Class KHRCompositionLayerColorScaleBias

java.lang.Object
org.lwjgl.openxr.KHRCompositionLayerColorScaleBias

public final class KHRCompositionLayerColorScaleBias extends Object
The XR_KHR_composition_layer_color_scale_bias extension.

Color scale and bias are applied to a layer color during composition, after its conversion to premultiplied alpha representation.

If specified, colorScale and colorBias must be used to alter the LayerColor as follows:

  • colorScale = max( vec4( 0, 0, 0, 0 ), colorScale )
  • LayerColor.RGB = LayerColor.A > 0 ? LayerColor.RGB / LayerColor.A : vec3( 0, 0, 0 )
  • LayerColor = LayerColor * colorScale + colorBias
  • LayerColor.RGB *= LayerColor.A

This extension specifies the XrCompositionLayerColorScaleBiasKHR structure, which, if present in the XrCompositionLayerBaseHeader::next chain, must be applied to the composition layer.

This extension does not define a new composition layer type, but rather it defines a transform that may be applied to the color derived from existing composition layer types.

  • Field Details

    • XR_KHR_composition_layer_color_scale_bias_SPEC_VERSION

      public static final int XR_KHR_composition_layer_color_scale_bias_SPEC_VERSION
      The extension specification version.
      See Also:
    • XR_KHR_COMPOSITION_LAYER_COLOR_SCALE_BIAS_EXTENSION_NAME

      public static final String XR_KHR_COMPOSITION_LAYER_COLOR_SCALE_BIAS_EXTENSION_NAME
      The extension name.
      See Also:
    • XR_TYPE_COMPOSITION_LAYER_COLOR_SCALE_BIAS_KHR

      public static final int XR_TYPE_COMPOSITION_LAYER_COLOR_SCALE_BIAS_KHR
      Extends XrStructureType.
      See Also: