Class VideoInfoDmaDrm

java.lang.Object
org.javagi.base.ProxyInstance
org.freedesktop.gstreamer.video.VideoInfoDmaDrm
All Implemented Interfaces:
Proxy

@Generated("org.javagi.JavaGI") public class VideoInfoDmaDrm extends ProxyInstance
Information describing a DMABuf image properties. It wraps GstVideoInfo and adds DRM information such as drm-fourcc and drm-modifier, required for negotiation and mapping.
Since:
1.24
  • Constructor Details

    • VideoInfoDmaDrm

      public VideoInfoDmaDrm(MemorySegment address)
      Create a VideoInfoDmaDrm proxy instance for the provided memory address.
      Parameters:
      address - the memory address of the native object
    • VideoInfoDmaDrm

      public VideoInfoDmaDrm()
      Allocate a new GstVideoInfoDmaDrm that is also initialized with gst_video_info_dma_drm_init().
      Since:
      1.24
  • Method Details

    • getType

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

      public static MemoryLayout getMemoryLayout()
      The memory layout of the native struct.
      Returns:
      the memory layout
    • readVinfo

      public @Nullable VideoInfo readVinfo()
      Read the value of the field vinfo.
      Returns:
      The value of the field vinfo
    • writeVinfo

      public void writeVinfo(@Nullable VideoInfo vinfo)
      Write a value in the field vinfo.
      Parameters:
      vinfo - The new value for the field vinfo
    • readDrmFourcc

      public int readDrmFourcc()
      Read the value of the field drm_fourcc.
      Returns:
      The value of the field drm_fourcc
    • writeDrmFourcc

      public void writeDrmFourcc(int drmFourcc)
      Write a value in the field drm_fourcc.
      Parameters:
      drmFourcc - The new value for the field drm_fourcc
    • readDrmModifier

      public long readDrmModifier()
      Read the value of the field drm_modifier.
      Returns:
      The value of the field drm_modifier
    • writeDrmModifier

      public void writeDrmModifier(long drmModifier)
      Write a value in the field drm_modifier.
      Parameters:
      drmModifier - The new value for the field drm_modifier
    • fromCaps

      public static @Nullable VideoInfoDmaDrm fromCaps(Caps caps)
      Parse caps to generate a GstVideoInfoDmaDrm. Please note that the caps should be a dma drm caps. The gst_video_is_dma_drm_caps() can be used to verify it before calling this function.
      Parameters:
      caps - a GstCaps
      Returns:
      A GstVideoInfoDmaDrm, or null if caps couldn't be parsed.
      Since:
      1.24
    • withCaps

      public static boolean withCaps(VideoInfoDmaDrm drmInfo, Caps caps)
      Parse caps and update info. Please note that the caps should be a dma drm caps. The gst_video_is_dma_drm_caps() can be used to verify it before calling this function.
      Parameters:
      drmInfo - GstVideoInfoDmaDrm
      caps - a GstCaps
      Returns:
      TRUE if caps could be parsed
      Since:
      1.24
    • fromVideoInfo

      public static boolean fromVideoInfo(VideoInfoDmaDrm drmInfo, VideoInfo info, long modifier)
      Fills drmInfo if info's format has a valid drm format and modifier is also valid
      Parameters:
      drmInfo - GstVideoInfoDmaDrm
      info - a GstVideoInfo
      modifier - the associated modifier value.
      Returns:
      true if drmInfo is filled correctly.
      Since:
      1.24
    • init

      public static void init(VideoInfoDmaDrm drmInfo)
      Initialize drmInfo with default values.
      Parameters:
      drmInfo - a GstVideoInfoDmaDrm
      Since:
      1.24
    • free

      public void free()
      Free a GstVideoInfoDmaDrm structure previously allocated with gst_video_info_dma_drm_new()
      Since:
      1.24
    • toCaps

      public @Nullable Caps toCaps()
      Convert the values of this VideoInfoDmaDrm into a GstCaps. Please note that the caps returned will be a dma drm caps which sets format field to DMA_DRM, and contains a new drm-format field. The value of drm-format field is composed of a drm fourcc and a modifier, such as NV12:0x0100000000000002.
      Returns:
      a new GstCaps containing the info in drmInfo.
      Since:
      1.24
    • toVideoInfo

      public boolean toVideoInfo(VideoInfo info)
      Convert the GstVideoInfoDmaDrm into a traditional GstVideoInfo with recognized video format. For DMA kind memory, the non linear DMA format should be recognized as GST_VIDEO_FORMAT_DMA_DRM. This helper function sets info's video format into the default value according to drmInfo's drm_fourcc field.
      Parameters:
      info - GstVideoInfo
      Returns:
      true if info is converted correctly.
      Since:
      1.24