Hi GonzoRus, I think it has to do with the order that these rotation values are processed internally - in the function that processes the view angles it rotates by the up/down angle first and so I think the script also needs to do that one first as well.
Try these instead, here I've just moved the upDownAngles to be first:
Alt+W=script:var v = moi.ui.mainWindow.viewpanel.getViewport('3D'); v.upDownAngle = 0; v.leftRightAngle = 0; v.tiltAngle = 0;
Alt+D=script:var v = moi.ui.mainWindow.viewpanel.getViewport('3D'); v.upDownAngle = 85; v.leftRightAngle = 90; v.tiltAngle = 0;
Alt+Q=script:var v = moi.ui.mainWindow.viewpanel.getViewport('3D'); v.upDownAngle = 45; v.leftRightAngle = 45; v.tiltAngle = 0;
Alt+E=script:var v = moi.ui.mainWindow.viewpanel.getViewport('3D'); v.upDownAngle = 85; v.leftRightAngle = 0; v.tiltAngle = 0;
Or also there's a method that takes all 3 numbers in one call, v.setAngles( updown, leftright, tilt ) , I think that would also solve the problem and would look like this:
Alt+W=script:moi.ui.mainWindow.viewpanel.getViewport('3D').setAngles( 0, 0, 0 );
Alt+D=script:moi.ui.mainWindow.viewpanel.getViewport('3D').setAngles( 85, 90, 0 );
Alt+Q=script:moi.ui.mainWindow.viewpanel.getViewport('3D').setAngles( 45, 45, 0 );
Alt+E=script:moi.ui.mainWindow.viewpanel.getViewport('3D').setAngles( 85, 0, 0 );
Do these versions behave better for you?
- Michael
|