OK fair enough. I guess most people must be using libgdx.
I tried porting the libgdx flavor but it turns out that it's actually easier to just use the spine-c flavor and expose what I need via JNI back to Android.
In my implementation I don't need all the vert transformations etc, all I really need is the bone scale/rotate/translate values at a given time step. To that end I've included a snippet from my implementation which seems to work (i.e. values change over time) but I just want to confirm that my assumptions are correct.
So rather than extracting the vertices, I just get the bone data:
spAnimationState_update(state, deltaTime);
spAnimationState_apply(state, skeleton);
spSkeleton_updateWorldTransform(skeleton);
int i;
for(i = 0; i < skeleton->boneCount; i++) {
spBone* data = skeleton->bones[i];
callback->onBoneStep(
i,
data->worldX,
data->worldY,
data->worldRotation,
data->worldScaleX,
data->worldScaleY);
}
(The "callback" instance is calling back to the JVM)
I don't really want "world" coordinates, but when I use the relative values (e.g. data->x) they don't seem to update.
Is there a better way to just get the SRT values?