Results 1 to 2 of 2

Thread: How to do multitexturing and tessellation together

  1. #1
    Junior Member Newbie
    Join Date
    May 2008
    Posts
    2

    How to do multitexturing and tessellation together

    Hi,

    This is the first time that I post the question here. Please point me a direction for the question below. Thanks in advance!

    I'm trying to do dot3 bump mapping using OpenGL, where the multi-texturing function is used:
    glMultiTexCoord2fARB(GLenum texUnit, TYPE coords)

    At the same time, I need to tesselate the textured polygon to render ploygons with holes inside. In this case, I need to use:
    gluTessVertex(GLUtesselator* tessobj, GLdouble coords[3], void * vertex_data)

    However, I can't find a way to do both together. I can't find a way to fit the glMultiTexCoord2fARB(...) function in the GL tesselation routine and vice versa.

    Anyone had the similar problem before or has the ideas to get around it? I have an urgent dealine to meet and must sort this out soon. Any comments will be really appreciated.

    Many thanks,

    Chen

  2. #2
    Senior Member Frequent Contributor
    Join Date
    May 2005
    Location
    Prague, Czech Republic
    Posts
    913

    Re: How to do multitexturing and tessellation together

    You need to register tessellation callback of GLU_TESS_VERTEX type. When that callback is called by the tassellator, it will get the pointer you specified in the vertex_data parameter when you called the gluTessVertex for corresponding vertex. If you use pointer to structure containing texture coordinates of that vertex, the callback can then extract them and call glMultiTexCoord2fARB as necessary.

Similar Threads

  1. Tessellation shaders: more control over the actual tessellation?
    By Ailurus in forum OpenGL: Advanced Coding
    Replies: 2
    Last Post: 12-17-2015, 03:57 PM
  2. Tessellation!
    By Makinis in forum OpenGL: Basic Coding
    Replies: 0
    Last Post: 06-29-2009, 03:59 AM
  3. How to do multitexturing and tessellation together
    By maochenhappy in forum OpenGL: Advanced Coding
    Replies: 0
    Last Post: 05-06-2008, 10:02 AM
  4. Tessellation
    By Hec in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 02-08-2002, 09:08 AM
  5. Tessellation with MFC
    By BillJ in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 07-27-2001, 03:16 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Proudly hosted by Digital Ocean