Committing a patch similar to revision 44887 with fixes to my own bugs
(sorry Campbell, and thanks for reviewing :)
Fixes
------
- examples/ svn directory not removed anymore (in-source builds possible again)
- fixed "include references somehow stopped working"
+ using shutils.makearchive() to zip the file
New command line options
------------------------
-l: Log the output of the api dump and sphinx|latex warnings and errors
If given, save logs in:
* OUTPUT_DIR/.bpy.log
* OUTPUT_DIR/.sphinx-build.log
* OUTPUT_DIR/.sphinx-build_pdf.log
* OUTPUT_DIR/.latex_make.log
(using only one log directive instead of -l for bpy and -L for sphinx)
-P: builds the pdf
-R: pack the files in a dir ready for online deployment
(including the zip and the pdf eventually)
Example usage:
./blender.bin -b -P doc/python_api/sphinx_doc_gen.py -- -p bmesh* -o ./<OUTPUTDIR> -B -P -R -l
Wrap customdata, so far you can access the data layers in a pythonic way but not manipulate the customdata yet.
provides dictionary like access to customdata layers, eg:
texpoly = bm.faces.tex["UVMap"]
print(bm.verts.shape.keys()) # un-intended pun, keys() works on all layers.
print("MyInt" in bm.edges.int) # __contains__
layer = bm.faces.get("CheckForLayer")
this is no big improvement but at least its not a regression.
using the new operator for the bevel modifier can be enabled again be uncommenting a define.
- Edge rotate would leave verts selected, this would give problems because those selections would leave edges that would try to rotate when run again. now de-select old verts on edge rotate.
- Rotating into hidden verts gave odd results, now make sure hidden state is ok.
- BMO_slot_buffer_hflag_disable / BMO_slot_buffer_hflag_enable now have flushing for the hide flag too.
Everything seems to work well (many tests making random changes over various meshes went good), but the code is a bit complex and hard to follow, due to the various possibilities of invalid poly/loop combinations… Code also makes more operations than previous tri/quad faces version (hence is a bit slower), but I don’t think we can do otherwise, it’s just the price for bmesh flexibility. ;)
Note: added the py script I used to make the tests, under source/tests/...
Added a new RNA-only nested structure, Brush.SculptCapabilities. It
contains read-only properties that use the current sculpt tool (and
occasionally other brush properties) to determine whether some feature
is available.
For example, the grab and snake-hook brushes don't support the
strength property. Querying brush.sculpt_capabilities.has_strength
will return false only if one of these brushes is selected.
Created a single unifed operator, PAINT_OT_brush_select, to replace
BRUSH_OT_sculpt_tool_set, BRUSH_OT_vertex_tool_set,
BRUSH_OT_weight_tool_set, and BRUSH_OT_image_tool_set.
- tessface vertex color had the wrong sized array passing to rna_iterator_array_begin
- re-calculating tessface's would clear them if they were already created (own mistake)
- ED_mesh_color_add initialized tessface vertex colors from the loop color array
also made rna's mesh.tessface_vertex_colors.new() work like tessface_uv_textures.new()
where layers can be added as long as polygons are not present.
sphinx_doc_gen.sh broke building docs -
- examples/ svn directory was being removed since it assumed an out-of-source build.
- include references somehow stopped working (didnt find why).
also fixed an unrelated error with building docs in object_utils.py
New command line options:
-l: logs bpy dumping problems in OUTPUT_DIR/.bpy.log
-L: logs sphinx|latex problems in:
* OUTPUT_DIR/.sphinx-build.log (sphinx building html problems)
* OUTPUT_DIR/.sphinx-build_pdf.log (sphinx building latex problems)
* OUTPUT_DIR/.latex_make.log (latex make problems)
-P: builds the pdf
-R: pack the files in a dir ready for online deployment
(including the zip and the pdf eventually)
Example usage:
./cmake/bin/blender -b -P ./blender/doc/python_api/sphinx_doc_gen.py -- -p bmesh* -l -o ./python_api -B -P -R -L
Added function: BM_face_create_ngon_vcloud
creating quads and tris use this too since it finds the best face winding direction based on surrounding face (if any)
Issue was caused by MFACE layer adding for even DM without tessellated faces
which lead to adding new layer but with NULL data. This causes issues when layer
with faces (after extrude) was attempting to add because currently CD only checks
if layer type exists but does not check for size of the layer.
Solved by not adding MFACE layer if there's no tessellated faces.
which resolves some possible issues with operating files with quotes and backslashes.
Also this might resolve (or at least help) resolving compilation error on GNU Hurd platform
which will help a lot maintaining Blender for Debian.
- Reset rotation value when toggling Align to View property
which correctly re-alignes object on continuous property
toggling and fixes issue
#30510: [2.62] Add Mesh - Torus - "Align to View" cannot be switched back when toggling off
- Moves all generic object-add properties into a helper function
which might be easily re-used.
This idea is borrowed from the multires modifier, which already
checked if the object was in sculpt mode and, if so, created the
PBVH. That check is now moved higher up the chain into
mesh_build_data(), so that it occurs for CDDerivedMesh too.
This also replaces an assert in cdDM_getPBVH for tesselated mesh faces
with a call to create them if missing.