Defer OCIO LUT processor generation in render worker and fix stale graph snapshots
- Override OCIOLutNode::Value() to ensure the processor is created/updated before the color transform job is emitted. - In the worker process, mark the processor dirty on input/config changes instead of creating it synchronously during LoadGraph, which blocked the main process waiting for the graph load acknowledgement. - Keep eager processor generation in the main GUI process so the viewer cache is invalidated immediately when the LUT file or direction changes. - Mark the ProjectCopier's internal render-proxy project as modified when its update queue is processed, and reset the flag after RenderWorkerPool writes a new graph snapshot. This fixes the worker loading a stale graph snapshot after switching cube files or direction, which caused the old LUT effect to persist. All existing tests pass.
This commit is contained in:
@@ -572,6 +572,12 @@ bool RenderWorkerPool::PrepareJob(RenderTicketPtr ticket,
|
||||
return false;
|
||||
}
|
||||
wrote_new_snapshot = true;
|
||||
// For internal render-proxy copies, the snapshot now represents the
|
||||
// serialized state, so reset the modified flag so the snapshot can be
|
||||
// reused until the copy changes again.
|
||||
if (project->property("_oak_render_proxy").toBool()) {
|
||||
project->set_modified(false);
|
||||
}
|
||||
locker.relock();
|
||||
graph_cache_.insert(project_uuid, {graph_path});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user