Page 1 of 1
Keyable Hour in Physical Sky
Posted: Wed Oct 31, 2007 12:20 pm
by daimon
Hello,
Is there a way to key the hour or the Day of Year on physical sky options under Render Settings>Maxwell tab?
I need it for timelapse test and I don't want to do it frame by frame.
Thanks
D.
Posted: Thu Nov 01, 2007 6:39 pm
by deadalvs
hey !
try to use MEL a little...
like this:
setAttr "maxwellRenderOptions.skyTimeOfDay" 16;
You'll see that the time is set to 4 pm.
with that option now, You render out individual frames like in a batch job...
example:
set time x
render frame
set time y
render frame
...
does that help ?
Posted: Fri Nov 02, 2007 12:31 pm
by daimon
Thank you deadalvs,
Yes it helps but I have no idea about Mel and it will be a good idea if Next Limit does a little script to do that

Posted: Fri Nov 02, 2007 12:46 pm
by deadalvs
are You in a hurry and need it fast ?
i could give it a try.
maybe write what exactly You need... ok?
Posted: Fri Nov 02, 2007 1:04 pm
by daimon
Hello deadalvs
Not really I just wanted to automate some stuff.
Let say I have a house and I have a camera movement (100 frames), I want to set keyframe on time (frame 1, time 5am) and then another keyframe (frame 100, time 7pm). So now you have a timelapse video.
I am not sure if i make any sense here but please let me know if that helps.
D.
Posted: Fri Nov 02, 2007 1:09 pm
by deadalvs
ah, exactly as i imagined how it should work.
i guess this is not a big problem.
the only thing, as i guess, is that the sun-animation cannot be saved in the .mxs file. so each frame has to be saved/rendered individually.
so the script would set the sun time, render and save as file.frameNumber into a desired folder (normally default images folder).
then via fcheck You can save a video from all the image files...
that's not a lot to program and i could do that once i have time... okay ?

Posted: Fri Nov 02, 2007 2:24 pm
by daimon
Sounds perfect deadalvs,
Thanks a lot
Posted: Fri Nov 02, 2007 10:41 pm
by deadalvs
okay. there we go.
-->
http://www.jumpgates.com/matthias/MEL/d ... me.mel.zip
http://www.jumpgates.com/matthias/MEL/d ... aytime.mel
http://www.jumpgates.com/matthias/MEL/d ... aytime.txt
choose whichever link provides You with the script.
copy paste into the script editor, run it by hitting enter.
* * *
it's pretty self-explanatory.
the frames are rendered into active_project/images, named by the actual frame.
if You really need frame padding (naming convention like _0001 _0002 instead of _1 _2 and so on) i can script that too.
or if You need the frame's time in it's name like myimage_t_13_45_0005 (1:45 pm) or similar.
be aware that hitting the render button maya starts mxcl and renders every single frame in a row without stopping until finished. for aborting this You must kill the mxcl task in taskmgr.
((( the other «negative» point is that certainly maya is running in this batch process which means not the full amount of ram can be accessed by mxcl... certainly because maya is open... )))
have fun !
if You have any questions about the code: i'm here !
* * *
deadalvs
Posted: Tue Nov 06, 2007 9:49 am
by daimon
Sorry for the delay, damn Linksys kept me with out a connection for few days.
I am testing the script right now, its perfect!!!!
Thanks a million deadalvs
Posted: Tue Nov 06, 2007 10:09 am
by deadalvs
You're welcome.
if You need anything more: tell me.
of course i could continue the script for a full batch beast (defining different jobs, then render over night, weekend...). the only limitation there really is is that, as said, maya remains open which uses memory.
have fun !
Posted: Tue Nov 06, 2007 1:33 pm
by Jorge Alix
Posted: Tue Nov 06, 2007 1:52 pm
by deadalvs
okay... that's the professional approach towards that task...
thanks for the link !
Posted: Tue Nov 06, 2007 2:36 pm
by daimon
Posted: Tue Nov 20, 2007 7:58 pm
by def4d
huh? can we do that with Maxscripts?