Page 1 of 1

sun animation

Posted: Thu Sep 27, 2012 9:55 am
by AlexP
Hi,

I'm looking for easy solution to make timelapse sun animation. When I key time in Maxwell settings, maya animates hours and minutes as separate values. Is there any way to lock them together making them behave like a clock?

Best regs.

Re: sun animation

Posted: Thu Sep 27, 2012 10:21 am
by Mihnea Balta
You could make an expression which takes an input time as a number and breaks it down into hour, minute, second and drive those attributes with it. However, using the time of day is not really a good way to control the sun in an animation. Close to sunrise or sunset, one second of precision is not enough to get smooth transitions.

It's better to drive the sun direction with a Maya object, such as a directional light, and animate its orientation. That way you get smooth transitions regardless of the time of day, because the direction will be interpolated as needed. It's a bit tricky though if you need to match the real sun direction corresponding to a given location and time.

Re: sun animation

Posted: Sun Sep 30, 2012 12:05 pm
by AlexP
In the meantime I used that:
http://toi.bk.tudelft.nl/?m=4&s=1
SunSim. But it keys all frames one by one so I don't know how to e.g. alter sun speed though day. Moreover paremeters can't be saved.
Best feature would be possibility to create "sun light" via maxwell plugin.

Re: sun animation

Posted: Mon Oct 01, 2012 12:09 pm
by AlexP
Mihnea,
Can I set key for month in plugin settings? I can't rightclick dropdown to set key...

Re: sun animation

Posted: Mon Oct 01, 2012 3:14 pm
by Mihnea Balta
Set the month to the desired value with the dropdown, then run this in the command line or script editor:
Code: Select all
setKeyframe maxwellRenderOptions.skyMonth
Beware though that, since the month is an integer attribute, Maya will create a step curve, so the month will simply jump between the values you've set, without in-between values. To obtain smooth interpolation, select the render options node (for example by running the command "select -r maxwellRenderOptions"), open the graph editor, select the keys for the "Sky Month" attribute and hit one of the interpolation buttons in the toolbar (spline, linear etc.).

Re: sun animation

Posted: Mon Oct 01, 2012 6:04 pm
by AlexP
Thank you!