getting transform data at a certain time in ice

Discussions about SOFTIMAGEs© Interactive Creative Environment©
forton
Posts: 210
Joined: 25 Nov 2011, 16:57

getting transform data at a certain time in ice

Post by forton » 05 May 2015, 10:47

Is there a way to get transform data from an object with time input?
Like "get action source at frame" but for objects.

Cheers, Wim

User avatar
sant0s
Posts: 353
Joined: 05 Sep 2011, 20:57
Location: São Pedro de Moel

Re: getting transform data at a certain time in ice

Post by sant0s » 14 May 2015, 11:14

pls define it bit more precisely.
you mean srt transforms?
like getting global positiont/orientation/scale from cube7 at frame 531?

forton
Posts: 210
Joined: 25 Nov 2011, 16:57

Re: getting transform data at a certain time in ice

Post by forton » 15 May 2015, 09:32

Yes, like you describe, srt transforms at a specific frame.

Pooby
Posts: 501
Joined: 27 Aug 2010, 20:25

Re: getting transform data at a certain time in ice

Post by Pooby » 15 May 2015, 10:15

This is an idea thats a little more flexible than get action source at frame. I am going to use this on the current job if it works. I haven't tested it fully but I cant see why it would fail.

Have a point cloud in the scene, that is taking in the transforms from objects. ( this needs to be simulated)

IE.. a group of objects, feeding their transforms into the point cloud. Store the whole sequence as an array of transforms for one transform per point.

on the same ICE tree have it load the cache back in, so it keeps everything in memory. (obviously if its a huge sequence with lots of objects feeding in, it could get slow but test it to see)

Then any other object can look up any transform of any stored object at any time via the Pointcloud cache.

The advantage of this is that you dont need to do anything, once its set up and the data isn't stored in the scene, but an external file.
Any changes to the object feeding in the data, will update the cache upon simply playing the timeline instead of saving a new action.

EDIT.. although you will have to switch off the write cache when you're happy with the animation you're referencing, or it will write over the stored cache live during playback.

I just tested it and it works fine. The other very cool thing about this, is that you can reference the same animation in any number of scenes without manual loading. Once the cache is set up, it runs itself.

I feel a tutorial coming on. Its been months. Why not?

User avatar
FXDude
Posts: 1145
Joined: 19 Jun 2012, 19:59

Re: getting transform data at a certain time in ice

Post by FXDude » 15 May 2015, 15:34

That sounds awesome!

Reminded me of this!

Storing animation in ICE
https://vimeo.com/49833260


Which is awesome ! (like both you and ICE are :] )
(also works on points as you mention in the comments, so you can do things like trigger time warps on a mesh using a volume or weight map)

I wonder, is it also possible to refer parameters that have expressions? More specifically in this case, an "at_frame" expression?
hum...

User avatar
sant0s
Posts: 353
Joined: 05 Sep 2011, 20:57
Location: São Pedro de Moel

Re: getting transform data at a certain time in ice

Post by sant0s » 15 May 2015, 17:56

hahhah, I was thinking ultra simple and now there is some pro stuff coming up, nice!
would like to understand what you mean, @Pooby.
For what could you use that for example?
and yes, I also hear the tutorial is coming ;-)
SI still alive, great!

forton
Posts: 210
Joined: 25 Nov 2011, 16:57

Re: getting transform data at a certain time in ice

Post by forton » 16 May 2015, 00:37

this is what I'm doing for the moment:
I want to be able to do this without caching at all, it works with "get action source at frame", I have to loop the icetree for all the previous frames, I have to calculate all the previous steps to get the correct positions.
Now if I can do the same with normal srt's it would be perfect.
I know loops are slow and calculating every previous frame each time I change frame seems lot's of calculations.
But since it's only a few particles it works fast enough to scrub back and forth.
Off course at frame 3000 it could get a bit slower...

Pooby
Posts: 501
Joined: 27 Aug 2010, 20:25

Re: getting transform data at a certain time in ice

Post by Pooby » 16 May 2015, 10:00

Doing it without some sort of caching is impossible.
Even an action source is just a cache by different name. Storing it as an ICE array is a cache, whether its stored externally, Frozen into the scene, or running in the scene and played back further down the timeline after the storing is done.

A cache is just a bunch of data stored somewhere that you can access. You could even cache animation values to mesh positions and read that, but what you can't do is have a live lookup of the actual fcurves at a particular frame.
What I'd do is store to an external file, as its going to be the most flexible method and you can look it up from frame 1, but its your choice.