Maya Training

Introduction to Hard Surface Modeling

Maya Training

Interiors and Furniture Vol 1 & 2 - Modeling & Cloth

Maya Training

Shading, Lighting and Rendering the Bedroom in MR

Maya Training

Robot volume one - Modeling with animation in mind

Maya Training

Spach-Alspaugh House the complete courseware

Maya Training

Burt The Cartoon Dinosaur Vol 01 - Modeling

New Maya Training

Robot Volume 02 - Hybrid Rigging
You are here > Home > SimplyMaya Community Forums
Loading

Welcome to Simply Maya

Please Sign in or Sign up for an account

Member Login

Lost your password?

Not a member yet? Sign Up!

Old 29-12-2003, 06:06 PM   #1
DigitalDez
Registered User
 
DigitalDez's Avatar
 
Join Date: Dec 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Question Current viewport info

Is there a way to extract which viewport is currently active?

What I'm trying to do is create a simple (newbie) script to generate nurbs curves. I'd like it to be intuative like the default "Circle" and "Square" commands where they draw out perpendicular to the current viewport selected. Yet, if the Persp or a non-orthographic viewport is selected, it defaults to the top for creation. Any ideas?
DigitalDez is offline   Reply With Quote
Old 29-12-2003, 09:02 PM   #2
dannyngan
Registered User
 
dannyngan's Avatar
 
Join Date: Dec 2002
Location: Seattle, WA
Posts: 1,154
Thanks: 0
Thanked 1 Time in 1 Post
Default

Code:
getPanel -withFocus
__________________
Danny Ngan
Animator | Amaze Entertainment
my website | my blog | my job
dannyngan is offline   Reply With Quote
Old 29-12-2003, 11:18 PM   #3
DigitalDez
Registered User
 
DigitalDez's Avatar
 
Join Date: Dec 2003
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the help.

I tried to add the line of code you gave me and I did not get an error message, but I also did not receive the results I was hoping for.

I'm trying to create a small script that will draw a facited nurbs polygon shape. Here is what I have so far:

My Code:
circle -nr 0 1 0 -r 1 -d 1;
rename "nurbsPoly1";

I'm trying to get rid of the blue code above so that Maya looks for which viewport is active and draws my nurbsPoly1 perpendicular to the active viewport or top viewport if Persp/non-orthagonal is active. Where would I place the "getPanel -withFocus;" in the syntax above to achieve this result?
DigitalDez is offline   Reply With Quote
Old 21-01-2004, 08:55 PM   #4
strarup
Subscriber
 
Join Date: Jan 2003
Location: Denmark
Posts: 338
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Hi DigitalDez,

eh... I'm not sure if understand your question correctly, but whatever you do, all the viewports are members of the same workspace... and have the same coordinates to operate with...

so if you create a Nurbs sphere or any other object, it will be on the same spot (coordinate) in all the "modelling" Viewports...

hope this made sense...

regards

Strarup
__________________
------------------------------------------------
Alex V. U. Strarup

One mistake can ruin it all...
strarup is offline   Reply With Quote
Old 01-02-2004, 08:50 AM   #5
dannyngan
Registered User
 
dannyngan's Avatar
 
Join Date: Dec 2002
Location: Seattle, WA
Posts: 1,154
Thanks: 0
Thanked 1 Time in 1 Post
Default

One thing you could do is rotate the nurbs circle 90 degrees on either the X or Z axis to match whatever view has focus.
__________________
Danny Ngan
Animator | Amaze Entertainment
my website | my blog | my job
dannyngan is offline   Reply With Quote
Reply


Similar Threads
Thread Thread Starter Forum Replies Last Post
where can i post info about 3D job openings? atadami Members Lounge 3 03-12-2010 10:51 AM

Thread Tools





A little bit about who we are
Links you might find useful
Catch up with SimplyMaya
SimplyMaya specialises in Maya tutorials. We offer over 1,000 individual Maya training videos, ranging from basic Maya tutorials through to intermediate Maya tutorials. Our tutorials are created by instructors with industry experience and are designed to get you up and running in Maya quickly without making it seem like hard work.

Copyright © 1999-2015 SimplyMaya - vBulletin® Copyright © 2000-2015, Jelsoft Enterprises Ltd.