Results 1 to 6 of 6

Thread: gluTessCallback compile error on OSX

  1. #1
    Member Newbie
    Join Date
    Jun 2006
    Posts
    31

    gluTessCallback compile error on OSX

    I keep getting the following error when trying to compile the following tessellation code in XCode on OS X:

    error: initializing argument 3 of 'void gluTessCallback(GLUtesselator*, GLenum, GLvoid(*)(...))'
    error: invalid conversion from 'GLvoid(*)()' to 'GLvoid (*)(...)'

    my call back function is declared as follows and I am using the following code to register it:

    e
    gluTessCallback(tess, GLU_BEGIN, (GLvoid (*) (void)) glBegin );
    gluTessCallback(tess, GLU_VERTEX, (GLvoid (CALLBACK*) ()) &glVertex3dv );
    gluTessCallback(tess, GLU_END, (GLvoid (CALLBACK*) ()) &glEnd );
    gluTessCallback(tess, GLU_TESS_COMBINE, (GLvoid (CALLBACK*) ()) &combineCallback );
    gluTessCallback(tess, GLU_ERROR, (GLvoid (CALLBACK*) ()) &errorCallback );

    #ifndef CALLBACK
    #define CALLBACK
    #endif


    static void CALLBACK vertexCallback(GLdouble *vertex)
    {
    glVertex3dv((GLdouble *)vertex);
    }


    What must the callback and the call to gluTessCallback look like?

  2. #2
    Super Moderator OpenGL Lord
    Join Date
    Dec 2003
    Location
    Grenoble - France
    Posts
    5,574

    Re: gluTessCallback compile error on OSX

    first, you should not cross post.
    This question is appropriate in the beginner section. Maybe on the Mac specific too, but only post once, thanks.
    See http://www.flipcode.com/articles/art...selating.shtml

  3. #3
    Member Newbie
    Join Date
    Jun 2006
    Posts
    31

    Re: gluTessCallback compile error on OSX

    Sorry, but the info in the link you send did not work I still get error

  4. #4
    Super Moderator OpenGL Lord
    Join Date
    Dec 2003
    Location
    Grenoble - France
    Posts
    5,574

    Re: gluTessCallback compile error on OSX

    "Still get error" is not informative.
    - what code you used this time ?
    - what error you got ?
    - at which line ?

    If you want to be helped, you seriously need to read and understand this :
    http://www.catb.org/~esr/faqs/smart-questions.html

  5. #5
    Member Contributor
    Join Date
    Feb 2004
    Location
    Dallas/ Nottingham
    Posts
    96

    Re: gluTessCallback compile error on OSX

    Being abusive will not get you the help you need

    The link provided works fine for me

  6. #6
    Member Newbie
    Join Date
    Jun 2006
    Posts
    31

    Re: gluTessCallback compile error on OSX

    Did you compile it in XCode?

Similar Threads

  1. gluTessCallback compile error on OSX
    By Jorufo in forum OpenGL: macOS
    Replies: 6
    Last Post: 07-03-2006, 06:49 AM
  2. gluTessCallback compile error on OSX
    By Jorufo in forum OpenGL: Advanced Coding
    Replies: 1
    Last Post: 07-02-2006, 02:54 PM
  3. gluTessCallback giving me error
    By ntsang in forum OpenGL: Basic Coding
    Replies: 1
    Last Post: 02-28-2004, 09:56 AM
  4. gluTessCallback won't compile
    By kmulkey in forum OpenGL: Windows
    Replies: 0
    Last Post: 01-23-2004, 09:03 AM
  5. gluTessCallback(tess, GLU_TESS_BEGIN, glBegin)Compile error
    By Andyxia in forum OpenGL: Basic Coding
    Replies: 2
    Last Post: 07-01-2002, 01:49 AM

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