View Full Version : currentTime during rendering
Hi all max scripters, I have a problem using the script operator in pFlow. i can not acsess the currentTime systemglobals during rendering.
i want to change the frame number of the ifl to match the frame that is being rendered.
This is the code,
-----
on Proceed pCont do
(
bmp = openbitmap ("c:\\temp\\xmaptest\\test.ifl")
bmp.frame = currentTime
-----
any ideas how to get it to work?
/regards DW
|
|
Hi all max scripters, I have a problem using the script operator in pFlow. i can not acsess the currentTime systemglobals during rendering.
i want to change the frame number of the ifl to match the frame that is being rendered.
I just came back to Europe and don't have Max installed on the machine I am posting from, but check out the default Birth Script operator's code- IIRC, it shows an example how to detect the actual evaluation time of a ParticleContainer. Note that there are two times you can access - the start and the end of the evaluation range which is dependent on the sub-frame sampling... Also, most times in PFlow are in Ticks, so you will have to convert the result to frames by dividing by TicksPerFrame.
Tibys
12-16-2004, 01:37 PM
Trust this Man, Bobo is the master of max script.
Thanks Bobo, and yeah you are the man.. :)
Problem solved,
----
tStart = pCont.getTimeStart() as float
curFrame = ((tStart*framerate/4800)+1)
----
/cheers
DW
CGTalk Moderation
01-20-2006, 04:00 AM
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.
vBulletin v3.0.5, Copyright ©2000-2012, Jelsoft Enterprises Ltd.