]> Creatis software - creaMaracasVisu.git/blobdiff - bbtk/src/bbmaracasvisuDrawAxisTree3D.cxx
no message
[creaMaracasVisu.git] / bbtk / src / bbmaracasvisuDrawAxisTree3D.cxx
index ab3ad3110cd05c73f03ac4a10ca7f862325b2e85..8d7324555487e2d214136069df0093304b2fccf8 100644 (file)
@@ -55,18 +55,22 @@ void DrawAxisTree3D::DrawOneAxis(int iGeneral,int numPoints, int iAxis)
        // color
        double r,g,b;
 
-       if ( (iAxis*3+1) < (int)(bbGetInputColour().size()) ){
+       if ( (iAxis*3+1) < (int)(bbGetInputColour().size()) )
+       {
                        r = bbGetInputColour()[0+iAxis*3];
                        g = bbGetInputColour()[1+iAxis*3]; 
                        b = bbGetInputColour()[2+iAxis*3];
-               } else {
-                       r = bbGetInputColour()[0];
-                       g = bbGetInputColour()[1]; 
-                       b = bbGetInputColour()[2];
-               }
+       } else {
+//                     r = bbGetInputColour()[0];
+//                     g = bbGetInputColour()[1]; 
+//                     b = bbGetInputColour()[2];
+                       r = (rand() % 100) / 100.0;
+                       g = (rand() % 100) / 100.0;
+                       b = (rand() % 100) / 100.0;
+       }
 
-       vtkactor->GetProperty()->SetColor( 1,0,0 );
-       vtkactor->GetProperty()->SetLineWidth( 3 );
+       vtkactor->GetProperty()->SetColor( r,g,b );
+       vtkactor->GetProperty()->SetLineWidth( 0.5 );
 
        if ( bbGetInputTransform()!=NULL )
        {