View Full Version : call for constructive criticising on my first script...

04 April 2006, 09:02 AM
hello everybody,

i've just finished writing my first script with mel, as i'm a beginner, i would like from you to take a look on this script and try it out, any constructive criticising is welcome! will notice in this script that i've written some solutions on something that already existe in mel (i'm beginner!!) like finding the first and last keyFrame on an animation, i didn't know it until the script has been finished! is the link :

description : it automises going thru sequances, looking thru the selected camera and setting up the timeline on the length of the curve, it's very usefull for handling animatics,......


04 April 2006, 10:02 AM
come on guys! don't tell me you don't have any comments to put on my first script! i'm really new in mel and a beginner in scripting so anything you say will help me a lot! .........

04 April 2006, 06:44 PM
I gave your script a try with my own scenes and realized it just works for one node cameras, I would definitely use it if you would include support for aim-cameras and aim-up-cameras as well. Sometimes the total length seems to give strange results in conjunction with those camera types, too.

Your scripting style is very good for a first-timer! I bet you had some programming experience before or at least took a very close look at other scripts. I personally like putting everything in one big procedure which has the same name like the script file so I can start it by typing the script name from the command line instead of sourcing the file. And while you use long parameter names most of the time which on the one hand makes your script very readable I tend to use the short forms to increase coding speed, but all this is just personal preference!
Good work :-)

04 April 2006, 08:21 PM
yes, i have had some experience in scripting, i used to code with php and a little bit with javascript and mysql, so all what i had to learn is the mel syntax, i still make simple scripts that you could know its functionnality just by reading the code :), but i would like to raise up my skill, it's why i'm asking everybody to give his oppinion on everything he wants, it's my first script in maya, and it suits me very well :thumbsup:.

thank you volXen, your personnal preferences are taken in consideration

you told me that the total length gives some strange result, i considered the length of the whole animation is the final key of the last camera, because if we have an overlapped camera animation (ex : cross dissolve), i don't think we should count the overlapped area twice!, i've wrote this script to help us (in my company) to manage the cams in an's why my thoughts was simple :), anyway, thank you volXen again, i'll work on it this weekend to fix it........

CGTalk Moderation
04 April 2006, 08:21 PM
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.