Sign in to follow this  
bob23bob

convert from off-center object space to center

Recommended Posts

Hi guys, So I have this mesh whose object space origin is not the center of the object itself, but offset some distance away. Instead of 're-exporting' this mesh with a centered object-space origin, is there a way to do this programatically? Basically I'd like to modify all the verts in this mesh to be relative to the 'center' of the object itself. How might I approach this problem? Thanks for any hints ! -b

Share this post


Link to post
Share on other sites
Quote:
Original post by bob23bob
Basically I'd like to modify all the verts in this mesh to be relative to the 'center' of the object itself. How might I approach this problem?
First calculate the new center of the object, then subtract this from the old center, and add the resulting vector to each vertex in the mesh.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this