Custom render within plugin?

Custom render within plugin?

Anonymous
Not applicable
526 Views
2 Replies
Message 1 of 3

Custom render within plugin?

Anonymous
Not applicable
hi..

This may be a FAQ, but I'm not knowledgeable enough at this point to know :>(.

I'm using Maya 2013 to host a plugin which registers a node that samples a mesh to produce points. I would like to display the points and intermediate geometry while the plugin is processing the mesh because it is a fairly involved process and it would help with the debugging. For this reason it would be nice if there was a way to force a refresh of the viewport during the processing. From my limited understanding I think a custom viewport 2.0 renderer might work. I notice that there is also a way to register a custom shape in the plugin.. maybe this is a better approach? I don't know if a custom shape can be flushed to the viewport on demand.

Assuming that a custom renderer is suitable, I notice that Maya 2013 has a viewRenderOverride example using the new Viewport 2.0 API. My plugin is using MFnPlugin and I want to update a viewport while the node's compute() method is running. The compute method is currently invoked as a result of running Mel script within the script window.

If anyone knows of a good way to handle this I would appreciate your feedback.

thanks!
0 Likes
527 Views
2 Replies
Replies (2)
Message 2 of 3

Anonymous
Not applicable
Nevermind.. I'll use the FBX SDK and do a custom GUI outside Maya.
0 Likes
Message 3 of 3

Anonymous
Not applicable
with API using python
import maya.OpenMayaUI as OpenMayaUI
OpenMayaUI.M3dView.active3dView().refresh()
0 Likes