0
$\begingroup$

I should explain that I've only just downloaded and installed blender maybe a week ago? There is a model I am going to use for a project and I have to convert it to a special format for the engine I'm using. It doesn't support bones or any rigging. To actually do rigging I apply a transformation to the drawing space according to where the model should be (for instance, move a submodel so that its rotation point is at the origin, rotate, and then move back and then do whatever transformations were applied to higher models in the hierarchy). So I do have the models themselves (the geometry and textures) converted into the proper format. That I do not need help with. I have another program for that but it only views polygon data (for the same reasons as above). I'm trying to determine those "rotation points" in blender. I have no idea how to use the interface. I figured out how to load the model in the window last night and I managed to delete some stupid cube that was sitting in the default window. I'm essentially wanting to know what menu or what button (preferably with screenshots) I go to in order to step through all the rotation points one by one so that I can convert it to my setup?

It is quite possible that my setup is slightly different than how bones work. I apologize if so. It's how I've thought about for quite some time when dealing with models. Hopefully it isn't too confusing for you people who have used Blender for more than a few hours.


For those asking what engine I'm using. It is game maker 8.0 pro. Yes I have read the manual thoroughly. It does not support bones. No, I cannot convert the codebase to something else as it is literally years old. No, I would prefer to not use a 3rd party library to load in the original model with its default rigging.

$\endgroup$
  • $\begingroup$ I understand that the SE new ToS and whatnot put "New Contributor" on people for some reason. I specifically do not like this for the reason that I am NOT a new user of stack exchange and do not need to be treated differently simply because I posted on a subforum I haven't before. Thank you. I just wanted to get that out of the way before I get inundated with "welcome to __" posts. I do not like those..... $\endgroup$ – The Great Duck Aug 28 '18 at 1:13
  • $\begingroup$ Can you add a screenshot what you get in Blender? Do you get an armature imported (looks like this, press Z to see in wireframe to check if it's not hidden inside the mesh) or is your model a collection of parts with unique origins? You might also got the "bones" as just empty objects.. $\endgroup$ – Jaroslav Jerryno Novotny Aug 28 '18 at 1:44
  • $\begingroup$ @JaroslavJerrynoNovotny I have the armature. I would prefer not to post a screenshot of the model if that is acceptable. I mostly just have no idea what menu to go to that would show the coordinates of this armature. $\endgroup$ – The Great Duck Aug 28 '18 at 1:54
1
$\begingroup$

With the armature selected switch to Edit Mode, select the bone you want, and the location of the point it rotates around is displayed in the Properties panel (N) under Head:

enter image description here

To automate this open a Text Editor window and run this code:

import bpy

obj = bpy.context.active_object

if obj.mode is not 'OBJECT': bpy.ops.object.set_object_mode()

for bone in obj.data.bones:
    print("Bone: {0} origin is at {1}".format(bone.name, bone.head))

It will output into System Console. You can rewrite it to output to a file in a custom format your engine will understand.

The values will be relative to the armature centre of origin and with Z axis pointing up.

$\endgroup$
  • $\begingroup$ Unfortunately my engine requires it to be hardcoded in manually (and quite tediously) but thanks for the tidbit about automating it. $\endgroup$ – The Great Duck Aug 28 '18 at 23:48
  • $\begingroup$ Alrighty I have confirmed that this works (or rather that i could follow the steps). Unfortunately my other program put the model in a different pose for some reason but luckily blender seems capable of saving each submodel separately. However a little linear algebra never killed anyone and it should be fun. $\endgroup$ – The Great Duck Aug 29 '18 at 0:16

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.