]> git.rm.cloudns.org Git - xonotic/netradiant.git/commitdiff
Remove some commented-out code
authorMattia Basaglia <mattia.basaglia@gmail.com>
Mon, 13 Mar 2017 07:44:08 +0000 (07:44 +0000)
committerMattia Basaglia <mattia.basaglia@gmail.com>
Mon, 13 Mar 2017 07:44:08 +0000 (07:44 +0000)
76 files changed:
contrib/bkgrnd2d/dialog.cpp
contrib/bobtoolz/DBobView.cpp
contrib/bobtoolz/DBrush.cpp
contrib/bobtoolz/DPatch.cpp
contrib/bobtoolz/DPlane.cpp
contrib/bobtoolz/DShape.cpp
contrib/bobtoolz/DTrainDrawer.cpp
contrib/bobtoolz/bsploader.cpp
contrib/bobtoolz/funchandlers-GTK.cpp
contrib/bobtoolz/misc.cpp
contrib/bobtoolz/shapes.cpp
contrib/bobtoolz/visfind.cpp
contrib/camera/dialogs.cpp
contrib/camera/funchandlers.cpp
contrib/camera/listener.cpp
contrib/gtkgensurf/dec.cpp
contrib/gtkgensurf/face.cpp
contrib/gtkgensurf/font.cpp
contrib/gtkgensurf/gendlgs.cpp
contrib/gtkgensurf/genmap.cpp
contrib/gtkgensurf/gensurf.cpp
contrib/gtkgensurf/view.cpp
contrib/hydratoolz/plugin.cpp
contrib/prtview/portals.cpp
contrib/sunplug/sunplug.cpp
libs/generic/callback.cpp
libs/gtkutil/accelerator.cpp
libs/gtkutil/button.cpp
libs/gtkutil/dialog.cpp
libs/gtkutil/filechooser.cpp
libs/gtkutil/glfont.cpp
libs/gtkutil/menu.cpp
libs/gtkutil/messagebox.cpp
libs/memory/allocator.cpp
libs/splines/splines.cpp
libs/splines/util_str.cpp
plugins/entity/light.cpp
plugins/imagehl/mip.cpp
plugins/imagehl/sprite.cpp
plugins/md3model/md2.cpp
plugins/md3model/mdlimage.cpp
plugins/model/model.cpp
plugins/model/plugin.cpp
plugins/shaders/shaders.cpp
plugins/spritemodel/spritemodel.cpp
radiant/autosave.cpp
radiant/brush.cpp
radiant/brush_primit.cpp
radiant/build.cpp
radiant/camwindow.cpp
radiant/commands.cpp
radiant/console.cpp
radiant/eclass.cpp
radiant/eclass_doom3.cpp
radiant/eclass_fgd.cpp
radiant/entity.cpp
radiant/entityinspector.cpp
radiant/entitylist.cpp
radiant/gtkdlgs.cpp
radiant/mainframe.cpp
radiant/map.cpp
radiant/patch.cpp
radiant/patchdialog.cpp
radiant/patchmanip.cpp
radiant/qgl.cpp
radiant/referencecache.cpp
radiant/renderstate.cpp
radiant/scenegraph.cpp
radiant/select.cpp
radiant/selection.cpp
radiant/surfacedialog.cpp
radiant/texwindow.cpp
radiant/treemodel.cpp
radiant/watchbsp.cpp
radiant/windowobservers.cpp
radiant/xywindow.cpp

index 6d63bc3fd80e8cba0bb60ddd484088da45f470bb..cd8455d1343a5a9df99412bc80b12b96865ebba0 100644 (file)
@@ -55,7 +55,6 @@ void Append( GtkWidget *notebook );
 void Browse();
 void Reload();
 void SetPosLabel();
-//  ~BackgroundDialogPage();
 };
 
 
@@ -102,8 +101,6 @@ void CBackgroundDialogPage::Browse(){
 
        //TODO GetMapName saves the map. eeep!
        //also with no map, returns unnamed.map, otherwise returns full path
-//     Syn_Printf(MSG_PREFIX "GetMapName() %s\n",
-//                             g_FuncTable.m_pfnGetMapName());
 
        ct = g_FuncTable.m_pfnReadProjectKey( "basepath" );
        // TODO shouldn't need this stuff
@@ -225,7 +222,6 @@ CBackgroundDialogPage::CBackgroundDialogPage( VIEWTYPE vt ){
        g_signal_connect( G_OBJECT( w ), "clicked", G_CALLBACK( reload_callback ),
                                          ( gpointer ) this );
        // TODO disable until we have file
-       // gtk_widget_set_sensitive(w,FALSE);
        gtk_tooltips_set_tip( pTooltips, w, "Reload current file", NULL );
        gtk_box_pack_start( GTK_BOX( hbox ),w, FALSE, FALSE, 5 );
        gtk_widget_show( w );
@@ -324,7 +320,6 @@ void InitBackgroundDialog(){
                                                GTK_SIGNAL_FUNC( close_callback ), NULL );
        gtk_signal_connect( GTK_OBJECT( pDialogWnd ), "response",
                                                GTK_SIGNAL_FUNC( response_callback ), NULL );
-//  gtk_signal_connect( GTK_OBJECT (pDialogWnd), "expose_event", GTK_SIGNAL_FUNC( ci_expose ), NULL );
 
        pTooltips = gtk_tooltips_new();
 
index 55dd8e4dd58d083435c2e79be5fd901c77fbbcaa..6116ba5c73cfa70375ff6b3eac7dd473d9fe4daa 100644 (file)
@@ -163,7 +163,6 @@ bool DBobView::CalculateTrajectory( vec3_t start, vec3_t apex, float multiplier,
        VectorScale( dist, 1 / flight_time, speed );
        speed[2] = speed_z;
 
-//     Sys_Printf("Speed: (%.4f %.4f %.4f)\n", speed[0], speed[1], speed[2]);
 
        vec3_t* pPath = new vec3_t[points];
 
@@ -175,13 +174,6 @@ bool DBobView::CalculateTrajectory( vec3_t start, vec3_t apex, float multiplier,
                VectorScale( speed, ltime, pPath[i] );
                VectorAdd( pPath[i], start, pPath[i] );
 
-               // could do this all with vectors
-               // vGrav = {0, 0, -800.0f}
-               // VectorScale(vGrav, 0.5f*ltime*ltime, vAdd);
-               // VectorScale(speed, ltime, pPath[i]);
-               // _VectorAdd(pPath[i], start, pPath[i])
-               // _VectorAdd(pPath[i], vAdd, pPath[i])
-
                pPath[i][2] = start[2] + ( speed_z * ltime ) + ( varGravity * 0.5f * ltime * ltime );
        }
 
@@ -264,4 +256,4 @@ void DBobView_setEntity( Entity& entity, float multiplier, int points, float var
                globalErrorStream() << "bobToolz PathPlotter: Entity must have a targetname.\n";
        }
        return;
-}
\ No newline at end of file
+}
index 6daa23ca49cf52db18f61e1ac461a2932815625f..8e54f6fb5468139ba131ab0dc0faad41332b9d8f 100644 (file)
@@ -108,7 +108,6 @@ int DBrush::BuildPoints(){
 
                                        // otherwise point is removed due to another plane..
 
-                                       // Sys_Printf("(%f, %f, %f)\n", pnt[0], pnt[1], pnt[2]);
                                }
                        }
                }
index f46164c408f6290b9059d84fe048d6e3fa635b4c..c9090b27f5b2a9fd995e07903ee524b2347f9a8e 100644 (file)
@@ -259,7 +259,6 @@ DPatch* DPatch::MergePatches( patch_merge_t merge_info, DPatch *p1, DPatch *p2 )
                for ( int x = 0; x < p2->width; x++ )
                        newPatch->points[x][( y + p1->height - 1 )] = p2->points[x][y];
 
-//     newPatch->Invert();
        return newPatch;
 }
 
@@ -384,7 +383,6 @@ std::list<DPatch> DPatch::SplitCols(){
                }
        }
        else {
-               //globalErrorStream() << "bobToolz SplitPatchRows: Patch has not enough rows for splitting.\n";
                patchList.push_back( *this );
        }
        return patchList;
@@ -446,7 +444,6 @@ std::list<DPatch> DPatch::Split(){
        }
        else
        {
-               //globalErrorStream() << "bobToolz SplitPatchRows: Patch has not enough rows for splitting.\n";
                patchList.push_back( *this );
        }
        return patchList;
index 4699085450023e9040640183d7ab216ec993425a..009826de3f90fec70d16baa90ed8268ec594a98b 100644 (file)
@@ -104,7 +104,6 @@ bool DPlane::PlaneIntersection( DPlane *pl1, DPlane *pl2, vec3_t out ){
 bool DPlane::IsRedundant( std::list<DPoint*>& pointList ){
        int cnt = 0;
 
-       //std::list<DPoint *>::const_iterator point=pointList.begin();
        for ( std::list<DPoint *>::const_iterator point = pointList.begin(); point != pointList.end(); point++ )
        {
                if ( fabs( DistanceToPoint( ( *point )->_pnt ) ) < MAX_ROUND_ERROR ) {
index 8c675ff9476e77fe175f5d373471a0b547d9cded..cec4e3dca66a0b6aa9aafc6594628d8d110e66e7 100644 (file)
@@ -194,7 +194,6 @@ void DShape::BuildBorderedPrism( vec3_t min, vec3_t max, int nSides, int nBorder
        VectorScale( origin, 0.5f, origin );
 
        if ( nBorder >= Min( radius[0], radius[1] ) ) {
-//             DoMessageBox("Border is too large", "Error", MB_OK);
                return;
        }
 
index da7edcc1bd0ee568892cf4f4dc74653d87108027..a5456632ea29e39e035f163b420469fc1ce697b3 100644 (file)
@@ -241,7 +241,6 @@ void DTrainDrawer::BuildPaths() {
                if ( !pTarget ) {
                        globalOutputStream() << "couldn't find target " << pSP->strTarget;
                        return;
-//                     continue;
                }
 
                pSP->pTarget = pTarget;
index 6c8b09e90f185431e78c748a932e51eaf6e23527..d7b73f827458e32fcef6f742aebb2935422855da 100644 (file)
@@ -111,13 +111,6 @@ void SwapBSPFile( void ) {
        int i;
 
        // models
-//     SwapBlock( (int *)dmodels, nummodels * sizeof( dmodels[0] ) );
-
-       // shaders (don't swap the name)
-//     for ( i = 0 ; i < numShaders ; i++ ) {
-//             dshaders[i].contentFlags = LittleLong( dshaders[i].contentFlags );
-//             dshaders[i].surfaceFlags = LittleLong( dshaders[i].surfaceFlags );
-//     }
 
        // planes
        SwapBlock( (int *)dplanes, numplanes * sizeof( dplanes[0] ) );
@@ -159,16 +152,9 @@ void SwapBSPFile( void ) {
        }
 
        // drawindexes
-//     SwapBlock( (int *)drawIndexes, numDrawIndexes * sizeof( drawIndexes[0] ) );
 
        // drawsurfs
        SwapBlock( (int *)drawSurfaces, numDrawSurfaces * sizeof( drawSurfaces[0] ) );
-
-       // fogs
-//     for ( i = 0 ; i < numFogs ; i++ ) {
-//             dfogs[i].brushNum = LittleLong( dfogs[i].brushNum );
-//             dfogs[i].visibleSide = LittleLong( dfogs[i].visibleSide );
-//     }
 }
 
 /*
index aa8e64786a1eeba47bc8acc455514b706e1acfc4..cf98c47ce96f8c1045371382057bf1799ff9f70b 100644 (file)
@@ -101,7 +101,6 @@ void DoIntersect(){
 
        if ( rs.nBrushOptions == BRUSH_OPT_SELECTED ) {
                if ( GlobalSelectionSystem().countSelected() < 2 ) {
-                       //DoMessageBox("Invalid number of brushes selected, choose at least 2", "Error", eMB_OK);
                        globalErrorStream() << "bobToolz Intersect: Invalid number of brushes selected, choose at least 2.\n";
                        return;
                }
@@ -147,7 +146,6 @@ void DoPolygons(){
        UndoableCommand undo( "bobToolz.polygons" );
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of brushes selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz Polygons: Invalid number of brushes selected, choose 1 only.\n";
                return;
        }
@@ -155,7 +153,6 @@ void DoPolygons(){
        PolygonRS rs;
        scene::Instance& instance = GlobalSelectionSystem().ultimateSelected();
        if ( !Node_isBrush( instance.path().top() ) ) {
-               //DoMessageBox("No brush selected, select ONLY one brush", "Error", eMB_OK);
                globalErrorStream() << "bobToolz Polygons: No brush selected, select ONLY one brush.\n";
                return;
        }
@@ -247,7 +244,6 @@ void DoBuildStairs(){
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of brushes selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz BuildStairs: Invalid number of brushes selected, choose 1 only.\n";
                return;
        }
@@ -268,7 +264,6 @@ void DoBuildStairs(){
 
                if ( ( (int)size[2] % rs.stairHeight ) != 0 ) {
                        // stairs must fit evenly into brush
-                       //DoMessageBox("Invalid stair height\nHeight of block must be divisable by stair height", "Error", eMB_OK);
                        globalErrorStream() << "bobToolz BuildStairs: Invalid stair height. Height of block must be divisable by stair height.\n";
                }
                else
@@ -335,7 +330,6 @@ void DoBuildDoors(){
        UndoableCommand undo( "bobToolz.buildDoors" );
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of brushes selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz BuildDoors: Invalid number of brushes selected, choose 1 only.\n";
                return;
        }
@@ -379,7 +373,6 @@ void DoPathPlotter(){
        /*
           if( GlobalSelectionSystem().countSelected() != 1 )
           {
-           //DoMessageBox("Invalid number of brushes selected, choose 1 only", "Error", eMB_OK);
            globalOutputStream() << "bobToolz PathPlotter: Invalid number of entities selected, choose 1 trigger_push entity only.\n";
            return;
           }
@@ -396,7 +389,6 @@ void DoPitBuilder(){
        UndoableCommand undo( "bobToolz.pitBuilder" );
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of brushes selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz PitBuilder: Invalid number of brushes selected, choose 1 only.\n";
                return;
        }
@@ -406,7 +398,6 @@ void DoPitBuilder(){
        scene::Instance& instance = GlobalSelectionSystem().ultimateSelected();
        //seems it does this also with a patch with valid dimensions.. but probably better to enforce a brush.
        if ( !Node_isBrush( instance.path().top() ) ) {
-               //DoMessageBox("No brush selected, select ONLY one brush", "Error", eMB_OK);
                globalErrorStream() << "bobToolz PitBuilder: No brush selected, select ONLY 1 brush.\n";
                return;
        }
@@ -422,7 +413,6 @@ void DoPitBuilder(){
        }
        else
        {
-               //DoMessageBox("Failed To Make Pit\nTry Making The Brush Bigger", "Error", eMB_OK);
                globalErrorStream() << "bobToolz PitBuilder: Failed to make Pit, try making the brush bigger.\n";
        }
 }
@@ -436,7 +426,6 @@ void DoMergePatches(){
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 2 ) {
                globalErrorStream() << "bobToolz MergePatches: Invalid number of patches selected, choose 2 only.\n";
-               //DoMessageBox("Invalid number of patches selected, choose 2 only", "Error", eMB_OK);
                return;
        }
 
@@ -447,7 +436,6 @@ void DoMergePatches(){
        for ( i = 0; i < 2; i++ )
        {
                if ( !Node_isPatch( patches[i]->path().top() ) ) {
-                       //DoMessageBox("No patches selected, select ONLY patches", "Error", eMB_OK);
                        globalErrorStream() << "bobToolz MergePatches: Invalid number of patches selected, choose ONLY 2 patches.\n";
                        return;
                }
@@ -464,7 +452,6 @@ void DoMergePatches(){
        if ( merge_info.mergable ) {
                globalOutputStream() << merge_info.pos1 << " " <<  merge_info.pos2;
                //Message removed, No tools give feedback on success.
-               //globalOutputStream() << "bobToolz MergePatches: Patches Mergable.\n";
                DPatch* newPatch = mrgPatches[0].MergePatches( merge_info, &mrgPatches[0], &mrgPatches[1] );
 
                /*                mrgPatches[0].RemoveFromRadiant();
@@ -501,7 +488,6 @@ void DoSplitPatch() {
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of patches selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatch: Invalid number of patches selected, choose only 1 patch.\n";
                return;
        }
@@ -509,7 +495,6 @@ void DoSplitPatch() {
        scene::Instance& instance = GlobalSelectionSystem().ultimateSelected();
 
        if ( !Node_isPatch( instance.path().top() ) ) {
-               //DoMessageBox("No patch selected, select ONLY one patch", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatch: No patch selected, select ONLY 1 patch.\n";
                return;
        }
@@ -531,7 +516,6 @@ void DoSplitPatchCols() {
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of patches selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatchCols: Invalid number of patches selected, choose 1 only.\n";
                return;
        }
@@ -539,7 +523,6 @@ void DoSplitPatchCols() {
        scene::Instance& instance = GlobalSelectionSystem().ultimateSelected();
 
        if ( !Node_isPatch( instance.path().top() ) ) {
-               //DoMessageBox("No patch selected, select ONLY one patch", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatchCols: No patch selected, select ONLY 1 patch.\n";
                return;
        }
@@ -561,7 +544,6 @@ void DoSplitPatchRows() {
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of patches selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatchRows: Invalid number of patches selected, choose 1 only.\n";
                return;
        }
@@ -569,7 +551,6 @@ void DoSplitPatchRows() {
        scene::Instance& instance = GlobalSelectionSystem().ultimateSelected();
 
        if ( !Node_isPatch( instance.path().top() ) ) {
-               //DoMessageBox("No patch selected, select ONLY one patch", "Error", eMB_OK);
                globalErrorStream() << "bobToolz SplitPatchRows: No patch selected, select ONLY 1 patch.\n";
                return;
        }
@@ -597,7 +578,6 @@ void DoVisAnalyse(){
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 1 ) {
-               //DoMessageBox("Invalid number of objects selected, choose 1 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz VisAnalyse: Invalid number of objects selected, choose 1 only.\n";
                return;
        }
@@ -605,7 +585,6 @@ void DoVisAnalyse(){
        scene::Instance& brush = GlobalSelectionSystem().ultimateSelected();
        //ensure we have a brush selected
        if ( !Node_isBrush( brush.path().top() ) ) {
-               //DoMessageBox("No brush selected, select ONLY one brush", "Error", eMB_OK);
                globalErrorStream() << "bobToolz VisAnalyse: No brush selected, select ONLY 1 brush.\n";
                return;
        }
@@ -621,7 +600,6 @@ void DoVisAnalyse(){
 
        const char* rad_filename = GlobalRadiant().getMapName();
        if ( !rad_filename ) {
-               //DoMessageBox("An ERROR occurred while trying\n to get the map filename", "Error", eMB_OK);
                globalErrorStream() << "bobToolz VisAnalyse: An ERROR occurred while trying to get the map filename.\n";
                return;
        }
@@ -706,7 +684,6 @@ void DoFlipTerrain() {
 
        // ensure we have something selected
        if ( GlobalSelectionSystem().countSelected() != 2 ) {
-               //DoMessageBox("Invalid number of objects selected, choose 2 only", "Error", eMB_OK);
                globalErrorStream() << "bobToolz FlipTerrain: Invalid number of objects selected, choose 2 only.\n";
                return;
        }
@@ -718,7 +695,6 @@ void DoFlipTerrain() {
        for ( i = 0; i < 2; i++ )
        {
                if ( !Node_isBrush( brushes[i]->path().top() ) ) {
-                       //DoMessageBox("No brushes selected, select ONLY brushes", "Error", eMB_OK);
                        globalErrorStream() << "bobToolz FlipTerrain: No brushes selected, select ONLY 2 brushes.\n";
                        return;
                }
@@ -729,7 +705,6 @@ void DoFlipTerrain() {
        for ( i = 0; i < 2; i++ ) {
                Brushes[i].LoadFromBrush( *brushes[i], false );
                if ( !( Planes[i] = Brushes[i].FindPlaneWithClosestNormal( vUp ) ) || Brushes[i].FindPointsForPlane( Planes[i], Points[i], 3 ) != 3 ) {
-                       //DoMessageBox("Error", "Error", eMB_OK);
                        globalErrorStream() << "bobToolz FlipTerrain: ERROR (FindPlaneWithClosestNormal/FindPointsForPlane).\n";
                        return;
                }
@@ -757,7 +732,6 @@ void DoFlipTerrain() {
                found = false;
        }
        if ( dontmatch[0] == -1 ) {
-               //DoMessageBox("Error", "Error", eMB_OK);
                globalErrorStream() << "bobToolz FlipTerrain: ERROR (dontmatch[0]).\n";
                return;
        }
@@ -776,7 +750,6 @@ void DoFlipTerrain() {
                found = false;
        }
        if ( dontmatch[1] == -1 ) {
-               //DoMessageBox("Error", "Error", eMB_OK);
                globalErrorStream() << "bobToolz FlipTerrain: ERROR (dontmatch[1]).\n";
                return;
        }
index 977879f59e4b0fe4f239356eddef76aa623e87f3..4ba86d12675954f8936cb2eb3f357890c625f3dc 100644 (file)
@@ -52,7 +52,6 @@
         Global Vars
    ==========================*/
 
-//HANDLE bsp_process;
 char g_CurrentTexture[256] = "";
 
 //=============================================================
@@ -189,7 +188,6 @@ bool Q_Exec( const char *pCmd, bool bCreateConsole ){
        {
        case -1:
                return false;
-//      Error ("CreateProcess failed");
                break;
        case 0:
 #ifdef _DEBUG
@@ -198,7 +196,6 @@ bool Q_Exec( const char *pCmd, bool bCreateConsole ){
 #endif
                // NOTE: we could use that to detect when a step finishes. But then it
                // would not work for remote compiling stuff.
-//      execlp (pCmd, pCmd, NULL);
                system( pCmd );
                printf( "system() returned" );
                _exit( 0 );
index f466c5153558315b3a223d3419558b87982ee6f7..5558f9d613a9a0d54a978589b4f19f83698207e5 100644 (file)
@@ -592,7 +592,6 @@ void BuildDoorsX2( vec3_t min, vec3_t max,
        Node_getTraversable( GlobalSceneGraph().root() )->insert( pEDoor1 );
        Node_getTraversable( GlobalSceneGraph().root() )->insert( pEDoor2 );
 
-//     ResetCurrentTexture();
 }
 
 //-----------------------------------------------------------------------------------
@@ -629,12 +628,10 @@ void MakeBevel( vec3_t vMin, vec3_t vMax ){
                        PatchControl& p = matrix( i,2 - j );
                        PatchControl& q = matrix( i, j );
                        std::swap( p.m_vertex, q.m_vertex );
-                       //std::swap(p.m_texcoord, q.m_texcoord);
                }
        }
        GlobalPatchCreator().Patch_controlPointsChanged( patch );
        //TODO - the patch has textures weird, patchmanip.h has all function it needs.. lots of duplicate code..
-       //NaturalTexture(patch);
        Node_getTraversable( GlobalRadiant().getMapWorldEntity() )->insert( patch );
 }
 
@@ -642,7 +639,6 @@ void BuildCornerStairs( vec3_t vMin, vec3_t vMax, int nSteps, const char* mainTe
        vec3_t* topPoints = new vec3_t[nSteps + 1];
        vec3_t* botPoints = new vec3_t[nSteps + 1];
 
-       //bool bFacesUse[6] = {true, true, false, true, false, false};
 
        vec3_t centre;
        VectorCopy( vMin, centre );
index 629c163336688a4b1ca5808e84a0f7eef5617801..3ee41026384c84802325743e868a73d99d19471c 100644 (file)
@@ -14,7 +14,6 @@ typedef struct {
        int leafbytes;           //leafbytes = ((portalclusters+63)&~63)>>3;
 } vis_header;
 
-// added because int shift = 32; i = 0xFFFFFFFF >> shift;
 // then i = 0xFFFFFFFF, when it should = 0
 const unsigned long bitmasks[33] =
 {
index acd2fbd4fbda8cb08936ffc582d27a99669833c5..c23225ad771a637430798b781e7a22cc8df5848e 100644 (file)
@@ -66,7 +66,6 @@ static gint ci_new( GtkWidget *widget, gpointer data ){
        EMessageBoxReturn ret;
        int loop = 1;
        GSList *targetTypeRadio = NULL;
-//     char buf[128];
 
        // create the window
        window = gtk_window_new( GTK_WINDOW_TOPLEVEL );
@@ -646,16 +645,7 @@ void RefreshCamListCombo( void ){
        CCamera *combo_cam = firstCam;
        if ( combo_cam ) {
                while ( combo_cam ) {
-                       //combo_list = g_list_append( combo_list, (void *)combo_cam->GetCam()->getName() );
-                       //if( combo_cam->HasBeenSaved() ) {
                        combo_list = g_list_append( combo_list, (void *)combo_cam->GetFileName() );
-                       /*} else {
-                           char buf[128];
-                           sprintf( buf, "Unsaved Camera %i", combo_cam->GetCamNum() );
-                           combo_list = g_list_append( combo_list, (void *)buf );
-
-                           //combo_list = g_list_append( combo_list, (void *)combo_cam->GetCam()->getName() ); // FIXME: this requires camera.dll to create unique names for new cams
-                          }*/
                        combo_cam = combo_cam->GetNext();
                }
        }
@@ -669,7 +659,6 @@ void RefreshCamListCombo( void ){
        // select our current entry in the list
        if ( GetCurrentCam() ) {
                // stop editing on the current cam
-               //GetCurrentCam()->GetCam()->stopEdit();        // FIXME: this crashed on creating new cameras, why is it here?
 
                GList *li = GTK_LIST( GTK_COMBO( g_pCamListCombo )->list )->children;
                combo_cam = firstCam;
@@ -822,7 +811,6 @@ static gint ci_add( GtkWidget *widget, gpointer data ){
        EMessageBoxReturn ret;
        int i, loop = 1;
        GSList *eventTypeRadio = NULL;
-//     char buf[128];
 
        if ( !GetCurrentCam() ) {
                return TRUE;
@@ -931,7 +919,6 @@ static gint ci_add( GtkWidget *widget, gpointer data ){
 
                        if ( !camEventFlags[i][0] || ( str && str[0] ) ) {
                                int type = 0;
-//                             GList *li;
 
                                for ( type = 1; type < EVENT_COUNT; type++ ) {
                                        if ( gtk_toggle_button_get_active( (GtkToggleButton*)eventWidget[type] ) ) {
@@ -999,10 +986,8 @@ GtkWidget *CreateCameraInspectorDialog( void ){
        gtk_window_set_title( GTK_WINDOW( window ), "Camera Inspector" );
        gtk_signal_connect( GTK_OBJECT( window ), "delete_event", GTK_SIGNAL_FUNC( ci_close ), NULL );
        gtk_signal_connect( GTK_OBJECT( window ), "expose_event", GTK_SIGNAL_FUNC( ci_expose ), NULL );
-       //  gtk_signal_connect( GTK_OBJECT (window), "destroy", GTK_SIGNAL_FUNC( gtk_widget_destroy ), NULL );
        gtk_window_set_transient_for( GTK_WINDOW( window ), GTK_WINDOW( g_pRadiantWnd ) );
 
-       // don't use show, as you don't want to have it displayed on startup ;-)
        gtk_widget_realize( window );
 
        // fill the window
@@ -1260,7 +1245,6 @@ GtkWidget *CreateCameraInspectorDialog( void ){
 
        g_pEventsList = gtk_clist_new( 3 );
        gtk_container_add( GTK_CONTAINER( w ), g_pEventsList );
-       //gtk_signal_connect( GTK_OBJECT(g_pEventsList), "select_row", GTK_SIGNAL_FUNC (proplist_select_row), NULL);
        gtk_clist_set_selection_mode( GTK_CLIST( g_pEventsList ), GTK_SELECTION_BROWSE );
        gtk_clist_column_titles_hide( GTK_CLIST( g_pEventsList ) );
        gtk_clist_set_column_auto_resize( GTK_CLIST( g_pEventsList ), 0, TRUE );
index 4134a889eda465366e89e360b87173420e267b3a..dc43c540f316e298be4cf923f341f0cfef35a417 100644 (file)
@@ -121,7 +121,6 @@ void DoLoadCamera(){
                                        FreeCam( cam );
                                        sprintf( error, "Camera file \'%s\' is already loaded", fullpathtofile );
                                        g_FuncTable.m_pfnMessageBox( (GtkWidget *)g_pRadiantWnd, error, "Load error", eMB_OK );
-                                       //g_free( filename );
                                        return;
                                }
                                checkCam = checkCam->GetNext();
@@ -141,7 +140,6 @@ void DoLoadCamera(){
                                g_FuncTable.m_pfnMessageBox( (GtkWidget *)g_pRadiantWnd, error, "Load error", eMB_OK );
                        }
 
-                       //g_free( filename );
                }
                else {
                        g_FuncTable.m_pfnMessageBox( (GtkWidget *)g_pRadiantWnd, "No free camera slots available", "Load error", eMB_OK );
index b9f5fcf9a4d06eeba5b7ab9ebabed670e8dca8fc..0889dac491d81de44e3c30b74469d67abad8e846 100644 (file)
@@ -175,7 +175,6 @@ bool CListener::OnLButtonDown( unsigned int nFlags, double x, double y ){
 
        return true;
 
-       //return false;
 }
 
 bool CListener::OnLButtonUp( unsigned int nFlags, double x, double y ){
index 158a43020231cf432ad8c678aa3a06b08973eb18..dda98a02581bffcf1089ff46f9d12cb54ce62406 100644 (file)
@@ -217,8 +217,6 @@ void MakeDecimatedMap( int *NumNodes, int *NumTris, NODE **pNode, TRI **pTri ){
        }
        free( TriTable );
        // One last time (because we're pessimistic), check border triangles
-//     CheckBorders(&NumNodesUsed,NumNodes[0],Node,NumTris,pTri);
-//     Tri = *pTri;
 
        // Check that all fixed points are exact. If not, add them to the mix.
        // First check to see if we have any fixed points that aren't already used.
index 2bc90fe5ab8d6d2cfa07606e3444aecc2ed02859..d77807927a9f0d396b80f8fd4ff3630d726c3ccc 100644 (file)
@@ -28,7 +28,6 @@
 #define SIDE_BACK       1
 #define SIDE_CROSS      -2
 
-//vec3 vec3_origin = {0,0,0};
 
 void PlaneFromPoints( float *p0, float *p1, float *p2, PLANE *plane ){
        vec3 t1, t2;
@@ -176,7 +175,6 @@ MY_WINDING *BaseWindingForPlane( vec3 normal, vec dist ){
 
 void FreeWinding( MY_WINDING *w ){
        if ( *(unsigned *)w == 0xdeaddead ) {
-//             Error ("FreeWinding: freed a freed winding");
                return;
        }
        *(unsigned *)w = 0xdeaddead;
@@ -280,9 +278,7 @@ void ChopWindingInPlace( MY_WINDING **inout, vec3 normal, vec dist, vec epsilon
        }
 
 //     if (f->numpoints > maxpts)
-//             Error ("ClipWinding: points exceeded estimate");
 //     if (f->numpoints > MAX_POINTS_ON_WINDING)
-//             Error ("ClipWinding: MAX_POINTS_ON_WINDING");
 
        FreeWinding( in );
        *inout = f;
index 35004bfdcec88804af42509a54721982133a621b..76c21a3a46237ac3e6ecb323f353d65b8782b7ad 100644 (file)
@@ -220,7 +220,6 @@ void texfont_init(){
        g_GLTable.m_pfn_qglTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_WRAP_T, GL_REPEAT );
        g_GLTable.m_pfn_qglTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MIN_FILTER, GL_NEAREST );
        g_GLTable.m_pfn_qglTexParameteri( GL_TEXTURE_2D, GL_TEXTURE_MAG_FILTER, GL_NEAREST );
-       //  g_GLTable.m_pfn_qglPixelStorei (GL_UNPACK_ALIGNMENT, 1);
 
        unsigned char *buf = (unsigned char*)malloc( 128 * 128 );
        memset( buf, 255, 128 * 128 );
@@ -244,7 +243,6 @@ void texfont_write( const char *text, int l, int t ){
        g_GLTable.m_pfn_qglColor3f( 0, 1, 0 );
        g_GLTable.m_pfn_qglBindTexture( GL_TEXTURE_2D, texture );
        g_GLTable.m_pfn_qglEnable( GL_TEXTURE_2D );
-       //  g_GLTable.m_pfn_qglTexEnvi (GL_TEXTURE_ENV, GL_TEXTURE_ENV_MODE, GL_MODULATE);
        g_GLTable.m_pfn_qglAlphaFunc( GL_GREATER, 0.0625 );
        g_GLTable.m_pfn_qglEnable( GL_ALPHA_TEST );
 
index 3100ef4a42a6277738c7584058e6edb50a15f19d..b8c39efb934471af2348de99f38bcdf6742b0e93 100644 (file)
@@ -502,8 +502,6 @@ static void SetDlgValues( int tab ){
 }
 
 static void ReadDlgValues( int tab ){
-       //  char Text[256];
-       //  int i;
 
        switch ( tab )
        {
@@ -1265,7 +1263,6 @@ GtkWidget* create_main_dialog(){
        g_pWnd = dlg = gtk_window_new( GTK_WINDOW_TOPLEVEL );
        gtk_window_set_title( GTK_WINDOW( dlg ), gszCaption );
        g_signal_connect( G_OBJECT( dlg ), "delete_event", G_CALLBACK( main_close ), NULL );
-       //  g_signal_connect (G_OBJECT (dlg), "destroy", G_CALLBACK (gtk_widget_destroy), NULL);
        gtk_window_set_transient_for( GTK_WINDOW( dlg ), GTK_WINDOW( g_pRadiantWnd ) );
 
        hbox = gtk_hbox_new( FALSE, 5 );
index 377544cbec043266c0e641b60a9bc94014e7e9df..7d8d6ca1ce247e6284d263936817a8a2b6802027 100644 (file)
@@ -971,30 +971,18 @@ void MapBrushes(){
                                                        v[0].p[2] += HINT_OFFSET;
                                                        v[1].p[2] += HINT_OFFSET;
                                                        v[2].p[2] += HINT_OFFSET;
-//              v[3].p[2] = backface;
-//              v[4].p[2] = backface;
-//              v[5].p[2] = backface;
                                                        break;
                                                case PLANE_XY1:
                                                        v[0].p[2] -= HINT_OFFSET;
                                                        v[1].p[2] -= HINT_OFFSET;
                                                        v[2].p[2] -= HINT_OFFSET;
-//              v[3].p[2] = backface;
-//              v[4].p[2] = backface;
-//              v[5].p[2] = backface;
                                                        break;
                                                case PLANE_XZ0:
-//              v[0].p[1] = backface;
-//              v[1].p[1] = backface;
-//              v[2].p[1] = backface;
                                                        v[3].p[1] += HINT_OFFSET;
                                                        v[4].p[1] += HINT_OFFSET;
                                                        v[5].p[1] += HINT_OFFSET;
                                                        break;
                                                case PLANE_XZ1:
-//              v[0].p[1] = backface;
-//              v[1].p[1] = backface;
-//              v[2].p[1] = backface;
                                                        v[3].p[1] -= HINT_OFFSET;
                                                        v[4].p[1] -= HINT_OFFSET;
                                                        v[5].p[1] -= HINT_OFFSET;
@@ -1003,17 +991,11 @@ void MapBrushes(){
                                                        v[0].p[0] += HINT_OFFSET;
                                                        v[1].p[0] += HINT_OFFSET;
                                                        v[2].p[0] += HINT_OFFSET;
-//              v[3].p[0] = backface;
-//              v[4].p[0] = backface;
-//              v[5].p[0] = backface;
                                                        break;
                                                case PLANE_YZ1:
                                                        v[0].p[0] -= HINT_OFFSET;
                                                        v[1].p[0] -= HINT_OFFSET;
                                                        v[2].p[0] -= HINT_OFFSET;
-//              v[3].p[0] = backface;
-//              v[4].p[0] = backface;
-//              v[5].p[0] = backface;
                                                        break;
                                                }
                                                brush.Number   = N;
@@ -1120,8 +1102,6 @@ void GenerateXYZ(){
        int i0, i1, j0, j1;
        int ii, jj;
 
-//  FILE *f;
-//  char CSV[64];
 
        if ( !ValidSurface() ) {
                return;
index b28416e29bb485fceda4f2177c90dfc1dd2370b7..2d449389c4e1d667c520bcf22a8b2a06cd8005a2 100644 (file)
@@ -88,13 +88,7 @@ bounding_box PlayerBox[NUMGAMES] = { {{-16., 16.}, {-16., 16.}, {-24., 32.}},
                                                                         {{-16., 16.}, {-16., 16.}, {-24., 32.}},    // KingPin (guess)
                                                                         {{-30., 30.}, {-30., 30.}, {-10.,160.}},    // Genesis3D (no idea)
                                                                         {{-16., 16.}, {-16., 16.}, {-24., 32.}}};   // Quake3 (not sure)
-//char      gszOutputDir[NUMGAMES][NAME_MAX];
-//char      gszTextureDir[NUMGAMES][NAME_MAX];
 char Texture[NUMGAMES][3][64];
-//char      pakfile[NUMGAMES][NAME_MAX];
-//char      lastpakfile[NUMGAMES][NAME_MAX];
-//int       UsePak[NUMGAMES];
-//char      GameDir[NUMGAMES][NAME_MAX];
 
 char GameName[NUMGAMES][16] = {"Quake2", "Half-Life", "SiN", "Heretic2", "Kingpin", "Genesis3D", "Quake3" };
 
@@ -241,8 +235,6 @@ void ReadIniFile( const char *file ){
        NV = g_FuncTable.m_pfnProfileLoadInt( file, OPTS_SECTION,"NV",8 );
        NV = max( 1,min( NV,MAX_ROWS ) );
 
-//     Decimate   = GetPrivateProfileInt(OPTS_SECTION,"Decimate",0,file);
-//     Decimate = max(0,min(Decimate,100));
 
        AddHints          = g_FuncTable.m_pfnProfileLoadInt( file, OPTS_SECTION,"AddHints",0 );
        ArghRad2          = g_FuncTable.m_pfnProfileLoadInt( file, OPTS_SECTION,"ArghRad2",0 );
@@ -272,15 +264,9 @@ void ReadIniFile( const char *file ){
 
        for ( i = 0; i < NUMGAMES; i++ )
        {
-               //    strcpy (gszOutputDir[i], g_FuncTable.m_pfnProfileLoadString (file, GameName[i],"OutputDir",""));
                strcpy( Texture[i][0], g_FuncTable.m_pfnProfileLoadString( file, GameName[i], "Texture", "" ) );
                strcpy( Texture[i][1], g_FuncTable.m_pfnProfileLoadString( file, GameName[i], "Texture2", "" ) );
                strcpy( Texture[i][2], g_FuncTable.m_pfnProfileLoadString( file, GameName[i], "Texture3", "" ) );
-               //    strcpy (gszTextureDir[i], g_FuncTable.m_pfnProfileLoadString (file, GameName[i],"TextureDir",""));
-               //    UsePak[i] = GetPrivateProfileInt(GameName[i],"UsePak",0);
-               //    strcpy (pakfile[i], g_FuncTable.m_pfnProfileLoadString (file, GameName[i],"PakFile",""));
-               //    strcpy (lastpakfile[i], g_FuncTable.m_pfnProfileLoadString (file, GameName[i],"LastPakFile",""));
-               //    strcpy (GameDir[i], g_FuncTable.m_pfnProfileLoadString (file, GameName[i],"GameDir","\0"));
        }
        /*
           if(!strlen(gszTextureDir[QUAKE2]))
@@ -405,7 +391,6 @@ void WriteIniFile( const char *file ){
        g_FuncTable.m_pfnProfileSaveString( file, "Bitmap", "DefaultPath", gbmp.defpath );
        g_FuncTable.m_pfnProfileSaveString( file, "Bitmap", "BlackValue", va( "%g",gbmp.black_value ) );
        g_FuncTable.m_pfnProfileSaveString( file, "Bitmap", "WhiteValue", va( "%g",gbmp.white_value ) );
-//g_FuncTable.m_pfnProfileSaveString (file, "Formula", "Formula", ExcelFunc );
 }
 
 void UpdatePreview( bool DataChange ){
index ba0c43d5251c1ce7bf32a310582afc4b39e5d608..c51cce5513f8036fdae0f4d59fb43f395e45c394 100644 (file)
@@ -908,8 +908,6 @@ void DrawPreview( Rect rc ){
                                y = Vll + dv / 2;
                        }
                }
-//             x = (Hll+Hur)/2.;
-//             y = (Vll+Vur)/2.;
                v[0].p[0] = x + PlayerBox[Game].x[0];
                v[0].p[1] = y + PlayerBox[Game].y[0];
                v[0].p[2] = PlayerStartZ( x,y ) + PlayerBox[Game].z[0] + 8; // add 8 cuz I'm a pessimist
@@ -1177,8 +1175,6 @@ void project( XYZ *v ){
        y  = ct[2] * ya + st[2] * za;
 
        // horizontal and vertical projections:
-//     v->pp[0] = D*x/z;
-//     v->pp[1] = D*y/z;
        v->pp[0] = -y;
        v->pp[1] =  x;
        v->pp[2] =  z;
@@ -1186,8 +1182,6 @@ void project( XYZ *v ){
        // NOTE: if perspective transformation is desired,
        // set "persp" to the range from the surface,
        // then:
-       // v->projected_h = -v->projected_h * persp/(v->projected_z-persp);
-       // v->projected_v = -v->projected_v * persp/(v->projected_z-persp);
 }
 /*=======================================================================*/
 void evaluate(){
index 44393ea14f3fa0bd2d3199c0dbaccf821450f766..8e7499952c650124ca0ac764b8d9860af3609abd 100644 (file)
@@ -268,7 +268,6 @@ GSList *AddToWadList( GSList *wadlist, const char *shadername, const char *wad )
                        return wadlist;
                }
                ExtractFilePath( shadername,tmpstr );
-               // Sys_Printf("checking: %s\n",shadername);
 
                int l = strlen( tmpstr ) - 1;
 
@@ -333,7 +332,6 @@ void UpdateWadKeyPair( void ){
                        strcpy( wads,pEpair->value );
                        ConvertDOSToUnixName( wads,wads );
 
-                       // ok, we got the list of ; delimited wads, now split it into a GSList that contains
                        // just the wad names themselves.
 
                        p1 = wads;
@@ -406,7 +404,6 @@ void UpdateWadKeyPair( void ){
        g_FuncTable.m_pfnReleaseSelectedBrushHandles();
 
        // Now we have a complete list of wadnames (without paths) so we just have to turn this
-       // back to a ; delimited list.
 
        wads[0] = 0;
        while ( wadlist )
@@ -438,8 +435,6 @@ void UpdateWadKeyPair( void ){
 
        // store the wad list back in the worldspawn.
        if ( wads[0] ) {
-               //free(pEpair->value);
-               //pEpair->value = strdup(wads);
                SetKeyValue( pEntity, "wad", wads );
        }
 
index a896fcd4276e48ae18eee8d08ea66acea1655109..9da1760140dce3be6f34b081b2053c818486587b 100644 (file)
@@ -248,7 +248,6 @@ void CPortals::Load(){
                return;
        }
 
-//     node = new CBspNode[node_count];
        portal = new CBspPortal[portal_count];
        portal_sort = new int[portal_count];
 
index 50fb2cd8ee681f8abd93d02f2b3596c13251d966..3463441a8ee4cb8f744a0bfb2a8e26fd12e96a86 100644 (file)
@@ -148,7 +148,6 @@ gint grab_int_value( GtkSpinButton *a_spinner, gpointer user_data ) {
 
 // write the values of the Spinner-Boxes to the worldspawn
 static void set_coordinates( GtkWidget *widget, gpointer data ){
-       //Str str_min, str_max;
        char buffer[10], str_min[20], str_max[20];
 
        itoa( gtk_spin_button_get_value_as_int( msp.spinner1 ), str_min, 10 );
index db04d53e3c1a96d2a40c065ea073f06f4048d846..82e02c36ae3d5b0ec6bde599846ce947f42c358b 100644 (file)
@@ -32,7 +32,6 @@ public:
 int value;
 
 void printValue() const {
-       // print this->value here;
 }
 
 void setValue(){
@@ -68,7 +67,6 @@ namespace ExampleReferenceCaller
 {
 // ReferenceCaller example
 void Int_printValue( const int& value ){
-       // print value here;
 }
 
 void Int_setValue( int& value ){
index bba9ebe3434967f745066aa779cf3f9b89b96573..a2c3dd5df3a351c9ef705794fcc55d9db52263ac 100644 (file)
@@ -210,13 +210,11 @@ void globalQueuedAccelerators_remove( Accelerator accelerator ){
 void globalQueuedAccelerators_commit(){
        for ( AcceleratorSet::const_iterator i = g_queuedAcceleratorsRemove.begin(); i != g_queuedAcceleratorsRemove.end(); ++i )
        {
-               //globalOutputStream() << "removing: " << (*i).first << "\n";
                accel_group_remove_accelerator( global_accel, *i );
        }
        g_queuedAcceleratorsRemove.clear();
        for ( AcceleratorMap::const_iterator i = g_queuedAcceleratorsAdd.begin(); i != g_queuedAcceleratorsAdd.end(); ++i )
        {
-               //globalOutputStream() << "adding: " << (*i).first << "\n";
                accel_group_add_accelerator( global_accel, ( *i ).first, ( *i ).second );
        }
        g_queuedAcceleratorsAdd.clear();
@@ -364,12 +362,10 @@ void Keys_releaseAll( PressedKeys::Keys& keys, guint state ){
 }
 
 gboolean PressedKeys_key_press( GtkWidget* widget, GdkEventKey* event, PressedKeys* pressedKeys ){
-       //globalOutputStream() << "pressed: " << event->keyval << "\n";
        return event->state == 0 && Keys_press( pressedKeys->keys, event->keyval );
 }
 
 gboolean PressedKeys_key_release( GtkWidget* widget, GdkEventKey* event, PressedKeys* pressedKeys ){
-       //globalOutputStream() << "released: " << event->keyval << "\n";
        return Keys_release( pressedKeys->keys, event->keyval );
 }
 
@@ -412,39 +408,33 @@ void GlobalPressedKeys_disconnect( GtkWindow* window ){
 
 
 void special_accelerators_add( Accelerator accelerator, const Callback& callback ){
-       //globalOutputStream() << "special_accelerators_add: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_insert( g_special_accelerators, accelerator, callback ) ) {
                globalErrorStream() << "special_accelerators_add: already exists: " << makeQuoted( accelerator ) << "\n";
        }
 }
 void special_accelerators_remove( Accelerator accelerator ){
-       //globalOutputStream() << "special_accelerators_remove: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_erase( g_special_accelerators, accelerator ) ) {
                globalErrorStream() << "special_accelerators_remove: not found: " << makeQuoted( accelerator ) << "\n";
        }
 }
 
 void keydown_accelerators_add( Accelerator accelerator, const Callback& callback ){
-       //globalOutputStream() << "keydown_accelerators_add: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_insert( g_keydown_accelerators, accelerator, callback ) ) {
                globalErrorStream() << "keydown_accelerators_add: already exists: " << makeQuoted( accelerator ) << "\n";
        }
 }
 void keydown_accelerators_remove( Accelerator accelerator ){
-       //globalOutputStream() << "keydown_accelerators_remove: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_erase( g_keydown_accelerators, accelerator ) ) {
                globalErrorStream() << "keydown_accelerators_remove: not found: " << makeQuoted( accelerator ) << "\n";
        }
 }
 
 void keyup_accelerators_add( Accelerator accelerator, const Callback& callback ){
-       //globalOutputStream() << "keyup_accelerators_add: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_insert( g_keyup_accelerators, accelerator, callback ) ) {
                globalErrorStream() << "keyup_accelerators_add: already exists: " << makeQuoted( accelerator ) << "\n";
        }
 }
 void keyup_accelerators_remove( Accelerator accelerator ){
-       //globalOutputStream() << "keyup_accelerators_remove: " << makeQuoted(accelerator) << "\n";
        if ( !accelerator_map_erase( g_keyup_accelerators, accelerator ) ) {
                globalErrorStream() << "keyup_accelerators_remove: not found: " << makeQuoted( accelerator ) << "\n";
        }
@@ -458,7 +448,6 @@ gboolean accel_closure_callback( GtkAccelGroup* group, GtkWidget* widget, guint
 
 GClosure* accel_group_add_accelerator( GtkAccelGroup* group, Accelerator accelerator, const Callback& callback ){
        if ( accelerator.key != 0 && gtk_accelerator_valid( accelerator.key, accelerator.modifiers ) ) {
-               //globalOutputStream() << "global_accel_connect: " << makeQuoted(accelerator) << "\n";
                GClosure* closure = create_cclosure( G_CALLBACK( accel_closure_callback ), callback );
                gtk_accel_group_connect( group, accelerator.key, accelerator.modifiers, GTK_ACCEL_VISIBLE, closure );
                return closure;
@@ -472,7 +461,6 @@ GClosure* accel_group_add_accelerator( GtkAccelGroup* group, Accelerator acceler
 
 void accel_group_remove_accelerator( GtkAccelGroup* group, Accelerator accelerator ){
        if ( accelerator.key != 0 && gtk_accelerator_valid( accelerator.key, accelerator.modifiers ) ) {
-               //globalOutputStream() << "global_accel_disconnect: " << makeQuoted(accelerator) << "\n";
                gtk_accel_group_disconnect_key( group, accelerator.key, accelerator.modifiers );
        }
        else
@@ -494,7 +482,6 @@ void global_accel_destroy(){
 GClosure* global_accel_group_add_accelerator( Accelerator accelerator, const Callback& callback ){
        if ( !global_accel_enabled() ) {
                // workaround: cannot add to GtkAccelGroup while it is disabled
-               //globalOutputStream() << "queued for add: " << accelerator << "\n";
                globalQueuedAccelerators_add( accelerator, callback );
                return 0;
        }
@@ -502,7 +489,6 @@ GClosure* global_accel_group_add_accelerator( Accelerator accelerator, const Cal
 }
 void global_accel_group_remove_accelerator( Accelerator accelerator ){
        if ( !global_accel_enabled() ) {
-               //globalOutputStream() << "queued for remove: " << accelerator << "\n";
                globalQueuedAccelerators_remove( accelerator );
                return;
        }
index fc1e58d7bb955b4d06d9789a90b21b1a336275bf..a59b53f4241ef1776dff977e03b41b63a39c711e 100644 (file)
@@ -59,12 +59,7 @@ void button_set_icon( GtkButton* button, const char* icon ){
 }
 
 void toggle_button_set_active_no_signal( GtkToggleButton* button, gboolean active ){
-       //globalOutputStream() << "set active: " << active << "\n";
        guint handler_id = gpointer_to_int( g_object_get_data( G_OBJECT( button ), "handler" ) );
-       //guint signal_id = g_signal_lookup("toggled", G_OBJECT_TYPE (button));
-       //globalOutputStream() << "signal_id: " << signal_id << "\n";
-       //guint found = g_signal_handler_find(G_OBJECT(button), G_SIGNAL_MATCH_ID, signal_id, 0, 0, 0, 0);
-       //globalOutputStream() << " handler found: " << found << "\n";
        g_signal_handler_block( G_OBJECT( button ), handler_id );
        gtk_toggle_button_set_active( button, active );
        g_signal_handler_unblock( G_OBJECT( button ), handler_id );
@@ -86,9 +81,7 @@ GtkToggleButton* radio_button_get_nth( GtkRadioButton* radio, int index ){
 }
 
 void radio_button_set_active( GtkRadioButton* radio, int index ){
-       //radio_button_print_state(radio);
        gtk_toggle_button_set_active( radio_button_get_nth( radio, index ), TRUE );
-       //radio_button_print_state(radio);
 }
 
 void radio_button_set_active_no_signal( GtkRadioButton* radio, int index ){
@@ -108,7 +101,6 @@ void radio_button_set_active_no_signal( GtkRadioButton* radio, int index ){
 }
 
 int radio_button_get_active( GtkRadioButton* radio ){
-       //radio_button_print_state(radio);
        GSList *group = gtk_radio_button_group( radio );
        int index = g_slist_length( group ) - 1;
        for (; group != 0; group = g_slist_next( group ) )
index 59f5c5d9328161c359f4f37836eb38778c0fd7dd..ab74654a38afac4f0d75c816a1e37322e527c72f 100644 (file)
@@ -127,11 +127,6 @@ GtkWindow* create_fixedsize_modal_dialog_window( GtkWindow* parent, const char*
 
        window_remove_minmax( window );
 
-       //gtk_widget_set_size_request(GTK_WIDGET(window), width, height);
-       //gtk_window_set_default_size(window, width, height);
-       //gtk_window_resize(window, width, height);
-       //GdkGeometry geometry = { width, height, -1, -1, width, height, -1, -1, -1, -1, GDK_GRAVITY_STATIC, };
-       //gtk_window_set_geometry_hints(window, GTK_WIDGET(window), &geometry, (GdkWindowHints)(GDK_HINT_POS|GDK_HINT_MIN_SIZE|GDK_HINT_BASE_SIZE));
 
        return window;
 }
index d65d310ca567dc3eac3d47da95ccb6b946f37b56..dac409a37f9f566f188c72a1d4702e8afb64f0e3 100644 (file)
@@ -189,7 +189,6 @@ const char* file_dialog_show( GtkWidget* parent, bool open, const char* title, c
        }
 
        // we should add all important paths as shortcut folder...
-       // gtk_file_chooser_add_shortcut_folder(GTK_FILE_CHOOSER(dialog), "/tmp/", NULL);
 
 
        for ( std::size_t i = 0; i < masks.m_filters.size(); ++i )
index 09211a05450d3bd103dfb691ff8e6bfb9b04dde2..7d8de9ce97771df7c0fc4610ebf4a31cd4f2dbf6 100644 (file)
@@ -203,7 +203,6 @@ GLFontInternal( const char *_font_string ) : font_string( _font_string ){
 #endif
 
        font_desc = pango_font_description_from_string( font_string );
-       //pango_font_description_set_size(font_desc, 10 * PANGO_SCALE);
        pango_context_set_font_description( ft2_context, font_desc );
        pango_font_description_free( font_desc );
        // TODO fallback to fixed 8, courier new 8
index cbb07df8fef5518fbee2238258c9c05cb9b1d451..ef8e72d5369b1826d82340418b6bc22a36f88a30 100644 (file)
@@ -50,7 +50,6 @@ GtkMenuItem* menu_separator( GtkMenu* menu ){
 GtkTearoffMenuItem* menu_tearoff( GtkMenu* menu ){
        GtkTearoffMenuItem* menu_item = GTK_TEAROFF_MENU_ITEM( gtk_tearoff_menu_item_new() );
        container_add_widget( GTK_CONTAINER( menu ), GTK_WIDGET( menu_item ) );
-// gtk_widget_set_sensitive(GTK_WIDGET(menu_item), FALSE); -- controls whether menu is detachable
        gtk_widget_show( GTK_WIDGET( menu_item ) );
        return menu_item;
 }
index 8f9fb7fa02a812442f398b4927b0e70b6e8f6275..05dc2b2b29d069c98cb1f4c44d27f5e08a3c8510 100644 (file)
@@ -71,7 +71,6 @@ EMessageBoxReturn gtk_MessageBox( GtkWidget *parent, const char* text, const cha
        GtkWindow* window = create_fixedsize_modal_dialog_window( parentWindow, title, dialog, 400, 100 );
 
        if ( parentWindow != 0 ) {
-               //g_signal_connect(G_OBJECT(window), "delete_event", G_CALLBACK(floating_window_delete_present), parent);
                gtk_window_deiconify( parentWindow );
        }
 
index 0e4decf41f996bab050ffa28c6f927b0d667dfbe..fe2bd490245a4c3ca3c7c5f894cdce84643d990d 100644 (file)
@@ -53,7 +53,6 @@ void TestNewDelete(){
        {
                NamedAllocator<int> allocator( "test" );
                int* p = NamedNew<int>::type( allocator ).scalar();
-               //new int();
                NamedDelete<int>::type( allocator ).scalar( p );
        }
 
index 05cb3bf972c09d5b6723be51710b0c088f9fac5a..99f1999aa72641e0fc6cf3c0fbc1a3e4f8c0a443 100644 (file)
@@ -147,20 +147,16 @@ void glBox( idVec3 &color, idVec3 &point, float size ) {
 }
 
 void splineTest() {
-       //g_splineList->load("p:/doom/base/maps/test_base1.camera");
 }
 
 void splineDraw() {
-       //g_splineList->addToRenderer();
 }
 
 
-//extern void D_DebugLine( const idVec3 &color, const idVec3 &start, const idVec3 &end );
 
 void debugLine( idVec3 &color, float x, float y, float z, float x2, float y2, float z2 ) {
        idVec3 from( x, y, z );
        idVec3 to( x2, y2, z2 );
-       //D_DebugLine(color, from, to);
 }
 
 void idSplineList::addToRenderer() {
@@ -223,7 +219,6 @@ void idSplineList::addToRenderer() {
 }
 
 void idSplineList::buildSpline() {
-       //int start = Sys_Milliseconds();
        clearSpline();
        for ( int i = 3; i < controlPoints.Num(); i++ ) {
                for ( float tension = 0.0f; tension < 1.001f; tension += granularity ) {
@@ -239,7 +234,6 @@ void idSplineList::buildSpline() {
                }
        }
        dirty = false;
-       //Com_Printf("Spline build took %f seconds\n", (float)(Sys_Milliseconds() - start) / 1000);
 }
 
 
@@ -290,7 +284,6 @@ void idSplineList::draw( bool editMode ) {
                glEnd();
        }
        if ( count > 0 ) {
-               //assert(activeSegment >=0 && activeSegment < count);
                if ( activeSegment >= 0 && activeSegment < count ) {
                        glBox( activeColor, *splinePoints[activeSegment], 6 );
                        glBox( yellow, *splinePoints[activeSegment], 8 );
@@ -342,7 +335,6 @@ void idSplineList::initPosition( long bt, long totalTime ) {
        double distSoFar = 0.0;
        idVec3 temp;
        int count = splinePoints.Num();
-       //for(int i = 2; i < count - 1; i++) {
        for ( int i = 1; i < count; i++ ) {
                temp = *splinePoints[i - 1];
                temp -= *splinePoints[i];
@@ -399,7 +391,6 @@ const idVec3 *idSplineList::getPosition( long t ) {
                return &zero;
        }
 
-//     Com_Printf("Time: %d\n", t);
        assert( splineTime.Num() == splinePoints.Num() );
 
        while ( activeSegment < count ) {
@@ -428,7 +419,6 @@ const idVec3 *idSplineList::getPosition( long t ) {
 
 void idSplineList::parse( const char *( *text )  ) {
        const char *token;
-       //Com_MatchToken( text, "{" );
        do {
                token = Com_Parse( text );
 
@@ -469,16 +459,12 @@ void idSplineList::parse( const char *( *text )  ) {
                addPoint( point.x, point.y, point.z );
        } while ( 1 );
 
-       //Com_UngetToken();
-       //Com_MatchToken( text, "}" );
        dirty = true;
 }
 
 void idSplineList::write( fileHandle_t file, const char *p ) {
        idStr s = va( "\t\t%s {\n", p );
        FS_Write( s.c_str(), s.length(), file );
-       //s = va("\t\tname %s\n", name.c_str());
-       //FS_Write(s.c_str(), s.length(), file);
        s = va( "\t\t\tgranularity %f\n", granularity );
        FS_Write( s.c_str(), s.length(), file );
        int count = controlPoints.Num();
@@ -542,14 +528,9 @@ bool idCameraDef::getCameraInfo( long time, idVec3 &origin, idVec3 &direction, f
                        if ( events[i]->getType() == idCameraEvent::EVENT_TARGET ) {
                                setActiveTargetByName( events[i]->getParam() );
                                getActiveTarget()->start( startTime + events[i]->getTime() );
-                               //Com_Printf("Triggered event switch to target: %s\n",events[i]->getParam());
                        }
                        else if ( events[i]->getType() == idCameraEvent::EVENT_TRIGGER ) {
-                               //idEntity *ent = NULL;
-                               //ent = level.FindTarget( ent, events[i]->getParam());
                                //if (ent) {
-                               //      ent->signal( SIG_TRIGGER );
-                               //      ent->ProcessEvent( &EV_Activate, world );
                                //}
                        }
                        else if ( events[i]->getType() == idCameraEvent::EVENT_FOV ) {
@@ -560,7 +541,6 @@ bool idCameraDef::getCameraInfo( long time, idVec3 &origin, idVec3 &direction, f
                                float len = ( param2 ) ? atof( param2 ) : 0;
                                float newfov = ( param1 ) ? atof( param1 ) : 90;
                                fov.reset( fov.getFOV( time ), newfov, time, len );
-                               //*fv = fov = atof(events[i]->getParam());
                        }
                        else if ( events[i]->getType() == idCameraEvent::EVENT_FADEIN ) {
                                float time = atof( events[i]->getParam() );
@@ -629,11 +609,6 @@ bool idCameraDef::getCameraInfo( long time, idVec3 &origin, idVec3 &direction, f
 }
 
 bool idCameraDef::waitEvent( int index ) {
-       //for (int i = 0; i < events.Num(); i++) {
-       //      if (events[i]->getSegment() == index && events[i]->getType() == idCameraEvent::EVENT_WAIT) {
-       //              return true;
-       //      }
-       //}
        return false;
 }
 
@@ -715,7 +690,6 @@ void idCameraDef::buildCamera() {
                        break;
                }
                case idCameraEvent::EVENT_TARGETWAIT: {
-                       //targetWaits.Append(i);
                        break;
                }
                case idCameraEvent::EVENT_SPEED: {
@@ -784,9 +758,6 @@ void idCameraDef::startCamera( long t ) {
        cameraPosition->start( t );
        buildCamera();
        fov.reset( 90, 90, t, 0 );
-       //for (int i = 0; i < targetPositions.Num(); i++) {
-       //      targetPositions[i]->
-       //}
        startTime = t;
        cameraRunning = true;
 }
@@ -919,7 +890,6 @@ int idCameraDef::sortEvents( const void *p1, const void *p2 ) {
 
 void idCameraDef::addEvent( idCameraEvent *event ) {
        events.Append( event );
-       //events.Sort(&sortEvents);
 
 }
 void idCameraDef::addEvent( idCameraEvent::eventType t, const char *param, long time ) {
@@ -1044,9 +1014,6 @@ const idVec3 *idInterpolatedPosition::getPosition( long t ) {
                percent = 0.0;
        }
 
-       // the following line does a straigt calc on percentage of time
-       // float percent = (float)(startTime + time - t) / time;
-
        idVec3 v1 = startPos;
        idVec3 v2 = endPos;
        v1 *= ( 1.0 - percent );
index 62fdaedc50f6f5905beb1b22977841568ab7d0bb..0a447da10fddccb5a319fc5d723fba92e245dbcc 100644 (file)
@@ -495,7 +495,6 @@ void TestStringClass
        delete t;                           // t == ?
 
        a = c;                              // a.len == 4, a.data == "test\0"
-//   a = "";
        a = NULL;                           // a.len == 0, a.data == "\0"                                       ASSERT!
        a = c + d;                          // a.len == 8, a.data == "testtest\0"
        a = c + "wow";                      // a.len == 7, a.data == "testwow\0"
index d65b890498a540826d8810caa5d1d0debf6ab8a0..b0d9b6cbb741260d8e278d89b4c1d161247c78d4 100644 (file)
@@ -1350,7 +1350,6 @@ public:
 TypeCasts(){
        m_casts = TargetableInstance::StaticTypeCasts::instance().get();
        InstanceContainedCast<LightInstance, Bounded>::install( m_casts );
-       //InstanceContainedCast<LightInstance, Cullable>::install(m_casts);
        InstanceStaticCast<LightInstance, Renderable>::install( m_casts );
        InstanceStaticCast<LightInstance, SelectionTestable>::install( m_casts );
        InstanceStaticCast<LightInstance, Transformable>::install( m_casts );
@@ -1440,7 +1439,6 @@ void evaluateTransform(){
        }
        else
        {
-               //globalOutputStream() << getTranslation() << "\n";
 
                m_dragPlanes.m_bounds = m_contained.aabb();
                m_contained.setLightRadius( m_dragPlanes.evaluateResize( getTranslation(), rotation() ) );
index 51dbfd7e916409764e448fc21e1f169bd2873534..133e501d67229902e4582d3073ae09fe8672a246 100644 (file)
@@ -176,9 +176,6 @@ Image* LoadMIPBuff( byte* buffer ){
 
        RGBAImage* image = new RGBAImage( columns, rows );
 
-       //Sys_Printf("lpMip->width = %i, lpMip->height = %i, lpMip->offsets[0] = %i, lpMip->offsets[1] = %i, lpMip->offsets[2] = %i, lpMip->offsets[3] = %i, numPixels = %i\n", lpMip->width, lpMip->height, lpMip->offsets[0], lpMip->offsets[1], lpMip->offsets[2], lpMip->offsets[3], numPixels);
-       //for (i = 0; i < sizeof(*lpMip); i++)
-       //  Sys_Printf("%02x", (int) ((unsigned char *)lpMip)[i]);
 
        pixbuf = image->getRGBAPixels();
 
index efdcfa70a7aeeb88091a7e4e4821d86fdbecbb43..c220023a3812832e0773f562eb6673bd2d772e6b 100644 (file)
@@ -156,8 +156,6 @@ Image* LoadIDSPBuff( byte *buffer ){
                globalErrorStream() << "WARNING: IDSP file has multiple frames, only the first frame will be used.\n";
        }
 
-       // palette = buffer+mipdatasize+2;
-       // buf_p = buffer+lpMip->offsets[0];
 
        numPixels = columns * rows;
 
index 56a18ddc254e5e435221805a89adfd1563882c9b..18d3e7759857fdd07ac3af07df9bdf4704b49943 100644 (file)
@@ -250,9 +250,7 @@ void MD2Surface_read( Model& model, const byte* buffer, ArchiveFile& file ){
                        }
                        path[i] = '\0';
                }
-//     globalErrorStream() << "modified skinname: " << path << " (path) and " << skinnameRelative << " (texture)" << "\n";
                snprintf( skinname, MD2_MAX_SKINNAME, "%s%s", path, &skinnameRelative[1] );
-//     globalErrorStream() << skinname << "\n";
        }
        else
        {
index 3ab4e9e0754273f611a01c6fe0d18f99cf27152e..9a4f31604ebb4f6aa3c55a5efc8509ca70db576f 100644 (file)
@@ -75,10 +75,7 @@ void Texture_InitPalette( byte *pal ){
                b = gammatable[pal[2]];
                pal += 3;
 
-               //v = (r<<24) + (g<<16) + (b<<8) + 255;
-               //v = BigLong (v);
 
-               //mdl_palette[i] = v;
                mdl_palette[i * 3 + 0] = r;
                mdl_palette[i * 3 + 1] = g;
                mdl_palette[i * 3 + 2] = b;
index c3dbb6e630df5a04a1ada80939a981223e34e689..1378defa2c9a847c85a9a1d953e1f4dd3b68b4a0 100644 (file)
@@ -352,7 +352,6 @@ void CopyPicoModel( picoModel_t* model ){
 
        /* each surface on the model will become a new map drawsurface */
        int numSurfaces = PicoGetModelNumSurfaces( model );
-       //%  SYs_FPrintf( SYS_VRB, "Model %s has %d surfaces\n", name, numSurfaces );
        for ( int s = 0; s < numSurfaces; ++s )
        {
                /* get surface */
index 61e77628530ff65e8118ff2d1836b868d2d64914..dee948f8c1984075155168583161b9e3528ca2fa 100644 (file)
@@ -57,7 +57,6 @@ void PicoPrintFunc( int level, const char *str ){
                break;
 
        case PICO_VERBOSE:
-               //globalOutputStream() << "PICO_VERBOSE: " << str << "\n";
                break;
 
        case PICO_WARNING:
index 72757fca8dfef769a24e4870f5693a6d6b54dd46..de2c635a57020deb8660900fbc80e4ab3c390393 100644 (file)
@@ -1667,7 +1667,6 @@ void Shaders_Load(){
                }
        }
 
-       //StringPool_analyse(ShaderPool::instance());
 }
 
 void Shaders_Free(){
index 513b4584590a254309a54934705eb92984dd94e7..aab6380c2a78e6bc9c00b1cb17ffb504040ff9b0 100644 (file)
@@ -42,8 +42,6 @@ void LoadSpriteModel( entity_interfaces_t *interfaces, const char *name ){
        model->Construct( pShader );
        interfaces->pRender = (IRender*)model;
        interfaces->pRender->IncRef();
-       //interfaces->pSelect = (ISelect*)model;
-       //interfaces->pSelect->IncRef();
        interfaces->pSelect = NULL;
        interfaces->pEdit = NULL;
        model->DecRef();
@@ -69,13 +67,10 @@ void CSpriteModel::Construct( IShader *pShader ){
 
 CSpriteModel::CSpriteModel(){
        refCount = 1;
-       //m_nSurfaces = 0;
-       //m_children = NULL;
        m_pShader = NULL;
 }
 
 CSpriteModel::~CSpriteModel(){
-       // if(m_children) delete[] m_children;
        if ( m_pShader ) {
                m_pShader->DecRef();
        }
@@ -103,11 +98,8 @@ void CSpriteModel::Draw( int state, int rflags ) const {
        // setup opengl stuff
 
        g_QglTable.m_pfn_qglPushAttrib( GL_ALL_ATTRIB_BITS ); // GL_ENABLE_BIT
-       //g_QglTable.m_pfn_qglColor3f (1,1,1);   //testing
-       //g_QglTable.m_pfn_qglColor4f (1,1,1,1); //testing
        g_QglTable.m_pfn_qglBindTexture( GL_TEXTURE_2D, q->texture_number );
 
-       //g_QglTable.m_pfn_qglEnable (GL_TEXTURE_2D); // FIXME: ? this forces textures, even in wireframe mode, bad... ?
 
        g_QglTable.m_pfn_qglAlphaFunc( GL_LESS, 1 );
        g_QglTable.m_pfn_qglEnable( GL_ALPHA_TEST );
index fe42687cc640d12bb2e877cea69c4f669074407e..da20cbf26657e0ad37c20108eae8ff335ee4a8e8 100644 (file)
@@ -140,7 +140,6 @@ void QE_CheckAutoSave( void ){
                if ( g_AutoSave_Enabled ) {
                        const char* strMsg = g_SnapShots_Enabled ? "Autosaving snapshot..." : "Autosaving...";
                        globalOutputStream() << strMsg << "\n";
-                       //Sys_Status(strMsg);
 
                        // only snapshot if not working on a default map
                        if ( g_SnapShots_Enabled && !Map_Unnamed( g_map ) ) {
@@ -168,7 +167,6 @@ void QE_CheckAutoSave( void ){
                else
                {
                        globalOutputStream() << "Autosave skipped...\n";
-                       //Sys_Status ("Autosave skipped...");
                }
        }
 }
index bb03f43a41ce5106324ddbd2fd4b837ac09e1b17..bf0824dae61ebc1f4af1d7ab7497c979df61474b 100644 (file)
@@ -76,7 +76,6 @@ bool operator==( const ProximalVertex& other ) const {
                        return true;
                }
                v = v->m_next;
-               //ASSERT_MESSAGE(DEBUG_LOOP < c_brush_maxFaces, "infinite loop");
                if ( !( DEBUG_LOOP < c_brush_maxFaces ) ) {
                        break;
                }
index 5a02f8fe95da26ea4a0114d67a32f8e59204e3d6..2ca44ec1b2f2b1f172725b64a8253f0eea61eafe 100644 (file)
@@ -171,7 +171,6 @@ inline void Texdef_fromTransform( texdef_t& texdef, float width, float height, c
                        texdef.scale[1] = -texdef.scale[1];
                }
        }
-       //globalOutputStream() << "fromTransform: " << texdef.shift[0] << " " << texdef.shift[1] << " " << texdef.scale[0] << " " << texdef.scale[1] << " " << texdef.rotate << "\n";
 }
 
 inline void BPTexdef_fromTransform( brushprimit_texdef_t& bp_texdef, const Matrix4& transform ){
@@ -200,7 +199,6 @@ inline void Texdef_normalise( texdef_t& texdef, float width, float height ){
        // it may be useful to also normalise the rotation here, if this function is used elsewhere.
        texdef.shift[0] = float_mod( texdef.shift[0], width );
        texdef.shift[1] = float_mod( texdef.shift[1], height );
-       //globalOutputStream() << "normalise: " << texdef.shift[0] << " " << texdef.shift[1] << " " << texdef.scale[0] << " " << texdef.scale[1] << " " << texdef.rotate << "\n";
 }
 
 inline void BPTexdef_normalise( brushprimit_texdef_t& bp_texdef, float width, float height ){
@@ -236,7 +234,6 @@ void Texdef_basisForNormal( const TextureProjection& projection, const Vector3&
                ComputeAxisBase( normal, vector4_to_vector3( basis.x() ), vector4_to_vector3( basis.y() ) );
                vector4_to_vector3( basis.z() ) = normal;
                matrix4_transpose( basis );
-               //DebugAxisBase(normal);
        }
        else if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
                basis = g_matrix4_identity;
@@ -244,7 +241,6 @@ void Texdef_basisForNormal( const TextureProjection& projection, const Vector3&
                vector4_to_vector3( basis.y() ) = vector3_negated( projection.m_basis_t );
                vector4_to_vector3( basis.z() ) = vector3_normalised( vector3_cross( vector4_to_vector3( basis.x() ), vector4_to_vector3( basis.y() ) ) );
                matrix4_multiply_by_matrix4( basis, matrix4_rotation_for_z_degrees( -projection.m_texdef.rotate ) );
-               //globalOutputStream() << "debug: " << projection.m_basis_s << projection.m_basis_t << normal << "\n";
                matrix4_transpose( basis );
        }
        else
@@ -824,13 +820,10 @@ inline Matrix4 matrix4_reflection_for_plane45( const Plane3& plane, const Vector
 }
 
 void Texdef_transformLocked( TextureProjection& projection, std::size_t width, std::size_t height, const Plane3& plane, const Matrix4& identity2transformed ){
-       //globalOutputStream() << "identity2transformed: " << identity2transformed << "\n";
 
-       //globalOutputStream() << "plane.normal(): " << plane.normal() << "\n";
 
        Vector3 normalTransformed( matrix4_transformed_direction( identity2transformed, plane.normal() ) );
 
-       //globalOutputStream() << "normalTransformed: " << normalTransformed << "\n";
 
        // identity: identity space
        // transformed: transformation
@@ -842,7 +835,6 @@ void Texdef_transformLocked( TextureProjection& projection, std::size_t width, s
 
        Matrix4 identity2stIdentity;
        Texdef_basisForNormal( projection, plane.normal(), identity2stIdentity );
-       //globalOutputStream() << "identity2stIdentity: " << identity2stIdentity << "\n";
 
        if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_HALFLIFE ) {
                matrix4_transform_direction( identity2transformed, projection.m_basis_s );
@@ -862,10 +854,7 @@ void Texdef_transformLocked( TextureProjection& projection, std::size_t width, s
        Texdef_toTransform( projection, (float)width, (float)height, stIdentity2stOriginal );
        Matrix4 identity2stOriginal( matrix4_multiplied_by_matrix4( stIdentity2stOriginal, identity2stIdentity ) );
 
-       //globalOutputStream() << "originalProj: " << originalProjectionAxis << "\n";
-       //globalOutputStream() << "transformedProj: " << transformedProjectionAxis << "\n";
        double dot = vector3_dot( originalProjectionAxis, transformedProjectionAxis );
-       //globalOutputStream() << "dot: " << dot << "\n";
        if ( dot == 0 ) {
                // The projection axis chosen for the transformed normal is at 90 degrees
                // to the transformed projection axis chosen for the original normal.
index bdd6416d5f27b6e085861d6f39b248f659220b1d..bcf0d41d8f6c31b98e2a553efddb5aef8c88255f 100644 (file)
@@ -438,7 +438,6 @@ XMLElementParser& pushElement( const XMLElement& element ){
        }
        else
        {
-               //ERROR_MESSAGE("parse error: invalid element \"" << element.name() << "\"");
                return *this;
        }
 }
index a9f19224b76c23bfe123dce4beaa4cd319acf0e5..785af5468655f3a46b6fd2f6fdf493fc77bb2eb6 100644 (file)
@@ -353,7 +353,6 @@ void Cam_MouseControl( camera_t& camera, int x, int y ){
 }
 
 void Camera_mouseMove( camera_t& camera, int x, int y ){
-       //globalOutputStream() << "mousemove... ";
        Camera_FreeMove( camera, -x, -y );
        camera.m_update();
        CameraMovedNotify();
@@ -422,7 +421,6 @@ void Cam_KeyControl( camera_t& camera, float dtime ){
 void Camera_keyMove( camera_t& camera ){
        camera.m_mouseMove.flush();
 
-       //globalOutputStream() << "keymove... ";
        float time_seconds = camera.m_keycontrol_timer.elapsed_msec() / static_cast<float>( msec_per_sec );
        camera.m_keycontrol_timer.start();
        if ( time_seconds > 0.05f ) {
@@ -831,7 +829,6 @@ gboolean selection_button_release( GtkWidget* widget, GdkEventButton* event, Win
 }
 
 void selection_motion( gdouble x, gdouble y, guint state, void* data ){
-       //globalOutputStream() << "motion... ";
        reinterpret_cast<WindowObserver*>( data )->onMouseMotion( WindowVector_forDouble( x, y ), modifiers_for_state( state ) );
 }
 
@@ -1236,7 +1233,6 @@ static gboolean camwindow_freemove_focusout( GtkWidget* widget, GdkEventFocus* e
 }
 
 void CamWnd::EnableFreeMove(){
-       //globalOutputStream() << "EnableFreeMove\n";
 
        ASSERT_MESSAGE( !m_bFreeMove, "EnableFreeMove: free-move was already enabled" );
        m_bFreeMove = true;
@@ -1253,7 +1249,6 @@ void CamWnd::EnableFreeMove(){
 }
 
 void CamWnd::DisableFreeMove(){
-       //globalOutputStream() << "DisableFreeMove\n";
 
        ASSERT_MESSAGE( m_bFreeMove, "DisableFreeMove: free-move was not enabled" );
        m_bFreeMove = false;
@@ -1394,8 +1389,6 @@ void CamWnd::Cam_Draw(){
                ambient[3] = 1.0f;
                diffuse[0] = diffuse[1] = diffuse[2] = 0.4f;
                diffuse[3] = 1.0f;
-               //material[0] = material[1] = material[2] = 0.8f;
-               //material[3] = 1.0f;
 
                inverse_cam_dir[0] = m_Camera.vpn[0];
                inverse_cam_dir[1] = m_Camera.vpn[1];
@@ -1515,13 +1508,11 @@ void CamWnd::Cam_Draw(){
 void CamWnd::draw(){
        m_drawing = true;
 
-       //globalOutputStream() << "draw...\n";
        if ( glwidget_make_current( m_gl_widget ) != FALSE ) {
                if ( Map_Valid( g_map ) && ScreenUpdates_Enabled() ) {
                        GlobalOpenGL_debugAssertNoErrors();
                        Cam_Draw();
                        GlobalOpenGL_debugAssertNoErrors();
-                       //qglFinish();
 
                        m_XORRectangle.set( rectangle_t() );
                }
index 44a5e2e35678af824109279b7f19db1607796cd8..9e4462b96950f33d5567fd0528768ce64958e915 100644 (file)
@@ -230,7 +230,6 @@ void accelerator_edit_button_clicked( GtkButton *btn, gpointer dialogptr ){
        dialog.m_model = model;
 
        // 2. disallow changing the row
-       //gtk_widget_set_sensitive(GTK_WIDGET(dialog.m_list), false);
 
        // 3. highlight the row
        gtk_list_store_set( GTK_LIST_STORE( model ), &iter, 2, true, -1 );
index 72a64140fd0ba4af78aa8475cd06bb89551ea87e..d260c935725d3ba283ae05817d7391bb553a0e8f 100644 (file)
@@ -121,11 +121,9 @@ GtkWidget* Console_constructWindow( GtkWindow* toplevel ){
                gtk_widget_show( text );
                g_console = text;
 
-               //globalExtendedASCIICharacterSet().print();
 
                widget_connect_escape_clear_focus_widget( g_console );
 
-               //g_consoleWidgetFocusPrinter.connect(g_console);
 
                g_signal_connect( G_OBJECT( g_console ), "populate-popup", G_CALLBACK( console_populate_popup ), 0 );
                g_signal_connect( G_OBJECT( g_console ), "destroy", G_CALLBACK( destroy_set_null ), &g_console );
index db65063a50ea28fefc99aaee562c74e43511a59c..5b014193de9b775fe1a92eeeb2e36bbd12710b8d 100644 (file)
@@ -252,7 +252,6 @@ EntityClassQuake3() : m_unrealised( 4 ){
 }
 void realise(){
        if ( --m_unrealised == 0 ) {
-               //globalOutputStream() << "Entity Classes: realise\n";
                EntityClassQuake3_Construct();
                m_observers.realise();
        }
@@ -260,7 +259,6 @@ void realise(){
 void unrealise(){
        if ( ++m_unrealised == 1 ) {
                m_observers.unrealise();
-               //globalOutputStream() << "Entity Classes: unrealise\n";
                Eclass_Clear();
        }
 }
index f9598e4b9d094707ff541de9b505474350be745c..8e1163b01a5ebb041ee559566de4469782806f26 100644 (file)
@@ -123,7 +123,6 @@ bool EntityClassDoom3_parseUnknown( Tokeniser& tokeniser ){
        //const char* name =
        PARSE_RETURN_FALSE_IF_FAIL( EntityClassDoom3_parseToken( tokeniser ) );
 
-       //globalOutputStream() << "parsing unknown block " << makeQuoted(name) << "\n";
 
        PARSE_RETURN_FALSE_IF_FAIL( EntityClassDoom3_parseToken( tokeniser, "{" ) );
        tokeniser.nextLine();
@@ -370,7 +369,6 @@ static bool EntityClass_parse( EntityClass& entityClass, Tokeniser& tokeniser ){
                        }
                }
                else if ( string_equal( key, "editor_ragdoll" ) ) {
-                       //bool ragdoll = atoi(tokeniser.getToken()) != 0;
                        PARSE_RETURN_FALSE_IF_FAIL( EntityClassDoom3_parseToken( tokeniser ) );
                }
                else if ( string_equal( key, "editor_mins" ) ) {
index 7b87791520b4c5365acf8d92fbafe8383bf5a33d..c8ba41e623fdb7da0c8d790b796ed73c8d64e366 100644 (file)
@@ -63,8 +63,6 @@ EntityClass* EntityClassFGD_insertUniqueBase( EntityClass* entityClass ){
        std::pair<BaseClasses::iterator, bool> result = g_EntityClassFGD_bases.insert( BaseClasses::value_type( entityClass->name(), entityClass ) );
        if ( !result.second ) {
                globalErrorStream() << "duplicate base class: " << makeQuoted( entityClass->name() ) << "\n";
-               //eclass_capture_state(entityClass);
-               //entityClass->free(entityClass);
        }
        return ( *result.first ).second;
 }
index c7cf0dac09ba2e6f9e353b13e62a09d09c96af58..0ae8dc191ee85b1e119a3296971019789b1ce889 100644 (file)
@@ -170,8 +170,6 @@ void post( const scene::Path& path, scene::Instance& instance ) const {
 class EntityGroupSelected : public scene::Graph::Walker
 {
 NodeSmartReference group, worldspawn;
-//typedef std::pair<NodeSmartReference, NodeSmartReference> DeletionPair;
-//Stack<DeletionPair> deleteme;
 public:
 EntityGroupSelected( const scene::Path &p ) : group( p.top().get() ), worldspawn( Map_FindOrInsertWorldspawn( g_map ) ){
 }
@@ -193,7 +191,6 @@ void post( const scene::Path& path, scene::Instance& instance ) const {
                                Node_getTraversable( group )->insert( child );
 
                                if ( Node_getTraversable( parent )->empty() ) {
-                                       //deleteme.push(DeletionPair(parentparent, parent));
                                        Node_getTraversable( parentparent )->erase( parent );
                                }
                        }
index 5c1c330b913f7d6966550eb10dc7ff2db07741c3..7d79aa3e9f61f6a2292d91f69ca02f4fb967686e 100644 (file)
@@ -1576,7 +1576,6 @@ EntityInspector() : m_unrealised( 1 ){
 void realise(){
        if ( --m_unrealised == 0 ) {
                if ( g_entityInspector_windowConstructed ) {
-                       //globalOutputStream() << "Entity Inspector: realise\n";
                        EntityClassList_fill();
                }
        }
@@ -1584,7 +1583,6 @@ void realise(){
 void unrealise(){
        if ( ++m_unrealised == 1 ) {
                if ( g_entityInspector_windowConstructed ) {
-                       //globalOutputStream() << "Entity Inspector: unrealise\n";
                        EntityClassList_clear();
                }
        }
index 4fdc5b4ea6e83f0f20c45085aa4c0141f3336be2..0e100a5afc6e1f9177cf5914e2769b61c787f9f0 100644 (file)
@@ -120,7 +120,6 @@ void entitylist_treeviewcolumn_celldatafunc( GtkTreeViewColumn* column, GtkCellR
                char* name = const_cast<char*>( node_get_name( *node ) );
                g_object_set( G_OBJECT( renderer ), "text", name, "visible", TRUE, 0 );
 
-               //globalOutputStream() << "rendering cell " << makeQuoted(name) << "\n";
                GtkStyle* style = gtk_widget_get_style( GTK_WIDGET( getEntityList().m_tree_view ) );
                if ( instance->childSelected() ) {
                        g_object_set( G_OBJECT( renderer ), "cell-background-gdk", &style->base[GTK_STATE_ACTIVE], 0 );
index daa0f31c5f1be2b3e3d7f65740df5dd8febe6e23..fbdf34a23b852bc0f2e5b2dcb5fc367ad912cfe6 100644 (file)
@@ -941,7 +941,6 @@ EMessageBoxReturn DoShaderTagDlg( CopiedString* tag, char* title ){
                        GtkVBox* vbox = create_dialog_vbox( 4 );
                        gtk_box_pack_start( GTK_BOX( hbox ), GTK_WIDGET( vbox ), TRUE, TRUE, 0 );
                        {
-                               //GtkLabel* label = GTK_LABEL(gtk_label_new("Enter one ore more tags separated by spaces"));
                                GtkLabel* label = GTK_LABEL( gtk_label_new( "ESC to cancel, ENTER to validate" ) );
                                gtk_widget_show( GTK_WIDGET( label ) );
                                gtk_box_pack_start( GTK_BOX( vbox ), GTK_WIDGET( label ), FALSE, FALSE, 0 );
index 1b68860931f12fc6335c08b2aae5d98da3e48ec6..95e559dbde11a3a00f260a1580404b00862b45c6 100644 (file)
@@ -1223,8 +1223,6 @@ void Selection_Clone(){
 
                Scene_Clone_Selected( GlobalSceneGraph(), false );
 
-               //NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
-               //NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
        }
 }
 
@@ -1234,8 +1232,6 @@ void Selection_Clone_MakeUnique(){
 
                Scene_Clone_Selected( GlobalSceneGraph(), true );
 
-               //NudgeSelection(eNudgeRight, GetGridSize(), GlobalXYWnd_getCurrentViewType());
-               //NudgeSelection(eNudgeDown, GetGridSize(), GlobalXYWnd_getCurrentViewType());
        }
 }
 
@@ -1640,16 +1636,12 @@ bool redrawRequired(){
 }
 
 bool MainFrame_isActiveApp(){
-       //globalOutputStream() << "listing\n";
        GList* list = gtk_window_list_toplevels();
        for ( GList* i = list; i != 0; i = g_list_next( i ) )
        {
-               //globalOutputStream() << "toplevel.. ";
                if ( gtk_window_is_active( GTK_WINDOW( i->data ) ) ) {
-                       //globalOutputStream() << "is active\n";
                        return true;
                }
-               //globalOutputStream() << "not active\n";
        }
        return false;
 }
@@ -1697,13 +1689,11 @@ void ScreenUpdates_Enable(){
        g_wait_stack.pop_back();
        if ( g_wait_stack.empty() ) {
                EverySecondTimer_enable();
-               //gtk_widget_set_sensitive(GTK_WIDGET(MainFrame_getWindow()), TRUE);
 
                gtk_grab_remove( GTK_WIDGET( g_wait.m_window ) );
                destroy_floating_window( g_wait.m_window );
                g_wait.m_window = 0;
 
-               //gtk_window_present(MainFrame_getWindow());
        }
        else if ( GTK_WIDGET_VISIBLE( g_wait.m_window ) ) {
                gtk_label_set_text( g_wait.m_label, g_wait_stack.back().c_str() );
@@ -2176,7 +2166,6 @@ void Patch_registerShortcuts(){
        command_connect_accelerator( "PatchDeleteLastColumn" );
        command_connect_accelerator( "PatchDeleteLastRow" );
        command_connect_accelerator( "NaturalizePatch" );
-       //command_connect_accelerator("CapCurrentCurve");
 }
 
 void Manipulators_registerShortcuts(){
@@ -2203,10 +2192,6 @@ void TexdefNudge_registerShortcuts(){
 void SelectNudge_registerShortcuts(){
        command_connect_accelerator( "MoveSelectionDOWN" );
        command_connect_accelerator( "MoveSelectionUP" );
-       //command_connect_accelerator("SelectNudgeLeft");
-       //command_connect_accelerator("SelectNudgeRight");
-       //command_connect_accelerator("SelectNudgeUp");
-       //command_connect_accelerator("SelectNudgeDown");
 }
 
 void SnapToGrid_registerShortcuts(){
@@ -2349,7 +2334,6 @@ GtkToolbar* create_main_toolbar( MainFrame::EViewStyle style ){
        GtkButton* g_view_console_button = toolbar_append_button( toolbar, "Console (O)", "console.png", "ToggleConsole" );
        GtkButton* g_view_textures_button = toolbar_append_button( toolbar, "Texture Browser (T)", "texture_browser.png", "ToggleTextures" );
        // TODO: call light inspector
-       //GtkButton* g_view_lightinspector_button = toolbar_append_button(toolbar, "Light Inspector", "lightinspector.png", "ToggleLightInspector");
 
        gtk_toolbar_append_space( GTK_TOOLBAR( toolbar ) );
        GtkButton* g_refresh_models_button = toolbar_append_button( toolbar, "Refresh Models", "refresh_models.png", "RefreshReferences" );
@@ -2816,7 +2800,6 @@ void MainFrame::Create(){
 
        EverySecondTimer_enable();
 
-       //GlobalShortcuts_reportUnregistered();
 }
 
 void MainFrame::SaveWindowInfo(){
index b61a038af566460ba1b28f640c09ef20fc471a98..dfa6ce4e962e2981b50f2f23c5fc1d97c5eed4fa 100644 (file)
@@ -94,13 +94,11 @@ CopiedString m_name;
 
 void construct(){
        if ( !empty() ) {
-               //globalOutputStream() << "construct " << makeQuoted(c_str()) << "\n";
                m_names.insert( name_read( c_str() ) );
        }
 }
 void destroy(){
        if ( !empty() ) {
-               //globalOutputStream() << "destroy " << makeQuoted(c_str()) << "\n";
                m_names.erase( name_read( c_str() ) );
        }
 }
@@ -143,12 +141,10 @@ void attach( const NameCallback& setName, const NameCallbackCallback& attachObse
        std::pair<Names::iterator, bool> result = m_names.insert( Names::value_type( setName, m_uniqueNames ) );
        ASSERT_MESSAGE( result.second, "cannot attach name" );
        attachObserver( NameObserver::NameChangedCaller( ( *result.first ).second ) );
-       //globalOutputStream() << "attach: " << reinterpret_cast<const unsigned int&>(setName) << "\n";
 }
 void detach( const NameCallback& setName, const NameCallbackCallback& detachObserver ){
        Names::iterator i = m_names.find( setName );
        ASSERT_MESSAGE( i != m_names.end(), "cannot detach name" );
-       //globalOutputStream() << "detach: " << reinterpret_cast<const unsigned int&>(setName) << "\n";
        detachObserver( NameObserver::NameChangedCaller( ( *i ).second ) );
        m_names.erase( i );
 }
@@ -179,7 +175,6 @@ void mergeNames( const BasicNamespace& other ) const {
                char buffer[1024];
                name_write( buffer, uniqueName );
 
-               //globalOutputStream() << "renaming " << makeQuoted((*i).first.c_str()) << " to " << makeQuoted(buffer) << "\n";
 
                SetNameCallbacks& setNameCallbacks = ( *i ).second;
 
@@ -968,7 +963,6 @@ void Map_LoadFile( const char *filename ){
        globalOutputStream() << Unsigned( g_brushCount.get() ) << " primitive\n";
        globalOutputStream() << Unsigned( g_entityCount.get() ) << " entities\n";
 
-       //GlobalEntityCreator().printStatistics();
 
        //
        // move the view to a start position
@@ -1210,14 +1204,12 @@ bool Map_Save(){
    ===========
  */
 void Map_New(){
-       //globalOutputStream() << "Map_New\n";
 
        g_map.m_name = "unnamed.map";
        Map_UpdateTitle( g_map );
 
        {
                g_map.m_resource = GlobalReferenceCache().capture( g_map.m_name.c_str() );
-//    ASSERT_MESSAGE(g_map.m_resource->getNode() == 0, "bleh");
                g_map.m_resource->attach( g_map );
 
                SceneChangeNotify();
index 2ea79216a3d6f18e052e2d49917ba734b44de11b..ab28bbbd9b6e306fa9294d7ef0e3462b84ddc386 100644 (file)
@@ -387,9 +387,7 @@ void Patch::Smooth( EMatrixMajor mt ){
        {
                p1 = m_ctrl.data() + ( h * row_stride );
                p2 = p1 + ( 2 * width ) * col_stride;
-               //globalErrorStream() << "compare " << p1->m_vertex << " and " << p2->m_vertex << "\n";
                if ( vector3_length_squared( vector3_subtracted( p1->m_vertex, p2->m_vertex ) ) > 1.0 ) {
-                       //globalErrorStream() << "too far\n";
                        wrap = false;
                        break;
                }
@@ -1329,9 +1327,6 @@ void Patch::ConstructPrefab( const AABB& aabb, EPatchPrefab eType, int axis, std
                int n = ( width - 1 ) / 2; // n = number of segments
                setDims( width, height );
 
-               // vPos[0] = vector3_subtracted(aabb.origin, aabb.extents);
-               // vPos[1] = aabb.origin;
-               // vPos[2] = vector3_added(aabb.origin, aabb.extents);
 
                int i, j;
                float f = 1 / cos( M_PI / n );
@@ -1355,9 +1350,6 @@ void Patch::ConstructPrefab( const AABB& aabb, EPatchPrefab eType, int axis, std
                int n = ( width - 1 ) / 2; // n = number of segments
                setDims( width, height );
 
-               // vPos[0] = vector3_subtracted(aabb.origin, aabb.extents);
-               // vPos[1] = aabb.origin;
-               // vPos[2] = vector3_added(aabb.origin, aabb.extents);
 
                int i, j;
                float f = 1 / cos( M_PI / n );
@@ -1382,9 +1374,6 @@ void Patch::ConstructPrefab( const AABB& aabb, EPatchPrefab eType, int axis, std
                int m = ( height - 1 ) / 2; // m = number of segments (pitch)
                setDims( width, height );
 
-               // vPos[0] = vector3_subtracted(aabb.origin, aabb.extents);
-               // vPos[1] = aabb.origin;
-               // vPos[2] = vector3_added(aabb.origin, aabb.extents);
 
                int i, j;
                float f = 1 / cos( M_PI / n );
@@ -2004,8 +1993,6 @@ void Patch::TesselateSubMatrix( const BezierCurveTree *BX, const BezierCurveTree
        }
 
 
-       //if((nFlagsX & DEGEN_0a) && (nFlagsX & DEGEN_1a) && (nFlagsX & DEGEN_2a)) { newFlagsX |= DEGEN_0a; newFlagsX |= DEGEN_1a; newFlagsX |= DEGEN_2a; }
-       //if((nFlagsX & DEGEN_0b) && (nFlagsX & DEGEN_1b) && (nFlagsX & DEGEN_2b)) { newFlagsX |= DEGEN_0b; newFlagsX |= DEGEN_1b; newFlagsX |= DEGEN_2b; }
 
        newFlagsX |= ( nFlagsX & SPLIT );
        newFlagsX |= ( nFlagsX & AVERAGE );
@@ -2443,8 +2430,6 @@ void Patch::BuildVertexArray(){
                                m_tess.m_indices[( j * m_tess.m_lenStrips ) + i * 2] = RenderIndex( j * m_tess.m_nArrayWidth + i );
                                m_tess.m_indices[( j * m_tess.m_lenStrips ) + i * 2 + 1] = RenderIndex( ( j + 1 ) * m_tess.m_nArrayWidth + i );
                                // reverse because radiant uses CULL_FRONT
-                               //m_tess.m_indices[(j*m_tess.m_lenStrips)+i*2+1] = RenderIndex(j*m_tess.m_nArrayWidth+i);
-                               //m_tess.m_indices[(j*m_tess.m_lenStrips)+i*2] = RenderIndex((j+1)*m_tess.m_nArrayWidth+i);
                        }
                }
        }
@@ -2460,8 +2445,6 @@ void Patch::BuildVertexArray(){
                                m_tess.m_indices[( j * m_tess.m_lenStrips ) + i * 2] = RenderIndex( ( ( m_tess.m_nArrayHeight - 1 ) - i ) * m_tess.m_nArrayWidth + j );
                                m_tess.m_indices[( j * m_tess.m_lenStrips ) + i * 2 + 1] = RenderIndex( ( ( m_tess.m_nArrayHeight - 1 ) - i ) * m_tess.m_nArrayWidth + j + 1 );
                                // reverse because radiant uses CULL_FRONT
-                               //m_tess.m_indices[(j*m_tess.m_lenStrips)+i*2+1] = RenderIndex(((m_tess.m_nArrayHeight-1)-i)*m_tess.m_nArrayWidth+j);
-                               //m_tess.m_indices[(j*m_tess.m_lenStrips)+i*2] = RenderIndex(((m_tess.m_nArrayHeight-1)-i)*m_tess.m_nArrayWidth+j+1);
 
                        }
                }
index 5014e975e05739664e2280079447c19a8dd1fccf..c513207d9118a20ee5880cf81c099d44826fafe9 100644 (file)
@@ -264,8 +264,6 @@ bool visible(){
        return GTK_WIDGET_VISIBLE( GetWidget() );
 }
 
-//  void UpdateInfo();
-//  void SetPatchInfo();
 void GetPatchInfo();
 void UpdateSpinners( bool bUp, int nID );
 // read the current patch on map and initialize m_fX m_fY accordingly
@@ -815,7 +813,6 @@ GtkWindow* PatchInspector::BuildDialog(){
                                        }
                                        {
                                                GtkEntry* entry = GTK_ENTRY( gtk_entry_new() );
-                                               //  gtk_entry_set_editable (GTK_ENTRY (entry), false);
                                                gtk_widget_show( GTK_WIDGET( entry ) );
                                                gtk_box_pack_start( GTK_BOX( vbox2 ), GTK_WIDGET( entry ), TRUE, TRUE, 0 );
                                                AddDialogData( *entry, m_strName );
@@ -1116,7 +1113,6 @@ void PatchInspector::GetPatchInfo(){
        }
        else
        {
-               //globalOutputStream() << "WARNING: no patch\n";
        }
        // fill in our internal structs
        m_nRow = 0; m_nCol = 0;
index 909e3466311f966e23e11e9af66ddea22f221764..6560002db18c234b3de41fa7bfe4db2be55f5ef2 100644 (file)
@@ -577,7 +577,6 @@ void Patch_Transpose(){
 
 void Patch_Cap(){
        // FIXME: add support for patch cap creation
-       // Patch_CapCurrent();
        UndoableCommand undo( "patchCreateCaps" );
 
        Scene_PatchDoCap_Selected( GlobalSceneGraph(), TextureBrowser_GetSelectedShader( GlobalTextureBrowser() ) );
index 6cc9d7ca61b7be01e0fcfb20f2c849a04c3b808a..262fee355b32751a9c31c9167afc707ce904d122 100644 (file)
@@ -172,7 +172,6 @@ typedef int ( QGL_DLLEXPORT * QGLFunctionPointer )();
 
 QGLFunctionPointer QGL_getExtensionFunc( const char* symbol ){
 #if defined( XWINDOWS )
-       //ASSERT_NOTNULL(qglXGetProcAddressARB);
        if ( qglXGetProcAddressARB == 0 ) {
                return reinterpret_cast<QGLFunctionPointer>( glInvalidFunction );
        }
index dc5c52cabdddf8999ac0c9a2c570f961bb311b85..16807dfe298d123c80b54bd0e28a972bf1e38594 100644 (file)
@@ -99,7 +99,6 @@ NodeSmartReference MapResource_load( const MapFormat& format, const char* path,
 }
 
 bool MapResource_saveFile( const MapFormat& format, scene::Node& root, GraphTraversalFunc traverse, const char* filename ){
-       //ASSERT_MESSAGE(path_is_absolute(filename), "MapResource_saveFile: path is not absolute: " << makeQuoted(filename));
        globalOutputStream() << "Open file " << filename << " for write...";
        TextFileOutputStream file( filename );
        if ( !file.failed() ) {
@@ -266,7 +265,6 @@ ModelCache::iterator ModelCache_insert( const char* path, const char* name, scen
 void ModelCache_flush( const char* path, const char* name ){
        ModelCache::iterator i = g_modelCache.find( ModelKey( path, name ) );
        if ( i != g_modelCache.end() ) {
-               //ASSERT_MESSAGE((*i).value.getCount() == 0, "resource flushed while still in use: " << (*i).key.first.c_str() << (*i).key.second.c_str());
                g_modelCache.erase( i );
        }
 }
@@ -419,7 +417,6 @@ struct ModelResource : public Resource
                {
                        return m_model.get_pointer();
                }
-               //return 0;
        }
        void setNode( scene::Node* node ){
                ModelCache::iterator i = ModelCache_find( m_path.c_str(), m_name.c_str() );
@@ -451,7 +448,6 @@ struct ModelResource : public Resource
                        m_path = rootPath( m_originalName.c_str() );
                        m_name = path_make_relative( m_originalName.c_str(), m_path.c_str() );
 
-                       //globalOutputStream() << "ModelResource::realise: " << m_path.c_str() << m_name.c_str() << "\n";
 
                        m_observers.realise();
                }
@@ -460,7 +456,6 @@ struct ModelResource : public Resource
                if ( ++m_unrealised == 1 ) {
                        m_observers.unrealise();
 
-                       //globalOutputStream() << "ModelResource::unrealise: " << m_path.c_str() << m_name.c_str() << "\n";
                        clearModel();
                }
        }
@@ -559,12 +554,10 @@ void clear(){
 }
 
 Resource* capture( const char* path ){
-       //globalOutputStream() << "capture: \"" << path << "\"\n";
        return m_references.capture( CopiedString( path ) ).get();
 }
 void release( const char* path ){
        m_references.release( CopiedString( path ) );
-       //globalOutputStream() << "release: \"" << path << "\"\n";
 }
 
 void setEntityCreator( EntityCreator& entityCreator ){
index 166ddc89ab53482b59041cbb9e7cb0f31a27d440..206daca643466ccf49b645f896c3fac18b8396c2 100644 (file)
@@ -1285,8 +1285,6 @@ void OpenGLState_apply( const OpenGLState& self, OpenGLState& current, unsigned
        }
 
        if ( delta & state & RENDER_FILL ) {
-               //qglPolygonMode (GL_BACK, GL_LINE);
-               //qglPolygonMode (GL_FRONT, GL_FILL);
                glPolygonMode( GL_FRONT_AND_BACK, GL_FILL );
                GlobalOpenGL_debugAssertNoErrors();
        }
@@ -1546,7 +1544,6 @@ void Renderables_flush( OpenGLStateBucket::Renderables& renderables, OpenGLState
        glPushMatrix();
        for ( OpenGLStateBucket::Renderables::const_iterator i = renderables.begin(); i != renderables.end(); ++i )
        {
-               //qglLoadMatrixf(i->m_transform);
                if ( !transform || ( transform != ( *i ).m_transform && !matrix4_affine_equal( *transform, *( *i ).m_transform ) ) ) {
                        count_transform();
                        transform = ( *i ).m_transform;
index 1f885cff9e16d73c7dd6b7945abb53a2e5be87a1..dc98a0762aa234dd9da025ee2239d62cf24c09fa 100644 (file)
@@ -96,7 +96,6 @@ scene::Node& root(){
        return m_rootpath.top();
 }
 void insert_root( scene::Node& root ){
-       //globalOutputStream() << "insert_root\n";
 
        ASSERT_MESSAGE( m_rootpath.empty(), "scenegraph root already exists" );
 
@@ -107,7 +106,6 @@ void insert_root( scene::Node& root ){
        m_rootpath.push( makeReference( root ) );
 }
 void erase_root(){
-       //globalOutputStream() << "erase_root\n";
 
        ASSERT_MESSAGE( !m_rootpath.empty(), "scenegraph root does not exist" );
 
index a79004e7361e40f03c398658d112d46f3ef45922..ea9b5240f662dae6ad5d5eb6c3b0bc8c9f0881db 100644 (file)
@@ -533,7 +533,6 @@ void Select_ShiftTexture( float x, float y ){
                Scene_BrushShiftTexdef_Selected( GlobalSceneGraph(), x, y );
                Scene_PatchTranslateTexture_Selected( GlobalSceneGraph(), x, y );
        }
-       //globalOutputStream() << "shift selected face textures: s=" << x << " t=" << y << '\n';
        Scene_BrushShiftTexdef_Component_Selected( GlobalSceneGraph(), x, y );
 }
 
index ccb164924f2c1908210b659188cc980e0b91f140..2028637029bd418a8a7afb631caa50de6bffee24 100644 (file)
@@ -110,9 +110,7 @@ bool sphere_intersect_ray( const Vector3& origin, float radius, const Ray& ray,
 
 void ray_intersect_ray( const Ray& ray, const Ray& other, Vector3& intersection ){
        intersection = vector3_subtracted( ray.origin, other.origin );
-       //float a = 1;//vector3_dot(ray.direction, ray.direction);        // always >= 0
        double dot = vector3_dot( ray.direction, other.direction );
-       //float c = 1;//vector3_dot(other.direction, other.direction);        // always >= 0
        double d = vector3_dot( ray.direction, intersection );
        double e = vector3_dot( other.direction, intersection );
        double D = 1 - dot * dot; //a*c - dot*dot;       // always >= 0
@@ -2853,7 +2851,6 @@ void SelectArea( const View& view, const float device_point[2], const float devi
 
 void translate( const Vector3& translation ){
        if ( !nothingSelected() ) {
-               //ASSERT_MESSAGE(!m_pivotChanged, "pivot is invalid");
 
                m_translation = translation;
 
@@ -2876,7 +2873,6 @@ void outputTranslation( TextOutputStream& ostream ){
 }
 void rotate( const Quaternion& rotation ){
        if ( !nothingSelected() ) {
-               //ASSERT_MESSAGE(!m_pivotChanged, "pivot is invalid");
 
                m_rotation = rotation;
 
index 11a423b0d32c835075907f86c2935a97f13814ba..23e679b2b09452fd25971972dccc70e0a9364391 100644 (file)
@@ -247,7 +247,6 @@ void SurfaceInspector_updateSelection(){
 #if TEXTOOL_ENABLED
        if ( g_bp_globals.m_texdefTypeId == TEXDEFTYPEID_BRUSHPRIMITIVES ) {
                TexTool::queueDraw();
-               //globalOutputStream() << "textool texture changed..\n";
        }
 #endif
 }
@@ -374,7 +373,6 @@ static void OnBtnMatchGrid( GtkWidget *widget, gpointer data ){
 
 // DoSurface will always try to show the surface inspector
 // or update it because something new has been selected
-// Shamus: It does get called when the SI is hidden, but not when you select something new. ;-)
 void DoSurface( void ){
        if ( getSurfaceInspector().GetWidget() == 0 ) {
                getSurfaceInspector().Create();
@@ -417,12 +415,9 @@ static void OnBtnPatchFit( GtkWidget *widget, gpointer data ){
 }
 
 static void OnBtnAxial( GtkWidget *widget, gpointer data ){
-//globalOutputStream() << "--> [OnBtnAxial]...\n";
        UndoableCommand undo( "textureDefault" );
        TextureProjection projection;
-//globalOutputStream() << "    TexDef_Construct_Default()...\n";
        TexDef_Construct_Default( projection );
-//globalOutputStream() << "    Select_SetTexdef()...\n";
 
 #if TEXTOOL_ENABLED
 
@@ -908,7 +903,6 @@ GtkWindow* SurfaceInspector::BuildDialog(){
                                gtk_box_pack_start( GTK_BOX( vbox ), GTK_WIDGET( frame ), TRUE, TRUE, 0 );
                                {
                                        GtkVBox* vbox3 = GTK_VBOX( gtk_vbox_new( FALSE, 4 ) );
-                                       //gtk_container_set_border_width(GTK_CONTAINER(vbox3), 4);
                                        gtk_widget_show( GTK_WIDGET( vbox3 ) );
                                        gtk_container_add( GTK_CONTAINER( frame ), GTK_WIDGET( vbox3 ) );
                                        {
@@ -943,7 +937,6 @@ GtkWindow* SurfaceInspector::BuildDialog(){
                                gtk_box_pack_start( GTK_BOX( vbox ), GTK_WIDGET( frame ), TRUE, TRUE, 0 );
                                {
                                        GtkVBox* vbox3 = GTK_VBOX( gtk_vbox_new( FALSE, 4 ) );
-                                       //gtk_container_set_border_width(GTK_CONTAINER(vbox3), 4);
                                        gtk_widget_show( GTK_WIDGET( vbox3 ) );
                                        gtk_container_add( GTK_CONTAINER( frame ), GTK_WIDGET( vbox3 ) );
                                        {
@@ -1035,11 +1028,8 @@ GtkWindow* SurfaceInspector::BuildDialog(){
 
 //Instead of this, we probably need to create a vbox to put into the frame, then the
 //window, then the hbox. !!! FIX !!!
-//        gtk_container_add(GTK_CONTAINER(frame), hbox);
 
 //Hmm. Do we really need g_object_set_data? Mebbe not... And we don't! :-)
-//        g_object_set_data(G_OBJECT(flipX), "handler", gint_to_pointer(g_signal_connect(G_OBJECT(flipX), "toggled", G_CALLBACK(TexTool::flipX), 0)));
-//        g_object_set_data(G_OBJECT(flipY), "handler", gint_to_pointer(g_signal_connect(G_OBJECT(flipY), "toggled", G_CALLBACK(TexTool::flipY), 0)));
 //Instead, just do:
                                g_signal_connect( G_OBJECT( flipX ), "toggled", G_CALLBACK( TexTool::flipX ), NULL );
                                g_signal_connect( G_OBJECT( flipY ), "toggled", G_CALLBACK( TexTool::flipY ), NULL );
@@ -1488,7 +1478,6 @@ struct Extent
        float height( void ) { return fabs( maxY - minY ); }
 };
 
-//This seems to control the texture scale... (Yep! ;-)
 Extent extents = { -2.0f, -2.0f, +2.0f, +2.0f };
 brushprimit_texdef_t tm;                        // Texture transform matrix
 Vector2 pts[c_brush_maxFaces];
@@ -1501,8 +1490,6 @@ Vector2 windowSize;
 #define PI          3.14159265358979
 bool lButtonDown = false;
 bool rButtonDown = false;
-//int dragPoint;
-//int anchorPoint;
 bool haveAnchor = false;
 brushprimit_texdef_t currentBP;
 brushprimit_texdef_t origBP;                    // Original brush primitive (before we muck it up)
@@ -1539,7 +1526,6 @@ void CopyPointsFromSelectedFace( void ){
        textureNum = face.getShader().m_state->getTexture().texture_number;
        textureSize.x() = face.getShader().m_state->getTexture().width;
        textureSize.y() = face.getShader().m_state->getTexture().height;
-//globalOutputStream() << "--> Texture #" << textureNum << ": " << textureSize.x() << " x " << textureSize.y() << "...\n";
 
        currentBP = SurfaceInspector_GetSelectedTexdef().m_brushprimit_texdef;
 
@@ -1549,7 +1535,6 @@ void CopyPointsFromSelectedFace( void ){
 
        for ( Winding::const_iterator i = w.begin(); i != w.end(); i++ )
        {
-               //globalOutputStream() << (*i).texcoord.x() << " " << (*i).texcoord.y() << ", ";
                pts[count].x() = ( *i ).texcoord.x();
                pts[count].y() = ( *i ).texcoord.y();
                count++;
@@ -1557,7 +1542,6 @@ void CopyPointsFromSelectedFace( void ){
 
        numPts = count;
 
-       //globalOutputStream() << " ..copied points\n";
 }
 
 brushprimit_texdef_t bp;
@@ -1569,13 +1553,11 @@ void CommitChanges( void ){
        bp.coords[0][1] = tm.coords[0][0] * origBP.coords[0][1] + tm.coords[0][1] * origBP.coords[1][1];
        bp.coords[0][2] = tm.coords[0][0] * origBP.coords[0][2] + tm.coords[0][1] * origBP.coords[1][2] + tm.coords[0][2];
 //Ok, this works for translation...
-//     bp.coords[0][2] = tm.coords[0][0] * origBP.coords[0][2] + tm.coords[0][1] * origBP.coords[1][2] + tm.coords[0][2] * textureSize.x();
        bp.coords[1][0] = tm.coords[1][0] * origBP.coords[0][0] + tm.coords[1][1] * origBP.coords[1][0];
        bp.coords[1][1] = tm.coords[1][0] * origBP.coords[0][1] + tm.coords[1][1] * origBP.coords[1][1];
        bp.coords[1][2] = tm.coords[1][0] * origBP.coords[0][2] + tm.coords[1][1] * origBP.coords[1][2] + tm.coords[1][2];
-//     bp.coords[1][2] = tm.coords[1][0] * origBP.coords[0][2] + tm.coords[1][1] * origBP.coords[1][2] + tm.coords[1][2] * textureSize.y();
 
-//This doesn't work:   g_brush_texture_changed();
+//This doesn't work:   g_brush_texture_changed();
 // Let's try this:
 //Note: We should only set an undo *after* the button has been released... !!! FIX !!!
 //Definitely *should* have an undo, though!
@@ -1799,9 +1781,6 @@ void focus(){
 
        // Do some viewport fitting stuff...
 
-//globalOutputStream() << "--> Center: " << center.x() << ", " << center.y() << "\n";
-//globalOutputStream() << "--> Extents (stage 1): " << extents.minX << ", "
-//     << extents.maxX << ", " << extents.minY << ", " << extents.maxY << "\n";
        // TTimo: Apply a ratio to get the area we'll draw.
        center.x() = 0.5f * ( extents.minX + extents.maxX ),
                center.y() = 0.5f * ( extents.minY + extents.maxY );
@@ -1809,31 +1788,23 @@ void focus(){
        extents.minY = center.y() + VP_PADDING * ( extents.minY - center.y() ),
        extents.maxX = center.x() + VP_PADDING * ( extents.maxX - center.x() ),
        extents.maxY = center.y() + VP_PADDING * ( extents.maxY - center.y() );
-//globalOutputStream() << "--> Extents (stage 2): " << extents.minX << ", "
-//     << extents.maxX << ", " << extents.minY << ", " << extents.maxY << "\n";
 
        // TTimo: We want a texture with the same X / Y ratio.
        // TTimo: Compute XY space / window size ratio.
        float SSize = extents.width(), TSize = extents.height();
        float ratioX = textureSize.x() * extents.width() / windowSize.x(),
                  ratioY = textureSize.y() * extents.height() / windowSize.y();
-//globalOutputStream() << "--> Texture size: " << textureSize.x() << ", " << textureSize.y() << "\n";
-//globalOutputStream() << "--> Window size: " << windowSize.x() << ", " << windowSize.y() << "\n";
 
        if ( ratioX > ratioY ) {
                TSize = ( windowSize.y() * ratioX ) / textureSize.y();
-//             TSize = extents.width() * (windowSize.y() / windowSize.x()) * (textureSize.x() / textureSize.y());
        }
        else
        {
                SSize = ( windowSize.x() * ratioY ) / textureSize.x();
-//             SSize = extents.height() * (windowSize.x() / windowSize.y()) * (textureSize.y() / textureSize.x());
        }
 
        extents.minX = center.x() - 0.5f * SSize, extents.maxX = center.x() + 0.5f * SSize,
        extents.minY = center.y() - 0.5f * TSize, extents.maxY = center.y() + 0.5f * TSize;
-//globalOutputStream() << "--> Extents (stage 3): " << extents.minX << ", "
-//     << extents.maxX << ", " << extents.minY << ", " << extents.maxY << "\n";
 }
 
 gboolean size_allocate( GtkWidget * win, GtkAllocation * a, gpointer ){
@@ -1844,12 +1815,8 @@ gboolean size_allocate( GtkWidget * win, GtkAllocation * a, gpointer ){
 }
 
 gboolean expose( GtkWidget * win, GdkEventExpose * e, gpointer ){
-//     globalOutputStream() << "--> Textool Window was exposed!\n";
-//     globalOutputStream() << "    (window width/height: " << cc << "/" << e->area.height << ")\n";
 
-//     windowSize.x() = e->area.width, windowSize.y() = e->area.height;
 //This needs to go elsewhere...
-//     InitTextool();
 
        if ( glwidget_make_current( win ) == FALSE ) {
                globalOutputStream() << "    FAILED to make current! Oh, the agony! :-(\n";
@@ -1863,7 +1830,6 @@ gboolean expose( GtkWidget * win, GdkEventExpose * e, gpointer ){
        }
 
        // Probably should init button/anchor states here as well...
-//     rotationAngle = 0.0f;
        glClearColor( 0, 0, 0, 0 );
        glViewport( 0, 0, e->area.width, e->area.height );
        glMatrixMode( GL_PROJECTION );
@@ -1917,8 +1883,6 @@ gboolean expose( GtkWidget * win, GdkEventExpose * e, gpointer ){
        DrawControlWidgets();
 //???
        // reset the current texture
-//  glBindTexture(GL_TEXTURE_2D, 0);
-//  glFinish();
        glwidget_swap_buffers( win );
 
        return false;
@@ -1943,7 +1907,6 @@ Vector2 trans2;
 Vector2 dragPoint;  // Defined in terms of window space (+x/-y)
 Vector2 oldTrans;
 gboolean button_press( GtkWidget * win, GdkEventButton * e, gpointer ){
-//     globalOutputStream() << "--> Textool button press...\n";
 
        if ( e->button == 1 ) {
                lButtonDown = true;
@@ -1951,9 +1914,6 @@ gboolean button_press( GtkWidget * win, GdkEventButton * e, gpointer ){
 
                origBP = currentBP;
 
-               //globalOutputStream() << "--> Original BP: [" << origBP.coords[0][0] << "][" << origBP.coords[0][1] << "][" << origBP.coords[0][2] << "]\n";
-               //globalOutputStream() << "                 [" << origBP.coords[1][0] << "][" << origBP.coords[1][1] << "][" << origBP.coords[1][2] << "]\n";
-               //float angle = atan2(origBP.coords[0][1], origBP.coords[0][0]) * 180.0f / 3.141592653589f;
                origAngle = ( origBP.coords[0][1] > 0 ? PI : -PI ); // Could also be -PI... !!! FIX !!! [DONE]
 
                if ( origBP.coords[0][0] != 0.0f ) {
@@ -1965,13 +1925,10 @@ gboolean button_press( GtkWidget * win, GdkEventButton * e, gpointer ){
                rotationAngle = origAngle;
                oldCenter[0] = oldCenter[1] = 0;
 
-               //globalOutputStream() << "--> BP stats: ang=" << origAngle * RAD_TO_DEG << ", scale=" << origScaleX << "/" << origScaleY << "\n";
                //Should also set the Flip X/Y checkboxes here as well... !!! FIX !!!
                //Also: should reverse texture left/right up/down instead of flipping the points...
 
 //disnowok
-//float nx = windowSize.x() * (e->x - extents.minX) / (extents.maxX - extents.minX);
-//float ny = windowSize.y() * (e->y - extents.minY) / (extents.maxY - extents.minY);
 //disdoes...
 //But I want it to scroll the texture window, not the points... !!! FIX !!!
 //Actually, should scroll the texture window only when mouse is down on no widgets...
@@ -1983,8 +1940,6 @@ gboolean button_press( GtkWidget * win, GdkEventButton * e, gpointer ){
                dragPoint.x() = e->x, dragPoint.y() = e->y;
                trans2.x() = nx, trans2.y() = ny;
                oldRotationAngle = rotationAngle;
-//             oldTrans.x() = tm.coords[0][2] - nx * textureSize.x();
-//             oldTrans.y() = tm.coords[1][2] - ny * textureSize.y();
                oldTrans.x() = tm.coords[0][2];
                oldTrans.y() = tm.coords[1][2];
                oldCenter.x() = center.x();
@@ -1999,13 +1954,11 @@ gboolean button_press( GtkWidget * win, GdkEventButton * e, gpointer ){
         rButtonDown = true;
     }//*/
 
-//globalOutputStream() << "(" << (haveAnchor ? "anchor" : "released") << ")\n";
 
        return false;
 }
 
 gboolean button_release( GtkWidget * win, GdkEventButton * e, gpointer ){
-//     globalOutputStream() << "--> Textool button release...\n";
 
        if ( e->button == 1 ) {
 /*             float ptx = e->x / windowSize.x() * extents.width() + extents.minX;
@@ -2067,7 +2020,6 @@ gboolean button_release( GtkWidget * win, GdkEventButton * e, gpointer ){
    }
  */
 gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
-//     globalOutputStream() << "--> Textool motion...\n";
 
        if ( lButtonDown ) {
                if ( translatingX || translatingY ) {
@@ -2077,18 +2029,12 @@ gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
 //Need to fix this to take the rotation angle into account, so that it moves along
 //the rotated X/Y axis...
                        if ( translatingX ) {
-//                             tm.coords[0][2] = (trans.x() + ptx) * textureSize.x();
 //This works, but only when the angle is zero. !!! FIX !!! [DONE]
-//                             tm.coords[0][2] = oldCenter.x() + (ptx * textureSize.x());
                                tm.coords[0][2] = oldTrans.x() + ( ptx - trans2.x() ) * textureSize.x();
-//                             center.x() = oldCenter.x() + (ptx - trans2.x());
                        }
 
                        if ( translatingY ) {
-//                             tm.coords[1][2] = (trans.y() + pty) * textureSize.y();
-//                             tm.coords[1][2] = oldCenter.y() + (pty * textureSize.y());
                                tm.coords[1][2] = oldTrans.y() + ( pty - trans2.y() ) * textureSize.y();
-//                             center.y() = oldCenter.y() + (pty - trans2.y());
                        }
 
 //Need to update center.x/y() so that the widget translates as well. Also, oldCenter
@@ -2115,29 +2061,19 @@ gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
 // Problem with this: arcsin/cos seems to only return -90 to 90 and 0 to 180...
 // Can't derive angle from that!
 
-//rotationAngle = asin(s);// * 180.0f / 3.141592653589f;
                        rotationAngle = acos( c );
-//rotationAngle2 = asin(s);
                        if ( cross[2] < 0 ) {
                                rotationAngle = -rotationAngle;
                        }
 
-//NO! DOESN'T WORK! rotationAngle -= 45.0f * DEG_TO_RAD;
 //Let's try this:
 //No wok.
 /*c = cos(rotationAngle - oldRotationAngle);
    s = sin(rotationAngle - oldRotationAngle);
    rotationAngle += oldRotationAngle;
-   //c += cos(oldRotationAngle);
-   //s += sin(oldRotationAngle);
-   //rotationAngle += oldRotationAngle;
-   //c %= 2.0 * PI;
-   //s %= 2.0 * PI;
-   //rotationAngle %= 2.0 * PI;//*/
 
 //This is wrong... Hmm...
 //It seems to shear the texture instead of rotating it... !!! FIX !!!
-// Now it rotates correctly. Seems TTimo was overcomplicating things here... ;-)
 
 // Seems like what needs to happen here is multiplying these rotations by tm... !!! FIX !!!
 
@@ -2148,16 +2084,8 @@ gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
                        tm.coords[1][0] = -s;
                        tm.coords[1][1] =  c;
 //It doesn't work anymore... Dunno why...
-//tm.coords[0][2] = -trans.x();                        // This works!!! Yeah!!!
-//tm.coords[1][2] = -trans.y();
 //nope.
-//tm.coords[0][2] = rotationPoint.x(); // This works, but strangely...
-//tm.coords[1][2] = rotationPoint.y();
-//tm.coords[0][2] = 0;// center.x() / 2.0f;
-//tm.coords[1][2] = 0;// center.y() / 2.0f;
 //No.
-//tm.coords[0][2] = -(center.x() * textureSize.x());
-//tm.coords[1][2] = -(center.y() * textureSize.y());
 //Eh? No, but seems to be getting closer...
 /*float ptx = e->x / windowSize.x() * extents.width() + extents.minX;
    float pty = e->y / windowSize.y() * extents.height() + extents.minY;
@@ -2198,12 +2126,9 @@ gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
 //Look at nx/y above: they're getting fixed there! !!! FIX !!! [DONE]
                float dist = sqrt( ( nx * nx ) + ( ny * ny ) );
                // Normalize to the 2.0 = height standard (for now)
-//globalOutputStream() << "--> Distance before: " << dist;
                dist = dist * 2.0f / extents.height();
-//globalOutputStream() << ". After: " << dist;
                tran.x() = tran.x() * 2.0f / extents.height();
                tran.y() = tran.y() * 2.0f / extents.height();
-//globalOutputStream() << ". Trans: " << tran.x() << ", " << tran.y() << "\n";
 
 //Let's try this instead...
 //Interesting! It seems that e->x/y are rotated
@@ -2244,28 +2169,15 @@ gboolean motion( GtkWidget * win, GdkEventMotion * e, gpointer ){
 //It seems the fake tex coords conversion is screwing this stuff up... !!! FIX !!!
 //This is still wrong... Prolly need to do something with the oldScaleX/Y stuff...
 void flipX( GtkToggleButton *, gpointer ){
-//     globalOutputStream() << "--> Flip X...\n";
        //Shamus:
-//     SurfaceInspector_GetSelectedBPTexdef();         // Refresh g_selectedBrushPrimitTexdef...
-//     tm.coords[0][0] = -tm.coords[0][0];
-//     tm.coords[1][0] = -tm.coords[1][0];
-//     tm.coords[0][0] = -tm.coords[0][0];                     // This should be correct now...Nope.
-//     tm.coords[1][1] = -tm.coords[1][1];
        tm.coords[0][0] = -tm.coords[0][0];         // This should be correct now...
        tm.coords[1][0] = -tm.coords[1][0];
-//     tm.coords[2][0] = -tm.coords[2][0];//wil wok? no.
        UpdateControlPoints();
 }
 
 void flipY( GtkToggleButton *, gpointer ){
-//     globalOutputStream() << "--> Flip Y...\n";
-//     tm.coords[0][1] = -tm.coords[0][1];
-//     tm.coords[1][1] = -tm.coords[1][1];
-//     tm.coords[0][1] = -tm.coords[0][1];                     // This should be correct now...Nope.
-//     tm.coords[1][0] = -tm.coords[1][0];
        tm.coords[0][1] = -tm.coords[0][1];         // This should be correct now...
        tm.coords[1][1] = -tm.coords[1][1];
-//     tm.coords[2][1] = -tm.coords[2][1];//wil wok? no.
        UpdateControlPoints();
 }
 
index f0fd5d495951f0cb7bc94b6d0b6e0c193b84aa8e..71f90e31410b7d1dbdcb12ffd9c241c31d1a1880 100644 (file)
@@ -1181,13 +1181,11 @@ void Texture_Draw( TextureBrowser& textureBrowser ){
                        glEnable( GL_TEXTURE_2D );
                }
 
-               //int totalHeight = abs(y) + last_height + TextureBrowser_fontHeight(textureBrowser) + 4;
        }
 
 
        // reset the current texture
        glBindTexture( GL_TEXTURE_2D, 0 );
-       //qglFinish();
 }
 
 void TextureBrowser_queueDraw( TextureBrowser& textureBrowser ){
@@ -1351,7 +1349,6 @@ gboolean TextureBrowser_scroll( GtkWidget* widget, GdkEventScroll* event, Textur
 }
 
 void TextureBrowser_scrollChanged( void* data, gdouble value ){
-       //globalOutputStream() << "vertical scroll\n";
        TextureBrowser_setOriginY( *reinterpret_cast<TextureBrowser*>( data ), -(int)value );
 }
 
@@ -2158,7 +2155,6 @@ GtkWidget* TextureBrowser_constructWindow( GtkWindow* toplevel ){
        }
 
        // TODO do we need this?
-       //gtk_container_set_focus_chain(GTK_CONTAINER(hbox_table), NULL);
 
        return table;
 }
index 670e1f768c45d55eca7645588f9f75516f562db7..73ef7d47267d23a1c6569da1f5b1eae496fe4a2f 100644 (file)
@@ -122,7 +122,6 @@ static GtkTreeModelFlags graph_tree_model_get_flags( GtkTreeModel* tree_model ){
 
 static gint graph_tree_model_get_n_columns( GtkTreeModel* tree_model ){
        ASSERT_MESSAGE( tree_model != 0, "RUNTIME ERROR" );
-       //GraphTreeModel* graph_tree_model = (GraphTreeModel*) tree_model;
 
        return 2;
 }
@@ -145,7 +144,6 @@ inline void graph_iterator_write_tree_iter( GraphTreeNode::iterator i, GtkTreeIt
 
 static GType graph_tree_model_get_column_type( GtkTreeModel *tree_model, gint index ){
        ASSERT_MESSAGE( tree_model != 0, "RUNTIME ERROR" );
-       //GraphTreeModel *graph_tree_model = (GraphTreeModel *) tree_model;
 
        return G_TYPE_POINTER;
 }
index 0bc45cfd0b8dc84c69d6562c925e35188d9fb25a..cc5ec07f678288fe13f9c98d1f5becce3e54ae9f 100644 (file)
@@ -555,7 +555,6 @@ inline void GlobalGameDescription_string_write_mapparameter( StringOutputStream&
        {
                string << "+set sv_pure 0 ";
                // TTimo: a check for vm_* but that's all fine
-               //cmdline = "+set sv_pure 0 +set vm_ui 0 +set vm_cgame 0 +set vm_game 0 ";
                const char* fs_game = gamename_get();
                if ( !string_equal( fs_game, basegame_get() ) ) {
                        string << "+set fs_game " << fs_game << " ";
@@ -631,7 +630,6 @@ void CWatchBSP::RoutineProcessing(){
                        // see if there's anything in input
                        ret = Net_Receive( m_pInSocket, &msg );
                        if ( ret > 0 ) {
-                               //        unsigned int size = msg.size; //++timo just a check
                                strcpy( m_xmlBuf, NMSG_ReadString( &msg ) );
                                if ( m_bNeedCtxtInit ) {
                                        m_xmlParserCtxt = NULL;
index 989c1196309ef7ea40f9fc65cffc1802dba0e4bf..37ca85a5f93626a1f1b27e5727f8048af014aef8 100644 (file)
@@ -55,17 +55,14 @@ gboolean selection_modifier_key_press( GtkWidget* widget, GdkEventKey* event, Wi
        {
        case GDK_Alt_L:
        case GDK_Alt_R:
-               //globalOutputStream() << "Alt PRESSED\n";
                WindowObservers_OnModifierDown( observers, c_modifierAlt );
                break;
        case GDK_Shift_L:
        case GDK_Shift_R:
-               //globalOutputStream() << "Shift PRESSED\n";
                WindowObservers_OnModifierDown( observers, c_modifierShift );
                break;
        case GDK_Control_L:
        case GDK_Control_R:
-               //globalOutputStream() << "Control PRESSED\n";
                WindowObservers_OnModifierDown( observers, c_modifierControl );
                break;
        }
@@ -77,17 +74,14 @@ gboolean selection_modifier_key_release( GtkWidget* widget, GdkEventKey* event,
        {
        case GDK_Alt_L:
        case GDK_Alt_R:
-               //globalOutputStream() << "Alt RELEASED\n";
                WindowObservers_OnModifierUp( observers, c_modifierAlt );
                break;
        case GDK_Shift_L:
        case GDK_Shift_R:
-               //globalOutputStream() << "Shift RELEASED\n";
                WindowObservers_OnModifierUp( observers, c_modifierShift );
                break;
        case GDK_Control_L:
        case GDK_Control_R:
-               //globalOutputStream() << "Control RELEASED\n";
                WindowObservers_OnModifierUp( observers, c_modifierControl );
                break;
        }
index f8c20b8c92e4baf3187bb4b1b4a6d52fbbbee4b5..2190b0a1941dd2b0e092a8f965235b96664b15a9 100644 (file)
@@ -547,7 +547,6 @@ void XYWnd::ChaseMouse(){
        float multiplier = g_chasemouse_timer.elapsed_msec() / 10.0f;
        Scroll( float_to_integer( multiplier * m_chasemouse_delta_x ), float_to_integer( multiplier * -m_chasemouse_delta_y ) );
 
-       //globalOutputStream() << "chasemouse: multiplier=" << multiplier << " x=" << m_chasemouse_delta_x << " y=" << m_chasemouse_delta_y << '\n';
 
        XY_MouseMoved( m_chasemouse_current_x, m_chasemouse_current_y, getButtonState() );
        g_chasemouse_timer.start();
@@ -584,11 +583,9 @@ bool XYWnd::chaseMouseMotion( int pointx, int pointy ){
                }
 
                if ( m_chasemouse_delta_y != 0 || m_chasemouse_delta_x != 0 ) {
-                       //globalOutputStream() << "chasemouse motion: x=" << pointx << " y=" << pointy << "... ";
                        m_chasemouse_current_x = pointx;
                        m_chasemouse_current_y = pointy;
                        if ( m_chasemouse_handler == 0 ) {
-                               //globalOutputStream() << "chasemouse timer start... ";
                                g_chasemouse_timer.start();
                                m_chasemouse_handler = g_idle_add( xywnd_chasemouse, this );
                        }
@@ -597,7 +594,6 @@ bool XYWnd::chaseMouseMotion( int pointx, int pointy ){
                else
                {
                        if ( m_chasemouse_handler != 0 ) {
-                               //globalOutputStream() << "chasemouse cancel\n";
                                g_source_remove( m_chasemouse_handler );
                                m_chasemouse_handler = 0;
                        }
@@ -606,7 +602,6 @@ bool XYWnd::chaseMouseMotion( int pointx, int pointy ){
        else
        {
                if ( m_chasemouse_handler != 0 ) {
-                       //globalOutputStream() << "chasemouse cancel\n";
                        g_source_remove( m_chasemouse_handler );
                        m_chasemouse_handler = 0;
                }
@@ -966,7 +961,6 @@ void XYWnd::NewBrushDrag( int x, int y ){
        }
 
        // d1223m
-       //Scene_BrushResize_Selected(GlobalSceneGraph(), aabb_for_minmax(mins, maxs), TextureBrowser_GetSelectedShader(GlobalTextureBrowser()));
        Scene_BrushResize_Selected( GlobalSceneGraph(), aabb_for_minmax( mins, maxs ),
                                                                g_brush_always_caulk ?
                                                                "textures/common/caulk" : TextureBrowser_GetSelectedShader( GlobalTextureBrowser() ) );