Made predicate and function types callable in the sense that
authorTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>
Sun, 26 Jul 2009 16:15:28 +0000 (16:15 +0000)
committerTamito Kajiyama <rd6t-kjym@asahi-net.or.jp>
Sun, 26 Jul 2009 16:15:28 +0000 (16:15 +0000)
commit730fb1021c8b189229625866dac0f6e83db6418c
tree7985373b62cea17b3247a4e80842fbd372181058
parent78ce17fce88c23ba2c32b561bd9cc398a60a8278
Made predicate and function types callable in the sense that
callable(I, T) returns True when I is an object of a type T or
of a subtype of T.  Also implemented a measure to avoid an
infinite loop when user-defined predicate and function classes
do not properly overload the __call__ method (including the
cases of directly instantiating the base classes such as
UnaryPredicate0D and BinaryPredicate1D).
22 files changed:
source/blender/freestyle/intern/python/BPy_BinaryPredicate0D.cpp
source/blender/freestyle/intern/python/BPy_BinaryPredicate1D.cpp
source/blender/freestyle/intern/python/BPy_UnaryPredicate0D.cpp
source/blender/freestyle/intern/python/BPy_UnaryPredicate1D.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DDouble.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DEdgeNature.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DFloat.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DId.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DMaterial.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DUnsigned.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVec2f.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVec3f.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DVectorViewShape.cpp
source/blender/freestyle/intern/python/UnaryFunction0D/BPy_UnaryFunction0DViewShape.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DDouble.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DEdgeNature.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DFloat.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DUnsigned.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DVec2f.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DVec3f.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DVectorViewShape.cpp
source/blender/freestyle/intern/python/UnaryFunction1D/BPy_UnaryFunction1DVoid.cpp