Jump to content
  • Advertisement
Sign in to follow this  
alejandro

OpenGL OpenGL Model Tessellation

This topic is 2608 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'm trying OpenGL 4.0 Tessellation and I want to apply it to an stablished model, my model is on .md2 format, I'm assuming that a Bezier evaluation will do with the evaluation shader, though I may be very very wrong. Anyways I'm stuck with the following instructions


draw()
{
glBindBuffer( GL_ARRAY_BUFFER, vboid)
{
...
glPatchParameteri(GL_PATCH_VERTICES, 3);
glDrawArrays( GL_PATCHES, 0, size ); // size = how many vertices the model has
...
}
glBindBuffer( GL_ARRAY_BUFFER, 0)
}


The problem is that when it renders the model looks all messy and it certainly doesn't look like when I rendered it using glDrawArrays(GL_TRIANGLES, 0, size). Any suggestions on what parameters to use on glPatchParam... and glDrawArrays?

Thank you

Share this post


Link to post
Share on other sites
Advertisement
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!