------------------------------------------------------------------------------- */
-
/*
ProcessAdvertisements()
copies advertisement info into the BSP structures
/* check for patches with adjacent edges that need to lod together */
PatchMapDrawSurfs( e );
+ if ( debugClip ) {
+ AddTriangleModels( e );
+ }
+
/* build an initial bsp tree using all of the sides of all of the structural brushes */
faces = MakeStructuralBSPFaceList( entities[ 0 ].brushes );
tree = FaceBSP( faces );
FloodAreas( tree );
/* create drawsurfs for triangle models */
- AddTriangleModels( e );
+ if ( !debugClip ) {
+ AddTriangleModels( e );
+ }
/* create drawsurfs for surface models */
AddEntitySurfaceModels( e );
/* note it */
Sys_Printf( "--- BSP ---\n" );
+ doingBSP = qtrue;
SetDrawSurfacesBuffer();
mapDrawSurfs = safe_malloc( sizeof( mapDrawSurface_t ) * MAX_MAP_DRAW_SURFS );
memset( mapDrawSurfs, 0, sizeof( mapDrawSurface_t ) * MAX_MAP_DRAW_SURFS );
Sys_Printf( "Debug portal surfaces enabled\n" );
debugPortals = qtrue;
}
+ else if ( !strcmp( argv[ i ], "-debugclip" ) ) {
+ Sys_Printf( "Debug model clip enabled\n" );
+ debugClip = qtrue;
+ }
+ else if ( !strcmp( argv[ i ], "-clipdepth" ) ) {
+ clipDepthGlobal = atof( argv[ i + 1 ] );
+ i++;
+ Sys_Printf( "Model autoclip thickness set to %.3f\n", clipDepthGlobal );
+ }
else if ( !strcmp( argv[ i ], "-sRGBtex" ) ) {
texturesRGB = qtrue;
Sys_Printf( "Textures are in sRGB\n" );
colorsRGB = qfalse;
Sys_Printf( "Colors are linear\n" );
}
- else if ( !strcmp( argv[ i ], "-altsplit" ) )
- {
+ else if ( !strcmp( argv[ i ], "-altsplit" ) ) {
Sys_Printf( "Alternate BSP splitting (by 27) enabled\n" );
bspAlternateSplitWeights = qtrue;
}
- else if ( !strcmp( argv[ i ], "-deep" ) )
- {
+ else if ( !strcmp( argv[ i ], "-deep" ) ) {
Sys_Printf( "Deep BSP tree generation enabled\n" );
deepBSP = qtrue;
}
else if ( !strcmp( argv[ i ], "-bsp" ) ) {
Sys_Printf( "-bsp argument unnecessary\n" );
}
- else{
- Sys_FPrintf( SYS_WRN, "WARNING: Unknown option \"%s\"\n", argv[ i ] );
+ else if ( !strcmp( argv[ i ], "-noob" ) ) {
+ Sys_Printf( "No oBs!\n" );
+ noob = qtrue;
+ }
+ else
+ {
+ Sys_Printf( "WARNING: Unknown option \"%s\"\n", argv[ i ] );
}
}