PDA

View Full Version : Scrub Cache - For ultra smooth scrubbing even on complex rigs



hesido
03-13-2005, 09:13 AM
This one's for the memory-rich, and just like about every other of my suggestions, this should be optional (esp. for the negativists :) )

Scrub Cache:
Everytime you scrub in the timeline back and forth, bones recalculate even when you don't change anything.. With ScrubCache on, every frame you move into will be recorded with memory so your IK and Bone solution is now in the cache the first time, and that solution will be recalled the second time you move your time slider to that frame. SO scrubbing back and forth will become real fast after the first time.. Hopefully..

The cache is flushed as soon as the user thinks he has changed sth :) so he doesn't even have to change sth, thinking is enough, lol.. Kidding. You got the idea.

This option will be turned off automatically when fractional frames are on. The user would be able to limit the number of frames to be hold in the cache, or the memory used for it, developers decide :=)

This option, when activated, would be on by default for the active object only, so it does not immediately suck the memory away for big scenes. So this would be a safety valve for such scenes.


There could even be a flush cache function for us to assign to a key, or a button in timeline that would to let us know the frame is now serverd from ScrubCache. When the button is pressed, the cache is cleared. This is to make sure if there is a calculation error for some reason, the user can flush cache. When you right click the button, you can turn ScrubCache on and off from the popup menu.


---
I thought of this idea when I saw I am rotating around my object ultra fast but when I scrub, things really slow down.
---

pros: Will block the bone's are slow whining for quite a long time..
cons: Memory usage.

Mylenium
03-13-2005, 10:09 AM
This one's for the memory-rich, and just like about every other of my suggestions, this should be optional (esp. for the negativists :) )

Scrub Cache:
Everytime you scrub in the timeline back and forth, bones recalculate even when you don't change anything.. With ScrubCache on, every frame you move into will be recorded with memory so your IK and Bone solution is now in the cache the first time, and that solution will be recalled the second time you move your time slider to that frame. SO scrubbing back and forth will become real fast after the first time.. Hopefully..

The cache is flushed as soon as the user thinks he has changed sth :) so he doesn't even have to change sth, thinking is enough, lol.. Kidding. You got the idea.

This option will be turned off automatically when fractional frames are on. The user would be able to limit the number of frames to be hold in the cache, or the memory used for it, developers decide :=)

This option, when activated, would be on by default for the active object only, so it does not immediately suck the memory away for big scenes. So this would be a safety valve for such scenes.


There could even be a flush cache function for us to assign to a key, or a button in timeline that would to let us know the frame is now serverd from ScrubCache. When the button is pressed, the cache is cleared. This is to make sure if there is a calculation error for some reason, the user can flush cache. When you right click the button, you can turn ScrubCache on and off from the popup menu.


---
I thought of this idea when I saw I am rotating around my object ultra fast but when I scrub, things really slow down.
---

pros: Will block the bone's are slow whining for quite a long times..
cons: Memory usage.

Makes sense and I don't even think that memory consumption is a problem - you only need to store rotational values and even with a complex hierarchy it would by no means be as much as e.g. even the smallest particle system and the resulting PFX file. I'm not quite sure if you could eliminate re-calcualtion entirely, though. This would very much depend on the threshold that lets the program decide whether something has changed or not. In an IK chain even seemingly small variations in angles on one end could result in major differences on the other end, so if you use too high a threshold you wouldn't see the effects and the feature would become kinda useless and counterproductive. Having an option to temporarily limit the calculation depth of an IK chain would be more efficient - it would still re-calculate for every frame, but only the bones adjacent to the current one defined by the depth. This does not exclude your idea and a combo of both might be even better. The ultimate solution of course would be having explicit "solvers" for IK chains and parts of them. Like e.g. in Maya you could eliminate a lot of the re-calculations by simply deactivating the solver.

Mylenium

hesido
03-13-2005, 04:08 PM
Thanks Mylenium for backing me :=)

However, tresholds are far too complex for my fragile little mind, I say we dump the cache as soon as the user does ANYTHING in the scene :)