maxgribov/Spine

Question: getting [SKTexture] instead of Action

Closed this issue · 15 comments

Is there a way we can get a list of textures instead of an action when animating an object?
Can we add an extension do to that?
Thank you

can you explain in more detail what you want?

theoretically you can render each frame of animation for your character and get it in the form of texture. But I don't see any practical sense in this. Why do this when you can just play the animation?

and of course I don't plan to add anything like this to the library.. But if you really need it, you can do it yourself... The code is open...

actually, with Spine, you have full control over the time of each animation. You set the keyframes at exactly the right moment...

You do, but that is before generating the animation. On certain sequences, where animation rate depends on other variables then time (e.x. distance from something) the frame rate control is "on the fly"

you can adjust the animation keyframes themselves to fit the timings you need... and it will be much easier than rendering the animation frames as textures...

The timings may change mid animation (i.e. when the animation is already playing). With an action you can't do that.

by the way, you can control the speed of SKAction with property speed

Depending on the model, it may not be practical.

I understand that you have some very specific tasks that go beyond my plans for the development of this library... So I'm sorry, but you'll have to come up with something yourself... Good luck

by the way, you can always render your animations as png images directly from the Spine app. Assemble them into sprite sheets and use them as normal sprite animation.

Btw, exactly where in your code are the textures being generated?

Nowhere. Right now, textures are just loaded from assets.