Have LoadModel() use coordinate system of OBJ file rather than its own

Hello all,

I'm working on a project where I have asymmetrical, cylindrical parts I want to stack on top of each other (think totem pole).

When I created the shapes I made sure to put the origin in the same place for all the shapes so I could easily stack them on top of each other, and rotate them without them becoming misaligned.

Unfortunately from what I've seen P5's "loadModel()" will re-center the model moving it's origin.

Is there some mode or method I could use to have P5 use the origin of the OBJ file as the center of translation and rotation rather than using the default one it assigns?

Thank you.

Tagged:

Answers

  • Hello Everyone,

    I poked around with the code last night and figured out the problem.

    If anyone is having a similar problem the problem turned out to be the Normalize function not only scales the model, it also centers the origin. So if you scale it yourself you can avoid having the issue.

Sign In or Register to comment.