/* ================ CM_CreateNewFloatPlane ================ */ static int CM_CreateNewFloatPlane(vec4_t plane) { #ifndef USE_HASHING // add a new plane if(numPlanes == SHADER_MAX_TRIANGLES) { Com_Error(ERR_DROP, "CM_FindPlane: SHADER_MAX_TRIANGLES"); } Vector4Copy(plane, planes[numPlanes].plane); planes[numPlanes].signbits = CM_SignbitsForNormal(plane); numPlanes++; return numPlanes - 1; #else cPlane_t *p; // create a new plane if(numPlanes == SHADER_MAX_TRIANGLES) { Com_Error(ERR_DROP, "CM_FindPlane: SHADER_MAX_TRIANGLES"); } p = &planes[numPlanes]; Vector4Copy(plane, p->plane); p->signbits = CM_SignbitsForNormal(plane); numPlanes++; CM_AddPlaneToHash(p); return numPlanes - 1; #endif }
/* ================ CM_CreateNewFloatPlane ================ */ static int CM_CreateNewFloatPlane( vec4_t plane ) { #ifndef USE_HASHING // add a new plane if( numPlanes == SHADER_MAX_TRIANGLES ) Host_Error( "CM_CreateNewFloatPlane: SHADER_MAX_TRIANGLES limit exceeded\n" ); Vector4Copy( plane, planes[numPlanes].plane ); planes[numPlanes].signbits = SignbitsForPlane( plane ); numPlanes++; return numPlanes - 1; #else cmplane_t *p; // temp; // create a new plane if( numPlanes == SHADER_MAX_TRIANGLES ) Host_Error( "CM_FindPlane: SHADER_MAX_TRIANGLES limit exceeded\n" ); p = &planes[numPlanes]; Vector4Copy( plane, p->plane ); p->signbits = SignbitsForPlane(plane); numPlanes++; CM_AddPlaneToHash( p ); return numPlanes - 1; #endif }
/* ================ CM_CreateNewFloatPlane ================ */ static int CM_CreateNewFloatPlane( vec4_t plane ) { cPlane_t *p; //, temp; // create a new plane if ( numPlanes == SHADER_MAX_TRIANGLES ) { Sys::Drop( "CM_FindPlane: SHADER_MAX_TRIANGLES" ); } p = &planes[ numPlanes ]; Vector4Copy( plane, p->plane ); p->signbits = CM_SignbitsForNormal( plane ); numPlanes++; CM_AddPlaneToHash( p ); return numPlanes - 1; }