Patches to Bf Blender for CAD development. https://tornavis.org/
Go to file
Lukas Tönne 09874df135 Structural cleanup and improvements for the compositor.
Many parts of the compositor are unnecessarily complicated. This patch
aims at reducing the complexity of writing nodes and making the code
more transparent.

== Separating Nodes and Operations ==

Currently these are both mixed in the same graph, even though they have
very different purposes and are used at distinct stages in the
compositing process. The patch introduces dedicated graph classes for
nodes and for operations.

This removes the need for a lot of special case checks (isOperation etc.)
and explicit type casts. It simplifies the code since it becomes clear
at every stage what type of node we are dealing with. The compiler can
use static typing to avoid common bugs from mixing up these types and
fewer runtime sanity checks are needed.

== Simplified Node Conversion ==

Converting nodes to operations was previously based on "relinking", i.e.
nodes would start with by mirroring links in the Blender DNA node trees,
then add operations and redirect these links to them. This was very hard
to follow in many cases and required a lot of attention to avoid invalid
states.

Now there is a helper class called the NodeConverter, which is passed to
nodes and implements a much simpler API for this process. Nodes can add
operations and explicit connections as before, but defining "external"
links to the inputs/outputs of the original node now uses mapping
instead of directly modifying link data. Input data (node graph) and
result (operations graph) are cleanly separated.

== Removed Redundant Data Structures ==

A few redundant data structures have been removed, notably the
SocketConnection. These are only needed temporarily during graph
construction. For executing the compositor operations it is perfectly
sufficient to store only the direct input link pointers. A common
pointer indirection is avoided this way (which might also give a little
performance improvement).

== Avoid virtual recursive functions ==

Recursive virtual functions are evil. They are very hard to follow
during debugging. At least in the parts this patch is concerned with
these functions have been replaced by a non-virtual recursive core
function (which might then call virtual non-recursive functions if
needed). See for example NodeOperationBuilder::group_operations.
2014-04-15 16:28:10 +02:00
build_files OSX/python: update to py 3.4 2014-04-15 14:12:22 +02:00
doc Style cleanup: C & pep8 2014-04-15 13:11:48 +10:00
extern ...and linking, sorry for that! 2014-04-10 22:00:54 +03:00
intern Fix cycles standalone not writing images in background mode properly. 2014-04-15 15:19:23 +02:00
release Fix my last commit cad4bfe: Added 'use_' prefix to Freestyle edge/face mark properties. 2014-04-15 14:44:08 +09:00
scons@59512aadd1 Revert changes to submodules 2014-03-10 15:17:22 +06:00
source Structural cleanup and improvements for the compositor. 2014-04-15 16:28:10 +02: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 OSX/python: update to py 3.4 2014-04-15 14:12:22 +02:00
COPYING == docs == 2010-10-13 14:44:22 +00:00
GNUmakefile Found another place where nproc can be used 2014-03-02 10:29:40 +01:00
SConstruct Scons/cycles: fix header distribution for geom 2014-04-04 13:07:32 +02:00