How to run a videoPost plug-in when user changes the scene?
-
Hello,
I'm upgrading a videoPostData plug-in to the newest SDK version.
With R22, my plug-in
Execute
method was called each time the user changed the scene (move a mesh, play timeline, ...).With 2023.2.2 and with the same code the
Execute
is only called after a render.RENDERRESULT MyPlugin::Execute(BaseVideoPost* node, VideoPostStruct* vps) { ApplicationOutput("I want to be called at each editor-window change"); if( vps->vp == VIDEOPOSTCALL::RENDER && !vps->open && *vps->error == RENDERRESULT::OK ) { VPBuffer *rgba = vps->render->GetBuffer(VPBUFFER_RGBA, NOTOK); // ... } return RENDERRESULT::OK; }
How can I restore this behavior with the new SDK?
As reference, the behaviour I'm looking for is the same as the current "Sketch and Toon" effect when you enable "ViewportDisplay/Show Lines" in the effect settings.
macos 13.4.1
C4D 2023.2.2
C++ SDKThanks for your help
-
Hi @maxiokid ,
Please excuse the long answer delay.
There're a lot of changes between R22 and 2023.2.2, so I'm not surprised the behavior has changed. The way you adapt your plugin to the new SDK depends on what you're trying to achieve. Please provide a more detailed description of the the effects you need to use inside the execute function. Usually a minimally functional code snippet that highlights the issue is a very self-explanatory way to do that.
Cheers,
Ilia