Notifications
Clear all

[Closed] Disable timeline update

Hi,

My tool does some operation on each frame. How do I disable the timeline update to speed things up?

6 Replies
DisableSceneRedraw()
EnableSceneRedraw()
2 Replies
(@juzwa)
Joined: 1 year ago

Posts: 0

Yeah but this still updates the timeline. Im talking about sth similar to BakeAnim by Joe Gunn

(@polytools3d)
Joined: 1 year ago

Posts: 0

Sorry, your original question was not clear enough.

I mean right now I just loop through the timeline and update frames, maybe thats just wrong logic. But still I cannot think about anything else:

t1 = animationRange.start
t2 = animationRange.end
sliderTime = animationRange.start
for t = 1 to (t2.frame – t1.frame) as integer do (
with redraw off (
– some code
sliderTime += 1f
)
)
sliderTime = animationRange.start

2 Replies
(@polytools3d)
Joined: 1 year ago

Posts: 0

Use ‘at time’ context. There are plenty of exmaple on the forum. Here is a simple one:

(
 	delete objects
 	b = box()
 	for j = 1 to 100 do with animate on at time j b.pos.x = j
 )

Otherwise, you may want to get the controller’s keys array and directly work with each key.

(@juzwa)
Joined: 1 year ago

Posts: 0

Thanks! I think this is what I’ve been looking for