2
$\begingroup$

I'm having trouble with the Wavefront .OBJ export script (using Blender 2.69). I can't seem to affect the origin of the exported vertices.

I've seen other threads suggesting the origin is that of the scene/world, but as far as I can tell the origin seems to always be the centre of the object's bounds. This makes it difficult to position objects in the game I'm developing because I'm never sure where exactly the origin is.

I have tried the following:

  • Tweaking all the export settings
  • Moving the object's origin around
  • Moving the object around in the scene (inc applying transformations)

All of the above have no effect on the exported vertices.

Any help would be much appreciated; thanks.

$\endgroup$
  • $\begingroup$ This is exactly why it's common practice to normalize the location of every mesh asset. If every mesh has its origin at 0,0,0 then importing, exporting, and rigging are much simpler. $\endgroup$ – Matt Jan 14 '14 at 17:26
  • $\begingroup$ This is quite strange, blender does apply the objects transformation when exporting - so grabbing and object and moving it will move it in relation to its origin. If you import the OBJ back into Blender is it centered? You can also just export a triangle, open it in a text editor- and see if the points are around the 0,0,0 origin or not. $\endgroup$ – ideasman42 Jan 14 '14 at 17:38
  • $\begingroup$ Another issue, how are you checking where the origin is? - perhaps this is incorrect. or the tool re-centers the geometry. $\endgroup$ – ideasman42 Jan 14 '14 at 18:59
  • $\begingroup$ Can you please Explain what you did in beginner level? It would be helpful $\endgroup$ – Adirai Maji Oct 24 '16 at 16:33
1
$\begingroup$

I now feel silly. Turns out I was wrong and the obj export script does work as expected. Instead, the object was being recentred by another script I was using afterwards (obj2opengl.pl). The solution was to use the -noMove switch when running this second script otherwise the default is to "move [the object] to the center of its vertices"

Thank you for the comments, it helped me realise the true problem!

| improve this answer | |
$\endgroup$
  • 1
    $\begingroup$ You may now accept your own answer :) $\endgroup$ – CodeManX Feb 14 '14 at 12:03

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.