Go to file
Tamito Kajiyama 840891e22a D545: Freestyle Python API: new methods for Stroke and StrokeVertexIterator.
This revision extends the Freestyle Python API to make for style module writing
easier.

- freestyle.types.Stroke: A proper support for reversed() is implemented.  It
works the same with other Python sequence objects (returns an iterator starting
from the end).  This is in effect equivalent to Stroke.stroke_vertices_end().

- freestyle.types.StrokeVertexIterator: An incremented, decremented and reversed
method are added.  The first two methods return a new StrokeVertexIterator
object that has been incremented and decremented, respectively. The reversed
method returns a new StrokeVertexIterator object that will traverse stroke
vertices in the opposite direction.

- freestyle.types.Interface0DIterator: Its constructor now accepts a Stroke
object to create an Interface0DIterator that traverses stroke vertices.  This is
in effect equivalent to Stroke.vertices_begin().  The new API makes stroke
shaders involving function calls much simpler as illustrated below:

  # in the old API
  it = stroke.stroke_vertices_begin()
  for vert in it:
      result = somefunc(Interface0DIterator(it))

  # in the new API
  it = Interface0DIterator(stroke)
  for vert in it:
      result = somefunc(it)


Differential Revision: https://developer.blender.org/D545

Reviewers: kjym3
2014-06-16 10:12:51 +09:00
build_files OSX: Set Blender.app and Blenderplayer.app creation and modification date to compiletime, else we would always have the time from checkout here 2014-06-02 14:20:07 +02:00
doc Automatically generate blender.1 man page during build process 2014-06-14 01:19:58 +10:00
extern Add patchset to recent Carve changes 2014-06-11 13:13:36 +06:00
intern * Fix OpenCL after uchar4 commit. 2014-06-15 01:09:59 +02:00
release Expose Weigth tools for edit mode 2014-06-14 15:18:46 +02:00
scons@2d6ebcb239 Basic support for UNC paths on Windows 2014-04-21 17:06:09 +02:00
source D545: Freestyle Python API: new methods for Stroke and StrokeVertexIterator. 2014-06-16 10:12:51 +09:00
.arcconfig Use HTTPS protocol for arc 2013-12-24 22:57:27 +06:00
.gitignore .gitignore: Adding CMakeLists.txt.user for QtCreator users. 2014-01-26 17:52:14 -08:00
.gitmodules Initialize git submodules for addons, locales and scons 2013-11-15 12:19:08 +06:00
CMakeLists.txt CMake fixup for bd43ac04 as indicated by Campbell Barton 2014-06-13 17:24:19 -03:00
COPYING == docs == 2010-10-13 14:44:22 +00:00
GNUmakefile OSX: fix T40413, automatic threads for compile throw wrong output 2014-05-29 11:15:32 +02:00
SConstruct CMake/SCons: finish removing MSVC2012 references 2014-05-15 16:16:25 +10:00