copy node graph before rendering
Previous iterations would use mutexes to prevent changing of the graph mid-render, however several user actions would need to capture these mutexes causing the main thread to hang until the current render job (frame/range of samples) was complete. We now copy the nodes necessary as part of the "compile" process so that the main thread shouldn't need nearly as much blocking while caching occurs.
This commit is contained in:
@@ -28,6 +28,10 @@
|
||||
*
|
||||
* This is an abstract function. Since different types of Block will provide their lengths in different ways, it's
|
||||
* necessary to subclass and override the length() function for a Block to be usable.
|
||||
*
|
||||
* When overriding Node::copy(), the derivative class should also call Block::CopyParameters() on the new Block instance
|
||||
* which will copy the block's name, length, and media in point. It does not copy any node-specific parameters like any
|
||||
* input values or connections as per standard with Node::copy().
|
||||
*/
|
||||
class Block : public Node
|
||||
{
|
||||
|
||||
+2
-2
@@ -130,8 +130,8 @@ void NodeParam::DisconnectEdge(NodeEdgePtr edge)
|
||||
output->parent()->LockUserInput();
|
||||
input->parent()->LockUserInput();
|
||||
|
||||
output->edges_.removeAll(edge);
|
||||
input->edges_.removeAll(edge);
|
||||
output->edges_.removeOne(edge);
|
||||
input->edges_.removeOne(edge);
|
||||
|
||||
output->parent()->UnlockUserInput();
|
||||
input->parent()->UnlockUserInput();
|
||||
|
||||
Reference in New Issue
Block a user