diff --git a/src/osgVolume/Shaders/volume_accumulateSamples_iso_frag.cpp b/src/osgVolume/Shaders/volume_accumulateSamples_iso_frag.cpp index 0d1d414c9..75907aee1 100644 --- a/src/osgVolume/Shaders/volume_accumulateSamples_iso_frag.cpp +++ b/src/osgVolume/Shaders/volume_accumulateSamples_iso_frag.cpp @@ -29,14 +29,8 @@ char volume_accumulateSamples_iso_frag[] = "#version 110\n" " float r = (targetValue-color.a)/(previousColor.a-color.a);\n" " texcoord = texcoord - r*dt;\n" "\n" - "#if 0\n" - " color = texture3D( volumeTexture, texcoord);\n" - "#else\n" - " color.r = 1.0;\n" - " color.g = 1.0;\n" - " color.b = 1.0;\n" - " color.a = 1.0;\n" - "#endif\n" + " color.r = vec4(1.0, 1.0, 1.0, 1.0);\n" + "\n" " float px = texture3D( volumeTexture, texcoord + deltaX).a;\n" " float py = texture3D( volumeTexture, texcoord + deltaY).a;\n" " float pz = texture3D( volumeTexture, texcoord + deltaZ).a;\n" @@ -55,6 +49,8 @@ char volume_accumulateSamples_iso_frag[] = "#version 110\n" " color.g *= lightScale;\n" " color.b *= lightScale;\n" " }\n" + "\n" + " color.a = clamp(color.a*TransparencyValue, 0.0, 1.0);\n" " return color;\n" " }\n" "\n" diff --git a/src/osgVolume/Shaders/volume_accumulateSamples_iso_tf_frag.cpp b/src/osgVolume/Shaders/volume_accumulateSamples_iso_tf_frag.cpp index 2323bb947..db4b51cf2 100644 --- a/src/osgVolume/Shaders/volume_accumulateSamples_iso_tf_frag.cpp +++ b/src/osgVolume/Shaders/volume_accumulateSamples_iso_tf_frag.cpp @@ -53,7 +53,7 @@ char volume_accumulateSamples_iso_tf_frag[] = "#version 110\n" " color.g *= lightScale;\n" " color.b *= lightScale;\n" " }\n" - " fragColor.a = clamp(fragColor.a*Transparency, 0.0, 1.0);\n" + " fragColor.a = clamp(fragColor.a*TransparencyValue, 0.0, 1.0);\n" " return color;\n" " }\n" "\n"