Indicates whether depth testing is used when rendering this node.
If the depthTest flag is DepthTest.DISABLE
, then depth testing
is disabled for this node.
If the depthTest flag is DepthTest.ENABLE
, then depth testing
is enabled for this node.
If the depthTest flag is DepthTest.INHERIT
, then depth testing
is enabled for this node if it is enabled for the parent node or the
parent node is null.
The depthTest flag is only used when the depthBuffer flag for
the Scene
is true (meaning that the
Scene
has an associated depth buffer)
Depth test comparison is only done among nodes with depthTest enabled. A node with depthTest disabled does not read, test, or write the depth buffer, that is to say its Z value will not be considered for depth testing with other nodes.
Note that this is a conditional feature. See
ConditionalFeature.SCENE3D
for more information.
See the constructor in Scene with depthBuffer as one of its input arguments.
Node
javafx.scene.Scene
@defaultValue INHERIT
Diagram: Node