1f220fa62Smrg/* 2f220fa62Smrg * SGI FREE SOFTWARE LICENSE B (Version 2.0, Sept. 18, 2008) 3f220fa62Smrg * Copyright (C) 1991-2000 Silicon Graphics, Inc. All Rights Reserved. 4f220fa62Smrg * 5f220fa62Smrg * Permission is hereby granted, free of charge, to any person obtaining a 6f220fa62Smrg * copy of this software and associated documentation files (the "Software"), 7f220fa62Smrg * to deal in the Software without restriction, including without limitation 8f220fa62Smrg * the rights to use, copy, modify, merge, publish, distribute, sublicense, 9f220fa62Smrg * and/or sell copies of the Software, and to permit persons to whom the 10f220fa62Smrg * Software is furnished to do so, subject to the following conditions: 11f220fa62Smrg * 12f220fa62Smrg * The above copyright notice including the dates of first publication and 13f220fa62Smrg * either this permission notice or a reference to 14f220fa62Smrg * http://oss.sgi.com/projects/FreeB/ 15f220fa62Smrg * shall be included in all copies or substantial portions of the Software. 16f220fa62Smrg * 17f220fa62Smrg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS 18f220fa62Smrg * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 19f220fa62Smrg * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL 20f220fa62Smrg * SILICON GRAPHICS, INC. BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, 21f220fa62Smrg * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF 22f220fa62Smrg * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 23f220fa62Smrg * SOFTWARE. 24f220fa62Smrg * 25f220fa62Smrg * Except as contained in this notice, the name of Silicon Graphics, Inc. 26f220fa62Smrg * shall not be used in advertising or otherwise to promote the sale, use or 27f220fa62Smrg * other dealings in this Software without prior written authorization from 28f220fa62Smrg * Silicon Graphics, Inc. 29f220fa62Smrg */ 30f220fa62Smrg 31f220fa62Smrg/* 32f220fa62Smrg * glsurfeval.h 33f220fa62Smrg * 34f220fa62Smrg */ 35f220fa62Smrg 36f220fa62Smrg#ifndef __gluglsurfeval_h_ 37f220fa62Smrg#define __gluglsurfeval_h_ 38f220fa62Smrg 39f220fa62Smrg#include "basicsurfeval.h" 40f220fa62Smrg#include "bezierPatchMesh.h" //in case output triangles 41f220fa62Smrg#include <GL/gl.h> 42f220fa62Smrg#include <GL/glu.h> 43f220fa62Smrg 44f220fa62Smrgclass SurfaceMap; 45f220fa62Smrgclass OpenGLSurfaceEvaluator; 46f220fa62Smrgclass StoredVertex; 47f220fa62Smrg 48f220fa62Smrg#define TYPECOORD 1 49f220fa62Smrg#define TYPEPOINT 2 50f220fa62Smrg 51f220fa62Smrg/* Cache up to 3 vertices from tmeshes */ 52f220fa62Smrg#define VERTEX_CACHE_SIZE 3 53f220fa62Smrg 54f220fa62Smrg/*for internal evaluator callback stuff*/ 55f220fa62Smrg#ifndef IN_MAX_BEZIER_ORDER 56f220fa62Smrg#define IN_MAX_BEZIER_ORDER 40 /*XXX should be bigger than machine order*/ 57f220fa62Smrg#endif 58f220fa62Smrg 59f220fa62Smrg#ifndef IN_MAX_DIMENSION 60f220fa62Smrg#define IN_MAX_DIMENSION 4 61f220fa62Smrg#endif 62f220fa62Smrg 63f220fa62Smrgtypedef struct surfEvalMachine{ 64f220fa62Smrg REAL uprime;//cached previusly evaluated uprime. 65f220fa62Smrg REAL vprime; 66f220fa62Smrg int k; /*the dimension*/ 67f220fa62Smrg REAL u1; 68f220fa62Smrg REAL u2; 69f220fa62Smrg int ustride; 70f220fa62Smrg int uorder; 71f220fa62Smrg REAL v1; 72f220fa62Smrg REAL v2; 73f220fa62Smrg int vstride; 74f220fa62Smrg int vorder; 75f220fa62Smrg REAL ctlPoints[IN_MAX_BEZIER_ORDER*IN_MAX_BEZIER_ORDER*IN_MAX_DIMENSION]; 76f220fa62Smrg REAL ucoeff[IN_MAX_BEZIER_ORDER]; /*cache the polynomial values*/ 77f220fa62Smrg REAL vcoeff[IN_MAX_BEZIER_ORDER]; 78f220fa62Smrg REAL ucoeffDeriv[IN_MAX_BEZIER_ORDER]; /*cache the polynomial derivatives*/ 79f220fa62Smrg REAL vcoeffDeriv[IN_MAX_BEZIER_ORDER]; 80f220fa62Smrg} surfEvalMachine; 81f220fa62Smrg 82f220fa62Smrg 83f220fa62Smrg 84f220fa62Smrgclass StoredVertex { 85f220fa62Smrgpublic: 86f220fa62Smrg StoredVertex() { type = 0; coord[0] = 0; coord[1] = 0; point[0] = 0; point[1] = 0; } 87f220fa62Smrg ~StoredVertex(void) {} 88f220fa62Smrg void saveEvalCoord(REAL x, REAL y) 89f220fa62Smrg {coord[0] = x; coord[1] = y; type = TYPECOORD; } 90f220fa62Smrg void saveEvalPoint(long x, long y) 91f220fa62Smrg {point[0] = x; point[1] = y; type = TYPEPOINT; } 92f220fa62Smrg void invoke(OpenGLSurfaceEvaluator *eval); 93f220fa62Smrg 94f220fa62Smrgprivate: 95f220fa62Smrg int type; 96f220fa62Smrg REAL coord[2]; 97f220fa62Smrg long point[2]; 98f220fa62Smrg}; 99f220fa62Smrg 100f220fa62Smrgclass OpenGLSurfaceEvaluator : public BasicSurfaceEvaluator { 101f220fa62Smrgpublic: 102f220fa62Smrg OpenGLSurfaceEvaluator(); 103f220fa62Smrg virtual ~OpenGLSurfaceEvaluator( void ); 104f220fa62Smrg void polymode( long style ); 105f220fa62Smrg void range2f( long, REAL *, REAL * ); 106f220fa62Smrg void domain2f( REAL, REAL, REAL, REAL ); 107f220fa62Smrg void addMap( SurfaceMap * ) { } 108f220fa62Smrg 109f220fa62Smrg void enable( long ); 110f220fa62Smrg void disable( long ); 111f220fa62Smrg void bgnmap2f( long ); 112f220fa62Smrg void map2f( long, REAL, REAL, long, long, 113f220fa62Smrg REAL, REAL, long, long, REAL * ); 114f220fa62Smrg void mapgrid2f( long, REAL, REAL, long, REAL, REAL ); 115f220fa62Smrg void mapmesh2f( long, long, long, long, long ); 116f220fa62Smrg void evalcoord2f( long, REAL, REAL ); 117f220fa62Smrg void evalpoint2i( long, long ); 118f220fa62Smrg void endmap2f( void ); 119f220fa62Smrg 120f220fa62Smrg void bgnline( void ); 121f220fa62Smrg void endline( void ); 122f220fa62Smrg void bgnclosedline( void ); 123f220fa62Smrg void endclosedline( void ); 124f220fa62Smrg void bgntmesh( void ); 125f220fa62Smrg void swaptmesh( void ); 126f220fa62Smrg void endtmesh( void ); 127f220fa62Smrg void bgnqstrip( void ); 128f220fa62Smrg void endqstrip( void ); 129f220fa62Smrg 130f220fa62Smrg void bgntfan( void ); 131f220fa62Smrg void endtfan( void ); 132f220fa62Smrg void evalUStrip(int n_upper, REAL v_upper, REAL* upper_val, 133f220fa62Smrg int n_lower, REAL v_lower, REAL* lower_val); 134f220fa62Smrg void evalVStrip(int n_left, REAL u_left, REAL* left_val, 135f220fa62Smrg int n_right, REAL u_right, REAL* right_val); 136f220fa62Smrg 137f220fa62Smrg void coord2f( REAL, REAL ); 138f220fa62Smrg void point2i( long, long ); 139f220fa62Smrg 140f220fa62Smrg void newtmeshvert( REAL, REAL ); 141f220fa62Smrg void newtmeshvert( long, long ); 142f220fa62Smrg 143f220fa62Smrg#ifdef _WIN32 144f220fa62Smrg void putCallBack(GLenum which, void (GLAPIENTRY *fn)() ); 145f220fa62Smrg#else 146f220fa62Smrg void putCallBack(GLenum which, _GLUfuncptr fn ); 147f220fa62Smrg#endif 148f220fa62Smrg 149f220fa62Smrg int get_vertices_call_back() 150f220fa62Smrg { 151f220fa62Smrg return output_triangles; 152f220fa62Smrg } 153f220fa62Smrg void put_vertices_call_back(int flag) 154f220fa62Smrg { 155f220fa62Smrg output_triangles = flag; 156f220fa62Smrg } 157f220fa62Smrg 158f220fa62Smrg void put_callback_auto_normal(int flag) 159f220fa62Smrg { 160f220fa62Smrg callback_auto_normal = flag; 161f220fa62Smrg } 162f220fa62Smrg 163f220fa62Smrg int get_callback_auto_normal() 164f220fa62Smrg { 165f220fa62Smrg return callback_auto_normal; 166f220fa62Smrg } 167f220fa62Smrg 168f220fa62Smrg void set_callback_userData(void* data) 169f220fa62Smrg { 170f220fa62Smrg userData = data; 171f220fa62Smrg } 172f220fa62Smrg 173f220fa62Smrg /**************begin for LOD_eval_list***********/ 174f220fa62Smrg void LOD_eval_list(int level); 175f220fa62Smrg 176f220fa62Smrg 177f220fa62Smrg 178f220fa62Smrg 179f220fa62Smrgprivate: 180f220fa62Smrg StoredVertex *vertexCache[VERTEX_CACHE_SIZE]; 181f220fa62Smrg int tmeshing; 182f220fa62Smrg int which; 183f220fa62Smrg int vcount; 184f220fa62Smrg 185f220fa62Smrg GLint gl_polygon_mode[2];/*to save and restore so that 186f220fa62Smrg *no side effect 187f220fa62Smrg */ 188f220fa62Smrg bezierPatchMesh *global_bpm; //for output triangles 189f220fa62Smrg int output_triangles; //true 1 or false 0 190f220fa62Smrg 191f220fa62Smrg 192f220fa62Smrg 193f220fa62Smrg void (GLAPIENTRY *beginCallBackN) (GLenum type); 194f220fa62Smrg void (GLAPIENTRY *endCallBackN) (void); 195f220fa62Smrg void (GLAPIENTRY *vertexCallBackN) (const GLfloat *vert); 196f220fa62Smrg void (GLAPIENTRY *normalCallBackN) (const GLfloat *normal); 197f220fa62Smrg void (GLAPIENTRY *colorCallBackN) (const GLfloat *color); 198f220fa62Smrg void (GLAPIENTRY *texcoordCallBackN) (const GLfloat *texcoord); 199f220fa62Smrg 200f220fa62Smrg void (GLAPIENTRY *beginCallBackData) (GLenum type, void* data); 201f220fa62Smrg void (GLAPIENTRY *endCallBackData) (void* data); 202f220fa62Smrg void (GLAPIENTRY *vertexCallBackData) (const GLfloat *vert, void* data); 203f220fa62Smrg void (GLAPIENTRY *normalCallBackData) (const GLfloat *normal, void* data); 204f220fa62Smrg void (GLAPIENTRY *colorCallBackData) (const GLfloat *color, void* data); 205f220fa62Smrg void (GLAPIENTRY *texcoordCallBackData) (const GLfloat *texcoord, void* data); 206f220fa62Smrg 207f220fa62Smrg void beginCallBack (GLenum type, void* data); 208f220fa62Smrg void endCallBack (void* data); 209f220fa62Smrg void vertexCallBack (const GLfloat *vert, void* data); 210f220fa62Smrg void normalCallBack (const GLfloat *normal, void* data); 211f220fa62Smrg void colorCallBack (const GLfloat *color, void* data); 212f220fa62Smrg void texcoordCallBack (const GLfloat *texcoord, void* data); 213f220fa62Smrg 214f220fa62Smrg 215f220fa62Smrg void* userData; //the opaque pointer for Data callback functions. 216f220fa62Smrg 217f220fa62Smrg /*LOD evaluation*/ 218f220fa62Smrg void LOD_triangle(REAL A[2], REAL B[2], REAL C[2], 219f220fa62Smrg int level); 220f220fa62Smrg void LOD_eval(int num_vert, REAL* verts, int type, int level); 221f220fa62Smrg 222f220fa62Smrg int LOD_eval_level; //set by LOD_eval_list() 223f220fa62Smrg 224f220fa62Smrg /*************begin for internal evaluators*****************/ 225f220fa62Smrg 226f220fa62Smrg /*the following global variables are only defined in this file. 227f220fa62Smrg *They are used to cache the precomputed Bezier polynomial values. 228f220fa62Smrg *These calues may be used consecutively in which case we don't have 229f220fa62Smrg *recompute these values again. 230f220fa62Smrg */ 231f220fa62Smrg int global_uorder; /*store the uorder in the previous evaluation*/ 232f220fa62Smrg int global_vorder; /*store the vorder in the previous evaluation*/ 233f220fa62Smrg REAL global_uprime; 234f220fa62Smrg REAL global_vprime; 235f220fa62Smrg REAL global_vprime_BV; 236f220fa62Smrg REAL global_uprime_BU; 237f220fa62Smrg int global_uorder_BV; /*store the uorder in the previous evaluation*/ 238f220fa62Smrg int global_vorder_BV; /*store the vorder in the previous evaluation*/ 239f220fa62Smrg int global_uorder_BU; /*store the uorder in the previous evaluation*/ 240f220fa62Smrg int global_vorder_BU; /*store the vorder in the previous evaluation*/ 241f220fa62Smrg 242f220fa62Smrg REAL global_ucoeff[IN_MAX_BEZIER_ORDER]; /*cache the polynomial values*/ 243f220fa62Smrg REAL global_vcoeff[IN_MAX_BEZIER_ORDER]; 244f220fa62Smrg REAL global_ucoeffDeriv[IN_MAX_BEZIER_ORDER]; /*cache the polynomial derivatives*/ 245f220fa62Smrg REAL global_vcoeffDeriv[IN_MAX_BEZIER_ORDER]; 246f220fa62Smrg 247f220fa62Smrg REAL global_BV[IN_MAX_BEZIER_ORDER][IN_MAX_DIMENSION]; 248f220fa62Smrg REAL global_PBV[IN_MAX_BEZIER_ORDER][IN_MAX_DIMENSION]; 249f220fa62Smrg REAL global_BU[IN_MAX_BEZIER_ORDER][IN_MAX_DIMENSION]; 250f220fa62Smrg REAL global_PBU[IN_MAX_BEZIER_ORDER][IN_MAX_DIMENSION]; 251f220fa62Smrg REAL* global_baseData; 252f220fa62Smrg 253f220fa62Smrg int global_ev_k; /*the dimension*/ 254f220fa62Smrg REAL global_ev_u1; 255f220fa62Smrg REAL global_ev_u2; 256f220fa62Smrg int global_ev_ustride; 257f220fa62Smrg int global_ev_uorder; 258f220fa62Smrg REAL global_ev_v1; 259f220fa62Smrg REAL global_ev_v2; 260f220fa62Smrg int global_ev_vstride; 261f220fa62Smrg int global_ev_vorder; 262f220fa62Smrg REAL global_ev_ctlPoints[IN_MAX_BEZIER_ORDER*IN_MAX_BEZIER_ORDER*IN_MAX_DIMENSION]; 263f220fa62Smrg 264f220fa62Smrg REAL global_grid_u0; 265f220fa62Smrg REAL global_grid_u1; 266f220fa62Smrg int global_grid_nu; 267f220fa62Smrg REAL global_grid_v0; 268f220fa62Smrg REAL global_grid_v1; 269f220fa62Smrg int global_grid_nv; 270f220fa62Smrg 271f220fa62Smrg/*functions*/ 272f220fa62Smrg void inDoDomain2WithDerivs(int k, REAL u, REAL v, 273f220fa62Smrg REAL u1, REAL u2, int uorder, 274f220fa62Smrg REAL v1, REAL v2, int vorder, 275f220fa62Smrg REAL *baseData, 276f220fa62Smrg REAL *retPoint, REAL *retdu, REAL *retdv); 277f220fa62Smrg void inPreEvaluate(int order, REAL vprime, REAL *coeff); 278f220fa62Smrg void inPreEvaluateWithDeriv(int order, REAL vprime, REAL *coeff, REAL *coeffDeriv); 279f220fa62Smrg void inComputeFirstPartials(REAL *p, REAL *pu, REAL *pv); 280f220fa62Smrg void inComputeNormal2(REAL *pu, REAL *pv, REAL *n); 281f220fa62Smrg void inDoEvalCoord2(REAL u, REAL v, 282f220fa62Smrg REAL *retPoint, REAL *retNormal); 283f220fa62Smrg void inDoEvalCoord2NOGE(REAL u, REAL v, 284f220fa62Smrg REAL *retPoint, REAL *retNormal); 285f220fa62Smrg void inMap2f(int k, 286f220fa62Smrg REAL ulower, 287f220fa62Smrg REAL uupper, 288f220fa62Smrg int ustride, 289f220fa62Smrg int uorder, 290f220fa62Smrg REAL vlower, 291f220fa62Smrg REAL vupper, 292f220fa62Smrg int vstride, 293f220fa62Smrg int vorder, 294f220fa62Smrg REAL *ctlPoints); 295f220fa62Smrg 296f220fa62Smrg void inMapGrid2f(int nu, REAL u0, REAL u1, 297f220fa62Smrg int nv, REAL v0, REAL v1); 298f220fa62Smrg 299f220fa62Smrg void inEvalMesh2(int lowU, int lowV, int highU, int highV); 300f220fa62Smrg void inEvalPoint2(int i, int j); 301f220fa62Smrg void inEvalCoord2f(REAL u, REAL v); 302f220fa62Smrg 303f220fa62Smrgvoid inEvalULine(int n_points, REAL v, REAL* u_vals, 304f220fa62Smrg int stride, REAL ret_points[][3], REAL ret_normals[][3]); 305f220fa62Smrg 306f220fa62Smrgvoid inEvalVLine(int n_points, REAL u, REAL* v_vals, 307f220fa62Smrg int stride, REAL ret_points[][3], REAL ret_normals[][3]); 308f220fa62Smrg 309f220fa62Smrgvoid inEvalUStrip(int n_upper, REAL v_upper, REAL* upper_val, 310f220fa62Smrg int n_lower, REAL v_lower, REAL* lower_val 311f220fa62Smrg ); 312f220fa62Smrgvoid inEvalVStrip(int n_left, REAL u_left, REAL* left_val, int n_right, REAL u_right, REAL* right_val); 313f220fa62Smrg 314f220fa62Smrgvoid inPreEvaluateBV(int k, int uorder, int vorder, REAL vprime, REAL *baseData); 315f220fa62Smrgvoid inPreEvaluateBU(int k, int uorder, int vorder, REAL uprime, REAL *baseData); 316f220fa62Smrgvoid inPreEvaluateBV_intfac(REAL v ) 317f220fa62Smrg { 318f220fa62Smrg inPreEvaluateBV(global_ev_k, global_ev_uorder, global_ev_vorder, (v-global_ev_v1)/(global_ev_v2-global_ev_v1), global_ev_ctlPoints); 319f220fa62Smrg } 320f220fa62Smrg 321f220fa62Smrgvoid inPreEvaluateBU_intfac(REAL u) 322f220fa62Smrg { 323f220fa62Smrg inPreEvaluateBU(global_ev_k, global_ev_uorder, global_ev_vorder, (u-global_ev_u1)/(global_ev_u2-global_ev_u1), global_ev_ctlPoints); 324f220fa62Smrg } 325f220fa62Smrg 326f220fa62Smrgvoid inDoDomain2WithDerivsBV(int k, REAL u, REAL v, 327f220fa62Smrg REAL u1, REAL u2, int uorder, 328f220fa62Smrg REAL v1, REAL v2, int vorder, 329f220fa62Smrg REAL *baseData, 330f220fa62Smrg REAL *retPoint, REAL* retdu, REAL *retdv); 331f220fa62Smrg 332f220fa62Smrgvoid inDoDomain2WithDerivsBU(int k, REAL u, REAL v, 333f220fa62Smrg REAL u1, REAL u2, int uorder, 334f220fa62Smrg REAL v1, REAL v2, int vorder, 335f220fa62Smrg REAL *baseData, 336f220fa62Smrg REAL *retPoint, REAL* retdu, REAL *retdv); 337f220fa62Smrg 338f220fa62Smrg 339f220fa62Smrgvoid inDoEvalCoord2NOGE_BV(REAL u, REAL v, 340f220fa62Smrg REAL *retPoint, REAL *retNormal); 341f220fa62Smrg 342f220fa62Smrgvoid inDoEvalCoord2NOGE_BU(REAL u, REAL v, 343f220fa62Smrg REAL *retPoint, REAL *retNormal); 344f220fa62Smrg 345f220fa62Smrgvoid inBPMEval(bezierPatchMesh* bpm); 346f220fa62Smrgvoid inBPMListEval(bezierPatchMesh* list); 347f220fa62Smrg 348f220fa62Smrg/*-------------begin for surfEvalMachine -------------*/ 349f220fa62SmrgsurfEvalMachine em_vertex; 350f220fa62SmrgsurfEvalMachine em_normal; 351f220fa62SmrgsurfEvalMachine em_color; 352f220fa62SmrgsurfEvalMachine em_texcoord; 353f220fa62Smrg 354f220fa62Smrgint auto_normal_flag; //whether to output normla or not in callback 355f220fa62Smrg //determined by GL_AUTO_NORMAL and callback_auto_normal 356f220fa62Smrgint callback_auto_normal; //GLU_CALLBACK_AUTO_NORMAL_EXT 357f220fa62Smrgint vertex_flag; 358f220fa62Smrgint normal_flag; 359f220fa62Smrgint color_flag; 360f220fa62Smrgint texcoord_flag; 361f220fa62Smrg 362f220fa62Smrgvoid inMap2fEM(int which, //0:vert,1:norm,2:color,3:tex 363f220fa62Smrg int dimension, 364f220fa62Smrg REAL ulower, 365f220fa62Smrg REAL uupper, 366f220fa62Smrg int ustride, 367f220fa62Smrg int uorder, 368f220fa62Smrg REAL vlower, 369f220fa62Smrg REAL vupper, 370f220fa62Smrg int vstride, 371f220fa62Smrg int vorder, 372f220fa62Smrg REAL *ctlPoints); 373f220fa62Smrg 374f220fa62Smrgvoid inDoDomain2WithDerivsEM(surfEvalMachine *em, REAL u, REAL v, 375f220fa62Smrg REAL *retPoint, REAL *retdu, REAL *retdv); 376f220fa62Smrgvoid inDoDomain2EM(surfEvalMachine *em, REAL u, REAL v, 377f220fa62Smrg REAL *retPoint); 378f220fa62Smrg void inDoEvalCoord2EM(REAL u, REAL v); 379f220fa62Smrg 380f220fa62Smrgvoid inBPMEvalEM(bezierPatchMesh* bpm); 381f220fa62Smrgvoid inBPMListEvalEM(bezierPatchMesh* list); 382f220fa62Smrg 383f220fa62Smrg/*-------------end for surfEvalMachine -------------*/ 384f220fa62Smrg 385f220fa62Smrg 386f220fa62Smrg /*************end for internal evaluators*****************/ 387f220fa62Smrg 388f220fa62Smrg}; 389f220fa62Smrg 390f220fa62Smrginline void StoredVertex::invoke(OpenGLSurfaceEvaluator *eval) 391f220fa62Smrg{ 392f220fa62Smrg switch(type) { 393f220fa62Smrg case TYPECOORD: 394f220fa62Smrg eval->coord2f(coord[0], coord[1]); 395f220fa62Smrg break; 396f220fa62Smrg case TYPEPOINT: 397f220fa62Smrg eval->point2i(point[0], point[1]); 398f220fa62Smrg break; 399f220fa62Smrg default: 400f220fa62Smrg break; 401f220fa62Smrg } 402f220fa62Smrg} 403f220fa62Smrg 404f220fa62Smrg#endif /* __gluglsurfeval_h_ */ 405