PDA

View Full Version : Query Render Cam through Render View


Hamburger
07-24-2012, 02:06 AM
Hi, I'm using this code;

renderWindowEditor -ex -crc newCamera5 renderWindowPanel1Window;


But it returns // Result: 0 //

If I use this:

renderWindowEditor -crc newCamera5 renderWindowPanel1Window;

I get this:

// Error: line 1: Only one instance of this panel type allowed: renderWindowEditor //

How does one actually change the "Render View" render camera through MEL?

The Help's examples don't seem to work either:

string $editor = `renderWindowEditor`;
renderWindowEditor -e -mq 0.7 0.3 0.3 0.5 $editor;
renderWindowEditor -e -ar true $editor;
renderWindowEditor -e -snapshot persp 256 256 $editor;
renderWindowEditor -q -crc $editor;
renderWindowEditor -e -crc persp $editor;
renderWindowEditor -e -srg 768 576 $editor;
// Error: line 1: Only one instance of this panel type allowed: renderWindowEditor //

f3rry
07-24-2012, 07:28 AM
{
string $a = `getCurrentCamera`;
print $a;
}

NaughtyNathan
07-24-2012, 09:14 AM
you need to make sure if you are editing an existing control you use the -edit (-e) flag otherwise Maya assumes you're trying to create a new control with the same name. However I've no idea why the example code fails, it seems ok looking...

CGTalk Moderation
07-24-2012, 09:14 AM
This thread has been automatically closed as it remained inactive for 12 months. If you wish to continue the discussion, please create a new thread in the appropriate forum.