]> Creatis software - bbtk.git/commitdiff
#3301 BBTK Bug New Normal SurfaceTexture
authorEduardo DAVILA <davila@ei-ed-606.univ-lyon1.fr>
Thu, 5 Sep 2019 14:55:40 +0000 (16:55 +0200)
committerEduardo DAVILA <davila@ei-ed-606.univ-lyon1.fr>
Thu, 5 Sep 2019 14:55:40 +0000 (16:55 +0200)
kernel/src/bbtkWtBlackBox.h
packages/vtk/src/bbvtkSurfaceTexture.cxx

index 4725a0dfeac48efd3fdf351d87a4921c76edf4fe..e73bde96986610134b987d5e5e0d26f8d5b8e646 100644 (file)
@@ -157,6 +157,6 @@ namespace bbtk
 
 } //namespace bbtk
 
-#endif  //__bbtkWxBlackBox_h__
+#endif  //__bbtkWtBlackBox_h__
 
-#endif  //USE_WXWIDGETS
+#endif  //USE_WT
index 0016c6eeb502c29ce1a2985119e8a679e8087418..2d5c86d3c9f7887632eb06d3754f5a504b414860 100644 (file)
@@ -197,7 +197,7 @@ void SurfaceTexture::Process()
                
                if ( (p2[0]>=0) && (p2[0]<maxX) && (p2[1]>=0) && (p2[1]<maxY) &&(p2[2]>=0) && (p2[2]<maxZ)  )
                {
-                  gl =  bbGetInputImage()->GetScalarComponentAsDouble(p2[0], p2[1], p2[2],0);
+                  gl =  bbGetInputImage()->GetScalarComponentAsDouble(round(p2[0]), round(p2[1]), round(p2[2]),0);
                } else {
                        gl=0;
                }
@@ -221,6 +221,7 @@ void SurfaceTexture::bbUserSetDefaultValues()
        bbSetInputColorLevel(500);
        bbSetInputColorWindow(500);
        bbSetInputTransform(NULL);
+       bbSetInputExternalLookupTable(NULL);
   
        firsttime                               = true;
        colors                                  = NULL;