Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2013-02-22Code clean-up: Py_TYPE(self)->tp_name instead of ((PyObject ↵Tamito Kajiyama
*)self)->ob_type->tp_name.
2013-02-22Attribute renaming: .exact_type_name --> .name. Also did a more generic ↵Tamito Kajiyama
implementation of the attribute (meant to be a shortcut of .__class__.__name__).
2013-02-21Freestyle Python API improvements - part 5.Tamito Kajiyama
Handling of keyword arguments in Python wrapper class constructors was revised. This revision is mainly focused on Interface0D, Interface1D, Iterator, and their subclasses, as well as a few additional view map component classes. Implementation notes: Because of the extensive use of constructor overloading in the underlying C++ classes, the corresponding Python wrappers try to parse arguments through multiple calls of PyArg_ParseTupleAndKeywords() if needed. The downside of this implementation is that most argument errors result in the same error message ("invalid argument(s)") without indicating what is wrong. For now this issue is left for future work. * Now the instantiation of ViewVertex is prohibited since the underlying C++ class is an abstract class. * Removed the .cast_to_interface0diterator() method from CurvePointIterator and StrokeVertexIterator. Instead the constructor of Interface0DIterator now accepts the instances of these two iterator classes to construct a nested Interface0DIterator instance that can be passed to Function0D functor objects. Specifically, an iterator 'it' is passed to a functor 'func' as follows: func(Interface0DIterator(it)) instead of: func(it.cast_to_interface0diterator()) * Boolean arguments of class constructors only accept values of boolean type. Input values of other types are considered as error. * Additional code clean-up was made.
2013-02-16Fix for pointers to auto variables returned from Python wrapper class methods.Tamito Kajiyama
The previous implementation was a quick workaround of C++ const references. Also removed the unused 'borrowed' flag from the Python wrapper of FrsMaterial.
2013-02-16Made code style clean-up and fixed a typo in a docstring.Tamito Kajiyama
2013-02-16Freestyle Python API improvements - part 4.Tamito Kajiyama
Major API updates were made as in part 3 to address code review comments. This revision focuses on Python wrappers of C++ iterators. * Most getter/setter methods were reimplemented as attributes using PyGetSetDef. * The naming of methods and attributes was fixed to follow the naming conventions of the Blender Python API (i.e., lower case + underscores for methods and attributes, and CamelCase for classes). The only irregular naming change is the following, to better indicate the functionality: - ChainingIterator: getVertex --> next_vertex * In addition, some code clean-up was done in both C++ and Python. Also duplicated definitions of predicate classes were removed.
2013-02-16Fix for copy-and-paste bugs in Id rich comparison. Also made code style ↵Tamito Kajiyama
clean-up.
2013-02-15Fix compilation on linux (with gcc4.7).Bastien Montagne
Without const, I had the following error: /home/i7deb64/blender-2.5-svn/__work__/freestyle/source/blender/freestyle/intern/python/BPy_ViewMap.cpp: In function ‘PyObject* ViewMap_scene_bbox_get(BPy_ViewMap*, void*)’: /home/i7deb64/blender-2.5-svn/__work__/freestyle/source/blender/freestyle/intern/python/BPy_ViewMap.cpp:120:54: error: invalid initialization of non-const reference of type ‘BBox<VecMat::Vec3<double> >&’ from an rvalue of type ‘BBox<VecMat::Vec3<double> >’ In file included from /home/i7deb64/blender-2.5-svn/__work__/freestyle/source/blender/freestyle/intern/python/BPy_ViewMap.cpp:3:0: /home/i7deb64/blender-2.5-svn/__work__/freestyle/source/blender/freestyle/intern/python/BPy_Convert.h:81:12: error: in passing argument 1 of ‘PyObject* BPy_BBox_from_BBox(BBox<VecMat::Vec3<double> >&)’ /home/i7deb64/blender-2.5-svn/__work__/freestyle/source/blender/freestyle/intern/python/BPy_ViewMap.cpp:121:1: warning: control reaches end of non-void function [-Wreturn-type] make[2]: *** [source/blender/freestyle/CMakeFiles/bf_freestyle.dir/intern/python/BPy_ViewMap.cpp.o] Erreur 1
2013-02-15Minor coding style clean-up.Tamito Kajiyama
2013-02-15Freestyle Python API improvements - part 3.Tamito Kajiyama
Major API updates were made to address code review comments. This revision mostly focuses on Python wrappers of C++ 0D and 1D elements (i.e., Interface0D and Interface1D, as well as their subclasses). * Most getter/setter methods were reimplemented as attributes using PyGetSetDef. Vector attributes are now implemented based on mathutils callbacks. Boolean attributes now only accept boolean values. * The __getitem__ method was removed and the Sequence protocol was used instead. * The naming of methods and attributes was fixed to follow the naming conventions of the Blender Python API (i.e., lower case + underscores for methods and attributes, and CamelCase for classes). Some naming inconsistency within the Freestyle Python API was also addressed. * The Freestyle API had a number of method names including prefix/suffix "A" and "B", and their meanings were inconsistent (i.e., referring to different things depending on the classes). The names with these two letters were replaced with more straightforward names. Also some attribute names were changed so as to indicate the type of the value (e.g., FEdge.next_fedge instead of FEdge.next_edge) in line with other names explicitly indicating what the value is (e.g., SVertex.viewvertex). * In addition, some code clean-up was done in both C++ and Python. Notes: In summary, the following irregular naming changes were made through this revision (those resulting from regular changes of naming conventions are not listed): - CurvePoint: {A,B} --> {first,second}_svertex - FEdge: vertex{A,B} --> {first,second}_svertex - FEdge: {next,previous}Edge --> {next,previous}_fedge - FEdgeSharp: normal{A,B} --> normal_{right,left} - FEdgeSharp: {a,b}FaceMark --> face_mark_{right,left} - FEdgeSharp: {a,b}Material --> material_{right,left} - FEdgeSharp: {a,b}MaterialIndex --> material_index_{right,left} - FrsCurve: empty --> is_empty - FrsCurve: nSegments --> segments_size - TVertex: mate() --> get_mate() - ViewEdge: fedge{A,B} --> {first,last}_fedge - ViewEdge: setaShape, aShape --> occlude - ViewEdge: {A,B} --> {first,last}_viewvertex - ViewMap: getScene3dBBox --> scene_bbox
2013-02-14Fix for a static variable in BlenderStrokeRenderer::RenderStrokeRep() left afterTamito Kajiyama
quick trials of different approaches to performance improvement.
2013-02-13Fix for a crash when the Polygonization geometry modifier is used with a ↵Tamito Kajiyama
small "error" parameter value. The problem was caused by a null pointer reference in CurvePiece::error() resulting from incorrect lengths of subdivided curves calculated in CurvePiece::subdivide(). Problem report by IRIE Shinsuke with a GDB backtrace log, many thanks!
2013-02-10Merged changes in the trunk up to revision 54421.Tamito Kajiyama
Conflicts resolved: release/datafiles/startup.blend release/scripts/startup/bl_ui/properties_render.py source/blender/SConscript source/blender/blenloader/intern/readfile.c
2013-02-04* Added a generic helper function for parsing PyObject arguments as ↵Tamito Kajiyama
N-dimensional float array. * Local helpers were replaced with the generic one. This also fixed a memory leak in the setter function StrokeVertex_point_set. * Made minor code style changes.
2013-02-04* Fix for broken StrokeAttribute.visible setter function.Tamito Kajiyama
* Fix for a wrong vector element index in StrokeAttribute_mathutils_set in the case of MATHUTILS_SUBTYPE_COLOR. * Made minor code style changes.
2013-02-04Replaced PyTuple_SetItem by PyTuple_SET_ITEM when creating new tuples.Tamito Kajiyama
2013-02-03Freestyle Python API improvements - part 2.Tamito Kajiyama
The API syntax of FrsMaterial was updated by means of getter/setter properties. Python style modules (including the Parameter Editor) were updated accordingly.
2013-01-29Fix for a crash when freeing copied scenes.Tamito Kajiyama
The problem was caused by the fact that BKE_scene_copy() was simply doing "memcpy" to duplicate render layers including lineset settings without taking care of pointers in the linesets. For this reason, freeing the original scene and copied one resulted in freeing allocated memory buffers twice. Now BKE_scene_copy() properly duplicates linesets as part of render layers. Also some code clean-up was made in the modified files. Problem report by IRIE Shinsuke (with a patch to fix the crash). Many thanks!
2013-01-28Freestyle Python API improvements.Tamito Kajiyama
StrokeAttribute class methods were renamed from camel case to lower case plus underscore. Also made changes to shaders.pyTVertexOrientationShader that uses the affected methods.
2013-01-28Freestyle Python API improvements - part 1.Tamito Kajiyama
* The API syntax of StrokeVertex and StrokeAttribute was updated by means of getter/setter properties instead of class methods. Python style modules (including the Parameter Editor implementation) were updated accordingly. * Code clean-up was done for a few Python style modules, mostly by removing duplicated definitions of stroke shaders and fixing indentation.
2013-01-27Slightly generalized the crash fix in revision 54111.Tamito Kajiyama
Also added a warning message to anticipate potential issues due to the implication of the problem addressed here.
2013-01-26Fix for a crash in curvature calculation due to a WVertex with no associated ↵Tamito Kajiyama
edges. (TODO: identify the reason why such a strange WVertex is generated.) Problem report by Vicente Carro with a .blend for reproducing the issue. Thanks a lot!
2013-01-25Fix for no copy constructor in the Python wrapper of StrokeAttribute.Tamito Kajiyama
2013-01-22Fix for Stroke.Resample(float iSampling) and Stroke.UpdateLength() usingTamito Kajiyama
StrokeVertex.point2d() instead of .getPoint(). It is noted that .point2d() returns a 3-dimensional vector representing a 2D-projected point, with the z component indicating a normalized depth of the original 3D point, whereas .getPoint() returns a plain 2-dimensional vector. This fix should have been done in revision 48510... Also made fix for callers of Stroke.Resample() not calling stroke.UpdateLength().
2013-01-19Suppressed MSVC warning C4521: multiple copy constructors specified.Tamito Kajiyama
2013-01-18Removed unused variable d2 and calculation of its value in ↵Tamito Kajiyama
GeomUtils::intersect2dSeg2dSegParametric(). It is double-checked that this is not a bug :) This fix was suggested as part of the patch set committed in revision 53887, thanks again Bastien!
2013-01-18A patch set from Bastien Montagne (thanks!) for silencing build warnings ↵Tamito Kajiyama
(from gcc 4.7), mostly by commenting out unused variables, or using the BLI's SET_UINT_IN_POINTER macro.
2013-01-09Fix for BPy_FrsMaterial docstring.Tamito Kajiyama
2013-01-06Merged changes in the trunk up to revision 53584.Tamito Kajiyama
Conflicts resolved: release/scripts/startup/bl_ui/properties_render.py source/blender/blenloader/intern/readfile.c source/blender/editors/interface/interface_templates.c source/blender/makesrna/RNA_enum_types.h Also made additional code updates for: r53355 UIList - Python-extendable list of UI items r53460 Alpha premul pipeline cleanup
2013-01-04New command-line option --debug-freestyle to enable verbose debug messagesTamito Kajiyama
on the console during Freestyle rendering. The debug prints are turned off by default now. Errors are still printed on the console. A patch set implementing this functionality was provided by Bastien Montagne. Many thanks! :)
2013-01-02Yet another big style clean-up patch by Bastien Montagne, thanks a lot!Tamito Kajiyama
Now the code style is acceptable for the merge now, according to Bastien. Thanks again Bastien for having this done! :)
2012-12-29Fix encoding (from ISO 8859-15 to utf8).Bastien Montagne
2012-12-29Another mega (literally :p) code clean-up patch by Bastien Montagne, thanks ↵Tamito Kajiyama
again!
2012-12-26Fix encoding (from ISO 8859-15 to utf8).Bastien Montagne
2012-12-26Partly reverted the changes in revision 53099 to avoid a compilation error ↵Tamito Kajiyama
with MinGW (see the commit log of revision 28253).
2012-12-22Another "insanely" big code clean-up patch by Bastien Montagne, many thanks!Tamito Kajiyama
2012-12-21Fix encoding of those files (was iso-8859-15, i.e 8bit, instead of utf-8!).Bastien Montagne
2012-12-20Another big patch set by Bastien Montagne, thanks a lot!Tamito Kajiyama
* Made Freestyle optional (turned on by default). * Fix for missing bpath.c updates in the previous merge of trunk changes.
2012-12-19Merged changes in the trunk up to revision 53146.Tamito Kajiyama
Conflicts resolved: release/datafiles/startup.blend source/blender/blenkernel/CMakeLists.txt source/blender/blenlib/intern/bpath.c source/blender/blenloader/intern/readfile.c
2012-12-18Another big code clean-up patch by Bastien Montagne (GPL headers, indentation,Tamito Kajiyama
spaces around operators, and so forth). Many thanks!
2012-12-14Remove the "ID" stuff from top comments.Bastien Montagne
2012-12-14Removed 'svn:keywords' and 'svn:mime-type' properties from ↵Bastien Montagne
source/blender/freestyle files.
2012-12-12Fix for svn:executable.Tamito Kajiyama
Reported by Bastien Montagne, thanks!
2012-12-10All angle properties were switched from degrees to radians (using PROP_ANGLE Tamito Kajiyama
RNA subtype), since Freestyle internally use angles in radians. A patch set by Bastien Montagne (many thanks!) NOTICE FOR BRANCH USERS: This commit may break line drawing settings of already saved Freestyle files. All angles are now treated as radians instead of degrees, so collections of angle values might be necessary in order to recover previous visual results. Affected properties are: - Crease Angle in the edge detection options - Min 2D Angle in the 'Splitting' section of a line style - Max 2D Angle in the 'Splitting' section of a line style - 'orientation' parameter of the Calligraphy thickness modifier - 'angle' parameter of the PerlinNoise1D geometry modifier - 'angle' parameter of the PerlinNoise2D geometry modifier - 'angle' parameter of the 2DTransform geometry modifier
2012-12-09Fix for a number of compiler warnings as well as a bug hidden by the warnings.Tamito Kajiyama
Patch contribution by Bastien Montagne, thanks!
2012-12-05A patch set by Bastien Montagne (many thanks!)Tamito Kajiyama
* Removed the ../include and ../src include directories from scons/cmake files. These directories do not exist and are very noisy when building. * Coding style clean-up in Python scripts: 'string' is used for enum values, and "string" for usual stings. * UILayout.active is used instead of UILayout.enabled to grey out "inactive" settings. This still allows users to edit them, which can be handy sometimes. * Improved UI layout of the Line Style panel by means of: - The standard “column” paradigm is used in more places; - More compact layout where possible; and - Tweaks to the modifiers' header. * Improved UI layout of the Line Set panel by rearranging the "Selection by" options into a compact row of toggle buttons.
2012-10-28Improvements of Freestyle GUI controls - Part 1.Tamito Kajiyama
This commit makes a set of fixes and improvements based on the results of Freestyle branch review by Brecht. The discussion thread is: http://lists.blender.org/pipermail/bf-committers/2012-October/037927.html * The Layers panel and Freestyle-related panels in the Render tab of the Properties window were moved to the newly created Render Layers tab. The idea is to separate per render layer rendering options into a distinct Properties window tab, and use the existing Render tab to accommodate per scene rendering options. * The new Freestyle panel was added in the Render tab. The panel header contains a toggle button for globally enabling Freestyle, with the aim of making Freestyle easier to find. Those Freestyle options in the Post Processing panel were also moved to the new panel. * GUI code was updated so that UI controls will be greyed out (instead of being hidden) when Freestyle is disabled. Additional UI changes were also made to reduce space consumption. * The list of line sets was moved from the Freestyle panel to the Freestyle: Line Sets panel. * Old ray-casting algorithms were removed from the UI. Now only two algorithms (culled and non-culled cumulative visibility detection algorithms) are available, and the selection is done by the new "Culling" toggle button within the edge detection options.
2012-10-21Fix for OCIO-based color management (reported in the commit log of revision ↵Tamito Kajiyama
50832). The solution is exactly the same with revision 43584 for a similar issue in pre-OCIO color management: i.e., just disabling color management during the nested invocation of BI for stroke rendering.
2012-10-06Split time measurement for temporary scene generation from that for stroke ↵Tamito Kajiyama
rendering.
2012-10-06An attempt to improve the performance of temporary scene generation for ↵Tamito Kajiyama
stroke rendering. Many thanks to Joshua Leung (aligorith) for the performance analysis of BKE_object_add function: http://lists.blender.org/pipermail/bf-committers/2012-October/037759.html