Age | Commit message (Collapse) | Author |
|
Removed the ability to change the name of a constraint or vertex group
to "" as it was causing problems. Anyway, it shouldn't be allowed.
|
|
Crash deleting last vertex group in lattice. This code wasn't updated
to work for lattice vertex groups yet.
|
|
|
|
|
|
Updated Python Mesh API to support UV and Color layers with names.
Similar to vertex group's
renamed a function in customdata.c CustomData_free_layers -> CustomData_free_layers_active and made CustomData_free_layers accept an index, this is needed so python could free layers that arnt active.
|
|
These can be created and deleted in the Mesh panel in the same place as
before. There is always one active UV and vertex color layer, that is
edited and displayed.
Important things to do:
- Render engine, material support
- Multires and NMesh now lose non active layers
Also CustomData changes to support muliple layers of the same type, and
changes to layer allocation, updated documentation is here:
http://mediawiki.blender.org/index.php/BlenderDev/BlenderArchitecture/CustomData
|
|
although it has a lot of noise. Not to mention our bad string code gives
a load of warnings.
I've reviewed specifically:
- file reading/write
- dna and library code
- node system
- entire render module
Done a couple of files in src/ too, seemed to be nice errors.
|
|
code didn't use customdata yet.
|
|
All data layers, including MVert/MEdge/MFace, are now managed as custom
data layers. The pointers like Mesh.mvert, Mesh.dvert or Mesh.mcol are
still used of course, but allocating, copying or freeing these arrays
should be done through the CustomData API.
Work in progress documentation on this is here:
http://mediawiki.blender.org/index.php/BlenderDev/BlenderArchitecture/CustomData
Replaced TFace by MTFace:
This is the same struct, except that it does not contain color, that now
always stays separated in MCol. This was not a good design decision to
begin with, and it is needed for adding multiple color layers later. Note
that this does mean older Blender versions will not be able to read UV
coordinates from the next release, due to an SDNA limitation.
Removed DispListMesh:
This now fully replaced by DerivedMesh. To provide access to arrays of
vertices, edges and faces, like DispListMesh does. The semantics of the
DerivedMesh.getVertArray() and similar functions were changed to return
a pointer to an array if one exists, or otherwise allocate a temporary
one. On releasing the DerivedMesh, this temporary array will be removed
automatically.
Removed ssDM and meshDM DerivedMesh backends:
The ssDM backend was for DispListMesh, so that became obsolete automatically.
The meshDM backend was replaced by the custom data backend, that now figures
out which layers need to be modified, and only duplicates those.
This changes code in many places, and overall removes 2514 lines of code.
So, there's a good chance this might break some stuff, although I've been
testing it for a few days now. The good news is, adding multiple color and
uv layers should now become easy.
|
|
now, others can be added later (sticky, shape keys). Beside one small fix
for knife exact vertex group interpolation, is intended to work the same
as before.
Also fixes bug #5200, related to editmode undo and vertex groups. And
corrects the editmode to faceselect mode selection conversion, that was
broken in a previous commit.
|
|
With the addition of vertexgroup support for Lattices, the option
'create vertex groups from closest bone' crashed due to reading NULL.
Fix provided & tested by Joshua.
|
|
In a quick glance: (temp image)
http://www.blender.org/bf/rt.png
Main reason is that Lattices are useful a lot for Armature deformation.
Lattices just provide much more precise and interesting control. However,
with only bone envelopes it's very hard to use.
Working with Lattice vertex groups is nearly identical to Mesh:
- on CTRL+P 'make parent' you can choose the deform option now
- In editmode, the buttons to control vertex groups are available
- In outliner you can select vertexgroups too
- Deforming Lattices with Armatures has all options as for Mesh now.
Note:
- No WeightPaint has been added yet. To compensate, the editmode
drawing for a Lattice with vertex group shows weight values for the active
vertex group.
- Lattice editmode doesn't undo/redo weight editing yet.
- Softbody for Lattice still uses own vertex weights
Implementation notes:
- derivedmesh weight_to_rgb() is now exported to drawobject.c
- been doing cleanups in code (order of includes, var declarations, etc)
- weightpaint button handling now is generic
I've checked on Brecht's proposal for Custom Element data;
http://mediawiki.blender.org/index.php/BlenderDev/CustomElementData
It could have been used, but that would mean the existing code for
vertexgroup handling and armature deform couldn't be re-used. I guess this
is really a later todo.
|
|
This provides a weight-paint option that only paints on vertices that have
already the weight-group assigned before. The default adds weights on all
vertices painted on.
Fixes in patch include:
- much less code
- also support for 'filter' mode
- proper code styling
|
|
Shift+ctrl+A "Apply deformation" didn't work anymore, since we got the
Modifier stack. I've inserted a notice there for now, to point users to
the proper buttons.
|
|
calling "Apply deform" from toolbox, with no active object, crashed.
|
|
- Added subdivide sck upport for vertex groups
- Brought back subdivide-smooth, but it doesn't work as good as before yet,
it used to catch an exception for subdividing the middle vertex of a quad,
with edge-based subdivide it's not that simple. Will check later.
- made "number of cuts" a static variable, so it doesn't jump back to 2
all the time
Coder level notes:
- removed the old subdivide code (yay, over 30k code less!)
- did some minor layout cleanups in the new code (just consistant syntax)
- removed redundant code parts, to enable smooth & vgroup subdiv
- subdivide smooth can do multiple cuts too, but i like to see that only
as option when our smooth formula is good!
Compliment:
I think Johnny really made comprehensible design and nice code here. Was a
joy to work with. :)
|
|
but this code ensures the strcpy() is using BLI_strncpy now, and it uses
more clear names for the mallocs.
|
|
- Undo/Redo didn't work
- Crash on using weightpaint with Armature-modifier (instead of parent).
Note: checking if an object is being deformed cannot be simply done with
checking for a parent anymore... for this a call in modifier.c has been
added; modifiers_isDeformedByArmature(Object *). It even returns the
Armature object pointer.
|
|
- Hotkey CTRL+TAB toggles weightpaint on/off
- If Mesh has no vertex groups yet, it still accepts Weight Paint mode.
Then, on a first painting stroke it creates a default group.
- When combining WeightPaint mode with Bone selecting, if you select a
Bone without vertex group it draws Mesh dark blue. On a first painting
stroke it then also creates a new group, with the Bone name.
|
|
For defining the deformation distances of Bones, three values are being
used now. The bone tip and root radius define the bone-shape itself and the
"dist" defines the soft area around it. A full (user) doc is in CMS here;
http://www.blender3d.org/cms/Armature_Envelopes.647.0.html
Note: todo still is allowing both Vertex Deform Groups and these Envelopes
together (and or per Bone).
Also part of this commit is:
- New: Hiding bones in EditMode. This is a separate 'hide flag', so you can
keep the PoseMode hidden Bones separate from EditMode.
(In the future we should do some kind of bone-grouping or so)
- While transform(), the hotkeys G,R,S only switch mode when the previous
mode was compatible. Caused conflicts with Crease/BoneDist/etc.
- Deleting the last VertexGroup now also deletes the entire Mesh 'dvert'
data. Sounds logical, but remember that VertexGroups are partial on a
Mesh, partial on Object. Weird design decision though...
Anyhoo, at this moment the only way to have Bone Envelopes deform, is
by deleting all VertexGroups!
- In PoseMode, the hotkey ALT+S now does both B-Bone size or Envelope,
depending draw type.
- In EditMode, Extrude now also works when only Root points were selected.
- Weight editing is also symmetrical btw, with the "X-axis Mirror" option
set.
|
|
In WeightPaint mode, pose-mode armatures now allow selecting Bones, but
without making the Armature object active.
Selecting a Bone then results in selecting the associated vertexgroup. :)
Little quirk; all armatures with posemode then draw selectable...
|
|
- removed {lattice,curve}_modifier functions
- changed render code to use displist for curve rendering
instead of making its own. required adding a bevelSplitFlag
field to DispList. I also fixed the bevel face splitting
which did not work correctly in many situations.
- changed so all curve data creation happens in makeDispListCurveTypes,
includes making bevel list and filling polys
- changed render code to use displist for surface rendering
- removed Curve.orco variable, built as needed now
- removed stupid BLI_setScanFill* functions... why use a function
argument when you can use a global and two functions! Why indeed.
(this fixed crash when reloading a file with filled curves and
toggling editmode)
- bug fix, setting curve width!=1 disabled simple bevel for no
apparent reason
- cleaned up lots and lots of curve/displist code (fun example:
"if(dl->type==DL_INDEX3 || dl->type==DL_INDEX3)"). Hmmm!
- switched almost all lattice calls to go through lattice_deform_verts,
only exception left is particles
- added DBG_show_shared_render_faces function in render, just
helps to visualize which verts are shared while testing (no
user interface).
- renamed some curve bevel buttons and rewrote tooltips to be
more obvious
- made CU_FAST work without dupfontbase hack
Also by the way I wrote down some notes on how curve code
works, nothing spiffy but it is at:
http://wiki.blender.org/bin/view.pl/Blenderdev/CurveNotes
|
|
- convert object_apply_deform to use mesh_get_derived_deform
- convert build_particle_system to use mesh_get_derived_deform
- remove apply option from mesh_modifier
What do you know, this leaves only one callsite for mesh_modifier
and one "user" site for DL_VERTS...
|
|
and then went ahead and did it anyway. Someone is lying!
|
|
lot of casts, added prototypes, missing includes and some true errors
|
|
from blenkernel/ to src/. Moved the offending functions to blenkernel...
|
|
Function "deselect vertex group" didn't use proper code for new edge/face
flags yet.
|
|
- outliner bugs:
- shift+click on icons opened new window types
- click on world of other scene, makes that scene active
- deleting objects from multiple scenes crashed
|
|
Right now, it works for Meshes (all deformers including Curve) and for
Curve/Surfaces (only hooks).
More follows.
|
|
messages and pupmenu()s. Edited spelling and grammar,
stylistic consistency, etc.
I added the guidelines and rationale that I used to the
CMS here:
http://www.blender3d.org/cms/Language_and_terminology.338.0.html
Next step is to get icons in there, to make it easier to see
at a glance what sort of message (and how much attention
should be paid to it, or if it can be dismissed with a flick
of the mouse, eg. boring remove doubles notifications)
mockup: http://mke3.net:9000/blender/ui/controls/error_ok_icons.png
|
|
hold the three lists, nothing major, but gives a place to hang data
off of and a single "mesh" structure to pass around for editing
functions.
|
|
(MVert,MFace,etc) off into DNA_meshdata_types.h, to isolate areas
of source that actually edit mesh *data* vs. areas that just edit
mesh object information.
|
|
headerbar
|
|
colors. This because of the pretty weird (ab)use of load & make editmesh...
For each added undo step, the load_editmesh was fed with an empty mesh
to assign data to, without knowledge of what was in the original mesh.
That way UV and color data got lost.
Solved it in 2 steps:
1. removing the ->tface pointer from EditVlak, and make TFace a builtin
struct inside EditVlak. This didnt cost much extra mem, since it already
stored UV and color. This enabled some pretty cleanup in editmesh.c as
well, storing tface pointers was cumbersome.
2. for each undo step, it then generates always a tface and mcol block to
link to the undo Mesh.
Even when it wasn't in the actual Mesh, at exit editmode the original
Mesh is used as reference anyway, and undo-meshes are freed correctly.
The enormous commit is because I had to change the BLI_editVert.h file, and
found it was included in about every file unnecessary. I removed it there.
ALso found out that subsurf has code ready (unfinished) to make UV coords for
the displaylist in EditMode as well, nice to know for later...
|
|
|
|
Applies to bones that do not have a boneclass of unskinnable
(set per bone in editmode in the button window).
|
|
#ifdef HAVE_CONFIG_H
#include <config.h>
#endif
Just need to finish cpp files now :)
Kent
--
mein@cs.umn.edu
|
|
|