Smoke: Remove accidental leftover code from gSoC Smoke + my Smoke code merge.
authorDaniel Genrich <daniel.genrich@gmx.net>
Tue, 21 May 2013 19:52:22 +0000 (19:52 +0000)
committerDaniel Genrich <daniel.genrich@gmx.net>
Tue, 21 May 2013 19:52:22 +0000 (19:52 +0000)
Thanks to Miika for pointing this issue out and fixing it.

intern/smoke/intern/FLUID_3D.cpp

index 780a39e..a43d94a 100644 (file)
@@ -991,59 +991,11 @@ void FLUID_3D::project()
                                _pressure[index] = 0.0f;
                        }
 
-
-       /*
-       {
-               float maxvalue = 0;
-               for(unsigned int i = 0; i < _xRes * _yRes * _zRes; i++)
-               {
-                       if(_divergence[i] > maxvalue)
-                               maxvalue = _divergence[i];
-
-               }
-               printf("Max divergence: %f\n", maxvalue);
-       }
-       */
-
        copyBorderAll(_pressure, 0, _zRes);
 
-       /*
-       {
-               float maxvalue = 0;
-               for(unsigned int i = 0; i < _xRes * _yRes * _zRes; i++)
-               {
-                       if(_pressure[i] > maxvalue)
-                               maxvalue = _pressure[i];
-               }
-               printf("Max pressure BEFORE: %f\n", maxvalue);
-       }
-       */
-
        // solve Poisson equation
        solvePressurePre(_pressure, _divergence, _obstacles);
 
-       {
-               float maxvalue = 0;
-               for(unsigned int i = 0; i < _xRes * _yRes * _zRes; i++)
-               {
-                       if(_pressure[i] > maxvalue)
-                               maxvalue = _pressure[i];
-
-                       /* HACK: Animated collision object sometimes result in a non converging solvePressurePre() */ 
-                       /*if(_pressure[i] > _dx * _dt)
-                               _pressure[i] = _dx * _dt;
-                       else if(_pressure[i] < -_dx * _dt)
-                               _pressure[i] = -_dx * _dt;*/
-
-                       // if(_obstacle[i] && _pressure[i] != 0.0)
-                       //      printf("BAD PRESSURE i\n");
-
-                       // if(_pressure[i]>1)
-                       //      printf("index: %d\n", i);
-               }
-               // printf("Max pressure: %f, dx: %f\n", maxvalue, _dx);
-       }
-
        setObstaclePressure(_pressure, 0, _zRes);
 
        // project out solution