• Advertisement

Archived

This topic is now archived and is closed to further replies.

Loading ASE files

This topic is 6215 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I have created a model loader that loads ASE files into OpenGL the only problem is that the values loaded are huge. How do I scale these down and what to. In 3d exploration it exports CPP code find but it has an option to scale down to only have a number at the most at 1 how does this work Cheers Steve

Share this post


Link to post
Share on other sites
Advertisement
Hello, i show you two ways:

1.
in your render function add to all vertex point that your rendering /scaleValue for example:

glVertex3f( pnt.x / scaleValue , pnt.y / scaleValue ,pnt.z / scaleValue );

2.
you can alosw put some lines in your load function after that model loaded that scale all the vertices. for example:

for (int v=0; v{
vertex[v].x = vertex[v].z / scaleValue
vertex[v].y = vertex[v].y / scaleValue
vertex[v].z = vertex[v].z / scaleValue
}

and then render it.

that''s works for me.
i hope this help you , bye..

Share this post


Link to post
Share on other sites

  • Advertisement