I'm even exporting animations, now. Trouble is Max's quaternions aren't making any sense to me, even when I call invert() (in the MaxScript). I've also included the transformation matrix, as retrieved for each vertex with bone.transform (MaxScript). Either I fix the quaternions or I extract the data from the transform matrix. The following method is used to build a jpct transformation matrix. Given that, how could I go about using the matrix?
private Matrix getTransformationMatrix(JSONArray transformData) {
Matrix transformMatrix = new Matrix();
for (int j = 0; j < 4; j++) {
JSONArray row = (JSONArray) transformData.get(j);
transformMatrix.setRow(j,
((Number)row.get(0)).floatValue(),
((Number)row.get(1)).floatValue(),
((Number)row.get(2)).floatValue(), 1f);
}
return transformMatrix;
}