Closed paulmelis closed 4 years ago
Is now fixed in release-2.0.x
.
Check!
Hmmm, found something weird. See this test:
The output image contains the correct opacity=1 (but see #393) for the white background, but the red geometry has opacity=0.5. The image here in the github issue doesn't show alpha in meaningful way, unfortunately:
I would expect all pixels to have the full opaqueness of the background color, regardless of the geometry opacity. To get an image with the actual opaqueness of the geometry I would normally use background (1,1,1,0)
.
Also, if you enable vertex.color
in the test and disable the material, the per-vertex colors will have opacity 0.1, but this doesn't show in the rendered image. All pixels have opacity 1.0.
Finally, using the usual renderer.setParam("backgroundColor", 1.0f)
has the new behaviour of setting the opacity to 0. Perhaps because the float gets cast first to a vec3f(1,1,1)
followed by widening to vec4(1,1,1,0)
?
SciVis currently does not support (recursive) transparency of surfaces: another object behind the red quad would also be not visible (as is the background). We will fix this in v2.1.
Use of opacity of vertex.color
will come in v2.0.1.
Re the last point: this is exactly what happens, and this is intended (default of backgroudColor
is transparent/black) and was introduced in v1.3 (6d7a7634b2).
The alpha value of
bgColor
doesn't seem to have any effect?