Age | Commit message (Collapse) | Author |
|
|
|
|
|
also add py api BMDeformVert.clear()
|
|
Note about long lines: I did not touch to two pieces of code (because I don’t see any way to keep a nicely formated, compact code, with shorter lines):
* The node types definitions into rna_nodetree_types.h
* The vgroup name functions into rna_particle.c
|
|
Addresses:
* C++ comments.
* Spaces after if/for/while/switch statements.
* Spaces around assignment operators.
|
|
- spelling - turns out we had tessellation spelt wrong all over.
- use \directive for doxy (not @directive)
- remove BLI_sparsemap.h - was from bmesh merge IIRC but entire file commented and not used.
|
|
|
|
|
|
http://markmail.org/message/fp7ozcywxum3ar7n
|
|
|
|
Plus a few splits of very long lines…
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
tested that correcting invalid meshes works by generating random meshes and checking that only the first call to mesh.validate() makes changes.
found 2 bugs in mesh validation.
- face sorting array wasn't assigned correct indices.
- removing invalid edges used wrong comparison.
|
|
for python so it can correct for bad imported geometry - mesh.validate().
|
|
funcs more easily.
|
|
by modifiers.
detects...
- invalid vertex range for edges/faces
- duplicate indices in edge/face
- duplicate edges/faces in mesh
- missing edges data in faces
At the moment it doesn't correct errors, but eventually it will do this.
|
|
|
|
|
|
|
|
- mesh.add_geometry(v, e, f) --> mesh.vertices.add(tot), mesh.edges.add(tot), mesh.faces.add(tot)
- mesh.add_material(mat) --> mesh.materials.link(mat)
changed material.link so it always adds a material even if it exists in the list, this behavior is good for users but not scripts since it can mess up indicies (some formats may have the same material set twice).
|
|
scene.active_keying_set --> scene.keying_sets.active
...same for active_uv_texture. active_vertex_color, active_keyconfig,
- move mesh.add_uv_layer() and mesh.add_vertex_color() into their collections
also have them return the newly created layer and dont set the layer active.
uvtex = mesh.uv_layers.new(name)
vcol = mesh.vertex_colors.new(name)
|
|
|
|
|
|
|
|
msvc (though further work may be needed because changes made by the merge
|
|
|
|
|
|
bugs in RNA
from the report...
# bug 1. UV properties are not raw editable but are reported
# as RAW_TYPE_INT by RNA causing wrong conversion
# internally (bpy_rna.c line 2205)
# bug 2. raw update of UV coordinates crash blender (rna_access.c line 252)
mtfaces.foreach_set("uv", rawuvs)
# workaround:
#for i in range(int(len(faces)/4)):
# mtfaces[i].uv = uvs[i]
# bug 3. raw update of non-array property fails (rna_access.c line 2270)
mfaces.foreach_set("material_index", mats)
# workaround:
# for i in range(int(len(mfaces))):
# mfaces[i].material_index = mats[i]
# bug 4. It is not possible to add a vertex color layer using mesh API.
me.add_vertex_color()
# no workaround...
|
|
[[Split portion of a mixed commit.]]
|
|
eg.
for v in me.verts: print(v.index)
added calc_edges as an option eg.
mesh.update(calc_edges=True)
This is needed when adding faces to an existing mesh which create new edges.
|
|
* Move mesh API functions to mesh_data.c, would like to keep
RNA layer fairly thin, any non-trivial functions shoud be
in their modules.
* Replace mesh.create_copy by generic id.copy.
* Fix #19250: Mesh.add_geometry() in editmode fails silently,
now gives an error.
|
|
|
|
* copied I/O scripts
* copied, modified rna_*_api.c and rna_*.c
I/O scripts not working yet due to slight BPY differences and RNA changes. Will fix them later.
Not merged changes:
* C unit testing integration, because it is clumsy
* scons cross-compiling, can be merged easily later
|
|
|
|
something wrong (`svn status` output: http://www.pasteall.org/7887).
The command: svn merge -r 23130:23129 https://svn.blender.org/svnroot/bf-blender/branches/soc-2009-kazanbas
|
|
Next: update scripts and merge in 2.5.
|
|
Notifiers
---------
Various fixes for wrong use of notifiers, and some new notifiers
to make things a bit more clear and consistent, with two notable
changes:
* Geometry changes are now done with NC_GEOM, rather than
NC_OBJECT|ND_GEOM_, so an object does need to be available.
* Space data now use NC_SPACE|ND_SPACE_*, instead of data
notifiers or even NC_WINDOW in some cases. Note that NC_SPACE
should only be used for notifying about changes in space data,
we don't want to go back to allqueue(REDRAW..).
Depsgraph
---------
The dependency graph now has a different flush call:
DAG_object_flush_update(scene, ob, flag)
is replaced by:
DAG_id_flush_update(id, flag)
It still works basically the same, one difference is that it now
also accepts object data (e.g. Mesh), again to avoid requiring an
Object to be available. Other ID types will simply do nothing at
the moment.
Docs
----
I made some guidelines for how/when to do which kinds of updates
and notifiers. I can't specify totally exact how to make these
decisions, but these are basically the guidelines I use. So, new
and updated docs are here:
http://wiki.blender.org/index.php/BlenderDev/Blender2.5/NotifiersUpdates
http://wiki.blender.org/index.php/BlenderDev/Blender2.5/DataNotifiers
|
|
|
|
- changing object.matrix now updates object.loc/rot/scale
- added bpy.data.add_lamp()
|
|
- tweaked OBJ importer. It reads primitive files (cube, cone, etc.)
|
|
|
|
|
|
- Mesh.calc_normals
- Object.add_vertex_to_group
- Main.add_material
- Main.add_texture
- Material.add_texture
- OBJ importer conversion in progress
|
|
- added Mesh.add_uv_layer, Object.add_vertex_group
|