am developing a native plugin in C++ that will manipulate Unity textures and meshes.
I’ve noticed in the official example that it performs such actions as well as rendering actions in a special C++ function called through
GL.IssuePluginEvent in the C# script.
My question is, does any access to GPU memory have to happen inside that function?
Surely the rendering tasks have to happen there, but I noticed that I can successfully call
s_CurrentAPI->BeginModifyTexture from a C++ function that’s called from FixedUpdate().
Is this defined behavior or could that lead to unpredictable crashes and I’m forced to do everything graphics related in the RenderEvent?
Huge thanks in advance