Quad Tessellation

Started by Bludo, March 15, 2016, 11:43:58 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.



I was hoping someone might be able to help me with an issue I've run into while trying to modify one of the existing tessellation samples.  I was attempting to use quad tessellation rather than triangles.  After making adjustments to the tessellation eval and control shaders, I was still running into an issue where the resulting geometry was skewed.

My suspicion is that I am unable to modify the GL_PATCH_VERTICES parameter inside of initialization to tell GL the proper number of vertices to use.  So before I put up the shader code (which is basic quad tessellation sample shader code), I thought I'd see if this seems like the source of the problem.  If so, is it possible to set the GL_PATCH_VERTICES parameter inside of GeeXLab, and if it is possible, how would it be done?  Thanks in advance for any help that anyone can provide.


Let me look at the problem...


I added a new function in the gh_renderer lib to set the number of vertices per patch (GL_PATCH_VERTICES):


Every group of 4 vertices of the input mesh is used as patch. All built-in meshes in GeeXLab are triangular meshes, so they won't be rendered properly. You have to build your own meshes using gh_mesh.create_v2() and gh_mesh.alloc_mesh_data(). I added a code sample in the host_api/gl-400-arb-tessellation-shader/ that shows how to build these kind of meshes and how to to quad tess.

Everything will be available in the next (beta) update asap!


That's great!  It sounds like that should resolve the issues perfectly.

I know these kinds of roll-outs take time, but I thought I'd see when you anticipate the next release.  I very much look forward to the opportunity to try it out.

Thank you so much for your help.


I should publish the Windows version very shortly...