I'll try and see what I can do to maybe rush something out sooner, just to give you guys something decent to work with...
just keep in mind, it'll probably be very basic as I've had to break a few things to redo the code.
to explain a bit, I'm trying to organize everything first before writing, rather than re-iterate through everything numerous times like every other script does.
I got caught up on bone matrices, and properly organizing the ROOT node before life decided to shove me in a hole...
I wish there was more official documentation so I could know how much slack I had with the format (how I could organize things more effectively)
EDIT:
btw, regarding your animations being lost
B3D is similar to IQM in that there's no individual animations
all animations are just 1 large animation indexed by frame number
though the script I'm working with (2.79) does support iterating both ipo and action animations
there could be changes in 2.8 causing issues with animation referencing the script is not aware of.
I'm just guessing at this point though cause I can't test... =3=
EDIT2:
just so nobody gets discouraged, life finally cut me some slack (not sure for how long), and I've gotten some free time to work on things a bit better...
and working have I been these past few days, though I've currently hit a snag with animation data and am currently working on a HexEdit template to help me get past it:
older shots:
Spoiler
eventually I'll have the structs colored so stuff is easier to make out on the hex side, much like my old works with other model formats:
Spoiler
EDIT3:
oh cool, Minetest ignores the global MESH chunk material and just defaults to 0 per TRIS chunk :srs:
Code: Select all
if (triangle_brush_id != -1)
{
loadTextures(Materials[triangle_brush_id]);
B3dMaterial = &Materials[triangle_brush_id];
meshBuffer->Material = B3dMaterial->Material;
}
else
B3dMaterial = 0; // this should be the MESH material ID
though it's good to know multi-material IS supported at least...
EDIT4:
the HexEdit template is mostly functional and should work for most proper B3D files
if anyone would like me to release it as is, let me know :)
otherwise, after I finish the export script, I'll work on coloring the structs and providing more info to make things less cryptic ;)
EDIT5:
ok so going through the animation code, I realized I needed a little bit more out of my template for validation purposes...
does anyone know of a good quat to euler code that doesn't need branching logic to handle singularities, or better yet doesn't deal with atan2() at all??
(I'm actually going for a quat -> mtx33 -> euler as the codes there seem more solid)
I'd prefer a code that maintains the original value as much possible...
or in other words, maintaining crazy values like 720 degrees instead of substituting 0 degrees for a gimbal lock case
is it possible to passively ignore gimbal lock with a better equation??
EDIT5.5: after some research, I still haven't found what I'm looking for... (gotta love DDG)
it appears what I'm talking about prior would be extrinsic rotation about the original axis (how OpenGL actually works)
(frame rotation (every euler equation ever) is intrinsic and causes singularities)
is there an extrinsic quat -> euler or mtx33 -> euler equation anywhere??