Enum Class VideoColorRange

java.lang.Object
java.lang.Enum<VideoColorRange>
org.freedesktop.gstreamer.video.VideoColorRange
All Implemented Interfaces:
Serializable, Comparable<VideoColorRange>, Constable, Enumeration

@Generated("org.javagi.JavaGI") public enum VideoColorRange extends Enum<VideoColorRange> implements Enumeration
Possible color range values. These constants are defined for 8 bit color values and can be scaled for other bit depths.
  • Enum Constant Details

    • UNKNOWN

      public static final VideoColorRange UNKNOWN
      unknown range
    • _0_255

      public static final VideoColorRange _0_255
      [0..255] for 8 bit components
    • _16_235

      public static final VideoColorRange _16_235
      [16..235] for 8 bit components. Chroma has [16..240] range.
  • Method Details

    • values

      public static VideoColorRange[] values()
      Returns an array containing the constants of this enum class, in the order they are declared.
      Returns:
      an array containing the constants of this enum class, in the order they are declared
    • valueOf

      public static VideoColorRange valueOf(String name)
      Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum class has no constant with the specified name
      NullPointerException - if the argument is null
    • of

      public static VideoColorRange of(int value)
      Create a new VideoColorRange for the provided value
      Parameters:
      value - the enum value
      Returns:
      the enum for the provided value
    • getValue

      public int getValue()
      Get the numeric value of this enum
      Specified by:
      getValue in interface Enumeration
      Returns:
      the enum value
    • of

      public static VideoColorRange of(MemorySegment address)
      Create a new VideoColorRange for the value in the provided memory address.
      Parameters:
      address - the memory address holding a enum value
      Returns:
      the enum for the value in the provided memory address
    • getType

      public static @Nullable Type getType()
      Get the GType of the VideoColorRange class.
      Returns:
      the GType
    • offsets

      public void offsets(VideoFormatInfo info, @Nullable Out<int[]> offset, @Nullable Out<int[]> scale)

      Compute the offset and scale values for each component of info. For each component, (c

      invalid reference
      i
      - offset
      invalid reference
      i
      ) / scale
      invalid reference
      i
      will scale the component c
      invalid reference
      i
      to the

      range [0.0 .. 1.0].

      The reverse operation (c

      invalid reference
      i
      * scale
      invalid reference
      i
      ) + offset
      invalid reference
      i
      can be used to convert

      the component values in range [0.0 .. 1.0] back to their representation in info and range.

      Parameters:
      info - a GstVideoFormatInfo
      offset - output offsets
      scale - output scale