CGTalk > Software > Autodesk Maya
Login register
Thread Closed share thread « Previous Thread | Next Thread »  
 
Thread Tools Search this Thread Display Modes
Old 10-31-2012, 12:31 AM   #1
Digit
_____
 
Digit's Avatar
portfolio
Andy
USA
 
Join Date: Nov 2004
Posts: 759
camera management script?

Hi, Ive been digging around trying to find a simple script that would allow me to quickly set my viewport to one of many cameras in my scene. I have found a few options on creative crash but theyre all old and no longer working. I dont know the first thing about scripting so cant help myself with this. Im looking for something along these lines:
http://www.creativecrash.com/maya/d...ookmark-manager

But could be even simpler than that. I just need a quick gui with a list of cameras that i can double click to set the viewport to. Maya's own camera sequencer is not quite what I'm looking for, nor is the bookmark manager quite it either.

Any ideas?

Thanks,
Andy
 
Old 10-31-2012, 01:26 AM   #2
Hamburger
Expert
portfolio
Where is it?
Architectural Viz
Australia
 
Join Date: Sep 2004
Posts: 2,014
 
Old 10-31-2012, 02:19 AM   #3
Horganovski
Freelance Animator/Rigger
 
Horganovski's Avatar
portfolio
Brian Horgan
Graphite9
Dublin, Ireland
 
Join Date: Apr 2007
Posts: 4,871
An interesting 10 minute scripting exercise for me so I had a go, this is MEL so it should work in any version of Maya (tested here in 2012/2013.5). Drop this in your Maya scripts folder, restart Maya and then type :

bh_cameraSwitcher;

That will launch a GUI that lists the cameras in the scene, click on any one to switch to it. Click the 'Refresh Cameras' button if you create a new camera and want to add that to the list.

[edit - newer version below

Hope that helps,
Cheers,
Brian

Last edited by Horganovski : 10-31-2012 at 05:50 PM.
 
Old 10-31-2012, 02:38 AM   #4
bk3d
Know-it-All
 
bk3d's Avatar
portfolio
brian keffer
Environment Artist
Sanzaru
fremont, USA
 
Join Date: Mar 2010
Posts: 312
Send a message via Yahoo to bk3d
here's a trick i learned a while back.
middle mouse drag a camera into your viewport from the outliner.
 
Old 10-31-2012, 02:21 PM   #5
Digit
_____
 
Digit's Avatar
portfolio
Andy
USA
 
Join Date: Nov 2004
Posts: 759
Thanks for all the useful responses!

Horganovski, you almost hit the jackpot but it didnt quite work for new cameras. Ill send you a PM.
 
Old 10-31-2012, 05:51 PM   #6
Horganovski
Freelance Animator/Rigger
 
Horganovski's Avatar
portfolio
Brian Horgan
Graphite9
Dublin, Ireland
 
Join Date: Apr 2007
Posts: 4,871
Fixed a minor bug in how the script was getting the camera names which could cause it to fail in some situations, here's a new one that should be more robust. Same process to use it as above, ie drop this in your Maya scripts folder, restart Maya and then type :

bh_cameraSwitcher;

Cheers,
Brian
 
Old 10-31-2012, 05:53 PM   #7
Digit
_____
 
Digit's Avatar
portfolio
Andy
USA
 
Join Date: Nov 2004
Posts: 759
Quote:
Originally Posted by Horganovski
Fixed a minor bug in how the script was getting the camera names which could cause it to fail in some situations, here's a new one that should be more robust. Same process to use it as above, ie drop this in your Maya scripts folder, restart Maya and then type :

bh_cameraSwitcher;

Cheers,
Brian


Works perfectly. Thanks a lot!
 
Old 10-31-2012, 05:54 PM   #8
Horganovski
Freelance Animator/Rigger
 
Horganovski's Avatar
portfolio
Brian Horgan
Graphite9
Dublin, Ireland
 
Join Date: Apr 2007
Posts: 4,871
You're welcome, glad that helps! I'll be using this myself too

Cheers,
Brian
 
Old 10-31-2012, 05:54 PM   #9
CGTalk Moderation
Lord of the posts
CGTalk Forum Leader
 
Join Date: Sep 2003
Posts: 1,066,481
Thread automatically closed

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.
__________________
CGTalk Policy/Legalities
Note that as CGTalk Members, you agree to the terms and conditions of using this website.
 
Thread Closed share thread


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
CGSociety
Society of Digital Artists
www.cgsociety.org

Powered by vBulletin
Copyright 2000 - 2006,
Jelsoft Enterprises Ltd.
Minimize Ads
Forum Jump
Miscellaneous

All times are GMT. The time now is 06:25 AM.


Powered by vBulletin
Copyright ©2000 - 2016, Jelsoft Enterprises Ltd.