The problem addressed here is that there was no mean to check if an iterator
points the last of the elements being iterated over. Such checking is necessary
to reliably dereference the iterator (i.e., calling the operator*() method of the
underlying C++ iterator object).
Now Interface0DIterator and StrokeVertexIterator have an .at_last property
to check if an iterator points the last element. Using this new API feature,
the present commit partly reverts the previous commit rBeb8964fb7f19 to
better address T41464.
Differential revision: https://developer.blender.org/D752
Author: flokkievids (Folkert de Vries)
Reviewed by: kjym3 (Tamito Kajiyama)
Include explicit control for texturing:
This commit introduces a painting mode option, available in
the slots panel. The default value "Material" will create slots from the
blender material, same as just merged from the paint branch.
The new option "Image", will use an explicit image field that artists can use
to select the image to paint on. This will should allow painting regardless
of the renderer used or for use in modifiers.
Remotely based on patch by kevindietrich (Kévin Dietrich), but using
a single generic panel here, as suggested by UI team.
Note we add this panel in all modes (only one tweak in scuplt mode,
where there is no history menu generated it seems, unlike other
'paint-like' modes), we can decide to move it into its own tab later.
Differential Revision: https://developer.blender.org/D733
- Get rid of the obsolete operator
- Use select_or_deselect_all in 3ds keymap, which performs better
than separate deselect all and select binded to the select mouse.
This was already done for maya, and seems was accidentally reverted
by 5a91db3d.
The reported issue was caused by an old bug combined with another bug
introduced by recent Freestyle Python API updates.
The old bug was that a mutable reference to CurvePoint was treated as if
it were immutable. Iteration over CurvePoint objects is implemented by
the C++ CurvePointIterator class, whose dereference method
CurvePointIterator::operator*() returns a reference to a mutable data
member (probably originally intended for better performance). Hence the
returned reference may vary upon iteration over different CurvePoints.
This implementation detail was overlooked and the returned reference was
treated as immutable (which is the case in fact for other Interface0D
subclasses except for CurvePoint). This bug was surprisingly old as it
existed before the beginning of Freestyle integration into Blender.
The other bug was in the MaterialBoundaryUP0D predicate class that was
not properly handling the end of iteration. It is noted that when the
iter() and next() built-in functions are applied to Interface0DIterator,
it is no longer possible to reliably check the end of iteration by the
.is_end property of the iterator. Namely, the .is_end property works as
expected only when iteration is carried out in combination with the
conventional .increment() and .decrement() methods of the iterator. For
this reason the commit rBb408d8af31c9 was partly reverted to recover the
previous definition of MaterialBoundaryUP0D.
Modeling tool to cut intersections into geometry (like boolean, without calculating inside/outside).
Faces are split along intersections, leaving new edges selected.
Access from Face menu.
Removed the previous changes for passing a line style through the Controller, and
revised the BlenderTextureShader to assign the shader node tree of a line style
(if specified) to strokes. This way the assignment of shading nodes can be done
through both the Freestyle GUI and Python scripting.
This commit merges the code in the pie-menu branch.
As per decisions taken the last few days, there are no pie menus
included and there will be an official add-on including overrides of
some keys with pie menus. However, people will now be able to use the
new code in python.
Full Documentation is in http://wiki.blender.org/index.php/Dev:Ref/
Thanks:
Campbell Barton, Dalai Felinto and Ton Roosendaal for the code review
and design comments
Jonathan Williamson, Pawel Lyczkowski, Pablo Vazquez among others for
suggestions during the development.
Special Thanks to Sean Olson, for his support, suggestions, testing and
merciless bugging so that I would finish the pie menu code. Without him
we wouldn't be here. Also to the rest of the developers of the original
python add-on, Patrick Moore and Dan Eicher and finally to Matt Ebb, who
did the research and first implementation and whose code I used to get
started.
Added a small menu with a few helper oerators next to each group panel:
* Remove group from all objects
* Select objects in group
More could be added possibly in the future.
Thanks to Campbell for the advice here.