Skip to main content
Known Participant
January 10, 2024
Question

Passing modified sequence data from render thread back to ui threads

  • January 10, 2024
  • 1 reply
  • 191 views

I am modifying sequence data in my render thread of a multi-thread plugin. I set PF_OutFlag2_MUTABLE_RENDER_SEQUENCE_DATA_SLOWER and subsequent calls of the SmartRender function have access to the sequence data. However, the sequence data access from the UI thread for PF_Cmd_USER_CHANGED_PARAM or PF_Cmd_UPDATE_PARAMS_UI never contain the changes. What do I need to do to pass them back?

This topic has been closed for replies.

1 reply

Community Expert
January 10, 2024

Well, ae's design is such that data only travels ftom the ui thread to the data thread.

The reason being that in order to have a separate ui thread, and multiple render threads, the render copy of the project must remain consistent throughout the rendering process, so the render projects can't ne changed by the rendet threads. Sequence data can indeed be changed, but not to be copied cack to the ui thread.

 

That being said, it's not impossible to pull off without ae's help, such as with some pointer in the sequence data struct, but it's just bad practice as ae's work scheme wanrs the ui thread to indpendent of the render.

 

It's recomended that the ui thread aquire it's data using async calls to the render api.