Part of the Khronos Group
OpenGL.org

The Industry's Foundation for High Performance Graphics

from games to virtual reality, mobile phones to supercomputers

Results 1 to 1 of 1

Thread: Wired -glEvalMesh2 problem

Threaded View

  1. #1
    Junior Member Newbie
    Join Date
    May 2012
    Posts
    1

    Lightbulb Wired -glEvalMesh2 problem

    Hi everyone,

    I get stucked with this problem for two days and can someone please tell me the anwser?

    Thanks in advance.

    I try to generate a curved surface using control points. A curved surface is generated for ctrlPts [9][9] or ctrlPts [17][17], but no surface is generated at all for ctrlPts [32][32]. The ctrlPts is generated randomly. with x ranging from -350 to 350, , y> 0 and z ranging from -350 to 350.

    GLint nCtrlPtsR = 33;
    GLint nCtrlPtsC = 33;
    const GLint nu = 33, nv=33;
    GLfloat u1=0.0, u2=1.0, v1=0.0, v2=1.0;
    GLfloat ctrlPts [33][33][3];

    glPointSize(4);
    glMap2f (GL_MAP2_VERTEX_3, 0.0, 1.0, 3, nCtrlPtsR, 0.0, 1.0, nCtrlPtsC*3,nCtrlPtsC, &ctrlPts[0][0][0]);

    glEnable (GL_MAP2_VERTEX_3);
    glMapGrid2f(nu-1, 0.0,1.0,nv-1, 0.0,1.0);
    glEvalMesh2 (GL_FILL, 0,nu-1, 0,nv-1);
    Last edited by ehope2012; 05-14-2012 at 09:01 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
  •