Package org.freedesktop.gstreamer.video
Class VideoFormatInfo
java.lang.Object
org.javagi.base.ProxyInstance
org.freedesktop.gstreamer.video.VideoFormatInfo
-
Constructor Summary
ConstructorsConstructorDescriptionAllocate a new VideoFormatInfo.VideoFormatInfo(Arena arena) Allocate a new VideoFormatInfo.VideoFormatInfo(MemorySegment address) Create a VideoFormatInfo proxy instance for the provided memory address.VideoFormatInfo(VideoFormat format, String name, String description, Set<VideoFormatFlags> flags, int bits, int nComponents, int[] shift, int[] depth, int[] pixelStride, int nPlanes, int[] plane, int[] poffset, int[] wSub, int[] hSub, VideoFormat unpackFormat, VideoFormatUnpack unpackFunc, int packLines, VideoFormatPack packFunc, VideoTileMode tileMode, int tileWs, int tileHs, VideoTileInfo[] tileInfo) Allocate a new VideoFormatInfo with the fields set to the provided values.VideoFormatInfo(VideoFormat format, String name, String description, Set<VideoFormatFlags> flags, int bits, int nComponents, int[] shift, int[] depth, int[] pixelStride, int nPlanes, int[] plane, int[] poffset, int[] wSub, int[] hSub, VideoFormat unpackFormat, VideoFormatUnpack unpackFunc, int packLines, VideoFormatPack packFunc, VideoTileMode tileMode, int tileWs, int tileHs, VideoTileInfo[] tileInfo, Arena arena) Allocate a new VideoFormatInfo with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionvoidFillcomponentswith the number of all the components packed in planepfor the formatinfo.A value of -1 incomponentsindicates that no more components are packed in the plane.intextrapolateStride(int plane, int stride) Extrapolateplanestride from the first stride of an image.static MemoryLayoutThe memory layout of the native struct.intreadBits()Read the value of the fieldbits.@org.jspecify.annotations.Nullable int @Nullable []Read the value of the fielddepth.Read the value of the fielddescription.Read the value of the fieldflags.Read the value of the fieldformat.@org.jspecify.annotations.Nullable int @Nullable []readHSub()Read the value of the fieldh_sub.readName()Read the value of the fieldname.intRead the value of the fieldn_components.intRead the value of the fieldn_planes.@Nullable VideoFormatPackRead the value of the fieldpack_func.intRead the value of the fieldpack_lines.@org.jspecify.annotations.Nullable int @Nullable []Read the value of the fieldpixel_stride.@org.jspecify.annotations.Nullable int @Nullable []Read the value of the fieldplane.@org.jspecify.annotations.Nullable int @Nullable []Read the value of the fieldpoffset.@org.jspecify.annotations.Nullable int @Nullable []Read the value of the fieldshift.intRead the value of the fieldtile_hs.@Nullable VideoTileInfo @Nullable []Read the value of the fieldtile_info.Read the value of the fieldtile_mode.intRead the value of the fieldtile_ws.Read the value of the fieldunpack_format.@Nullable VideoFormatUnpackRead the value of the fieldunpack_func.@org.jspecify.annotations.Nullable int @Nullable []readWSub()Read the value of the fieldw_sub.voidwriteBits(int bits) Write a value in the fieldbits.voidwriteDepth(@org.jspecify.annotations.Nullable int @Nullable [] depth, Arena _arena) Write a value in the fielddepth.voidwriteDescription(String description, Arena _arena) Write a value in the fielddescription.voidwriteFlags(Set<VideoFormatFlags> flags) Write a value in the fieldflags.voidwriteFormat(VideoFormat format) Write a value in the fieldformat.voidWrite a value in the fieldh_sub.voidWrite a value in the fieldname.voidwriteNComponents(int nComponents) Write a value in the fieldn_components.voidwriteNPlanes(int nPlanes) Write a value in the fieldn_planes.voidwritePackFunc(@Nullable VideoFormatPack packFunc, Arena _arena) Write a value in the fieldpack_func.voidwritePackLines(int packLines) Write a value in the fieldpack_lines.voidwritePixelStride(@org.jspecify.annotations.Nullable int @Nullable [] pixelStride, Arena _arena) Write a value in the fieldpixel_stride.voidwritePlane(@org.jspecify.annotations.Nullable int @Nullable [] plane, Arena _arena) Write a value in the fieldplane.voidwritePoffset(@org.jspecify.annotations.Nullable int @Nullable [] poffset, Arena _arena) Write a value in the fieldpoffset.voidwriteShift(@org.jspecify.annotations.Nullable int @Nullable [] shift, Arena _arena) Write a value in the fieldshift.voidwriteTileHs(int tileHs) Write a value in the fieldtile_hs.voidwriteTileInfo(@Nullable VideoTileInfo @Nullable [] tileInfo, Arena _arena) Write a value in the fieldtile_info.voidwriteTileMode(VideoTileMode tileMode) Write a value in the fieldtile_mode.voidwriteTileWs(int tileWs) Write a value in the fieldtile_ws.voidwriteUnpackFormat(VideoFormat unpackFormat) Write a value in the fieldunpack_format.voidwriteUnpackFunc(@Nullable VideoFormatUnpack unpackFunc, Arena _arena) Write a value in the fieldunpack_func.voidWrite a value in the fieldw_sub.Methods inherited from class org.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
VideoFormatInfo
Create a VideoFormatInfo proxy instance for the provided memory address.- Parameters:
address- the memory address of the native object
-
VideoFormatInfo
Allocate a new VideoFormatInfo.- Parameters:
arena- to control the memory allocation scope
-
VideoFormatInfo
public VideoFormatInfo()Allocate a new VideoFormatInfo. The memory is allocated withArena.ofAuto(). -
VideoFormatInfo
public VideoFormatInfo(VideoFormat format, String name, String description, Set<VideoFormatFlags> flags, int bits, int nComponents, int[] shift, int[] depth, int[] pixelStride, int nPlanes, int[] plane, int[] poffset, int[] wSub, int[] hSub, VideoFormat unpackFormat, VideoFormatUnpack unpackFunc, int packLines, VideoFormatPack packFunc, VideoTileMode tileMode, int tileWs, int tileHs, VideoTileInfo[] tileInfo, Arena arena) Allocate a new VideoFormatInfo with the fields set to the provided values.- Parameters:
format- value for the fieldformatname- value for the fieldnamedescription- value for the fielddescriptionflags- value for the fieldflagsbits- value for the fieldbitsnComponents- value for the fieldnComponentsshift- value for the fieldshiftdepth- value for the fielddepthpixelStride- value for the fieldpixelStridenPlanes- value for the fieldnPlanesplane- value for the fieldplanepoffset- value for the fieldpoffsetwSub- value for the fieldwSubhSub- value for the fieldhSubunpackFormat- value for the fieldunpackFormatunpackFunc- value for the fieldunpackFuncpackLines- value for the fieldpackLinespackFunc- value for the fieldpackFunctileMode- value for the fieldtileModetileWs- value for the fieldtileWstileHs- value for the fieldtileHstileInfo- value for the fieldtileInfoarena- to control the memory allocation scope
-
VideoFormatInfo
public VideoFormatInfo(VideoFormat format, String name, String description, Set<VideoFormatFlags> flags, int bits, int nComponents, int[] shift, int[] depth, int[] pixelStride, int nPlanes, int[] plane, int[] poffset, int[] wSub, int[] hSub, VideoFormat unpackFormat, VideoFormatUnpack unpackFunc, int packLines, VideoFormatPack packFunc, VideoTileMode tileMode, int tileWs, int tileHs, VideoTileInfo[] tileInfo) Allocate a new VideoFormatInfo with the fields set to the provided values. The memory is allocated withArena.ofAuto().- Parameters:
format- value for the fieldformatname- value for the fieldnamedescription- value for the fielddescriptionflags- value for the fieldflagsbits- value for the fieldbitsnComponents- value for the fieldnComponentsshift- value for the fieldshiftdepth- value for the fielddepthpixelStride- value for the fieldpixelStridenPlanes- value for the fieldnPlanesplane- value for the fieldplanepoffset- value for the fieldpoffsetwSub- value for the fieldwSubhSub- value for the fieldhSubunpackFormat- value for the fieldunpackFormatunpackFunc- value for the fieldunpackFuncpackLines- value for the fieldpackLinespackFunc- value for the fieldpackFunctileMode- value for the fieldtileModetileWs- value for the fieldtileWstileHs- value for the fieldtileHstileInfo- value for the fieldtileInfo
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readFormat
Read the value of the fieldformat.- Returns:
- The value of the field
format
-
writeFormat
Write a value in the fieldformat.- Parameters:
format- The new value for the fieldformat
-
readName
-
writeName
-
readDescription
Read the value of the fielddescription.- Returns:
- The value of the field
description
-
writeDescription
-
readFlags
Read the value of the fieldflags.- Returns:
- The value of the field
flags
-
writeFlags
Write a value in the fieldflags.- Parameters:
flags- The new value for the fieldflags
-
readBits
public int readBits()Read the value of the fieldbits.- Returns:
- The value of the field
bits
-
writeBits
public void writeBits(int bits) Write a value in the fieldbits.- Parameters:
bits- The new value for the fieldbits
-
readNComponents
public int readNComponents()Read the value of the fieldn_components.- Returns:
- The value of the field
n_components
-
writeNComponents
public void writeNComponents(int nComponents) Write a value in the fieldn_components.- Parameters:
nComponents- The new value for the fieldn_components
-
readShift
public @org.jspecify.annotations.Nullable int @Nullable [] readShift()Read the value of the fieldshift.- Returns:
- The value of the field
shift
-
writeShift
Write a value in the fieldshift.- Parameters:
shift- The new value for the fieldshift
-
readDepth
public @org.jspecify.annotations.Nullable int @Nullable [] readDepth()Read the value of the fielddepth.- Returns:
- The value of the field
depth
-
writeDepth
Write a value in the fielddepth.- Parameters:
depth- The new value for the fielddepth
-
readPixelStride
public @org.jspecify.annotations.Nullable int @Nullable [] readPixelStride()Read the value of the fieldpixel_stride.- Returns:
- The value of the field
pixel_stride
-
writePixelStride
public void writePixelStride(@org.jspecify.annotations.Nullable int @Nullable [] pixelStride, Arena _arena) Write a value in the fieldpixel_stride.- Parameters:
pixelStride- The new value for the fieldpixel_stride
-
readNPlanes
public int readNPlanes()Read the value of the fieldn_planes.- Returns:
- The value of the field
n_planes
-
writeNPlanes
public void writeNPlanes(int nPlanes) Write a value in the fieldn_planes.- Parameters:
nPlanes- The new value for the fieldn_planes
-
readPlane
public @org.jspecify.annotations.Nullable int @Nullable [] readPlane()Read the value of the fieldplane.- Returns:
- The value of the field
plane
-
writePlane
Write a value in the fieldplane.- Parameters:
plane- The new value for the fieldplane
-
readPoffset
public @org.jspecify.annotations.Nullable int @Nullable [] readPoffset()Read the value of the fieldpoffset.- Returns:
- The value of the field
poffset
-
writePoffset
Write a value in the fieldpoffset.- Parameters:
poffset- The new value for the fieldpoffset
-
readWSub
public @org.jspecify.annotations.Nullable int @Nullable [] readWSub()Read the value of the fieldw_sub.- Returns:
- The value of the field
w_sub
-
writeWSub
Write a value in the fieldw_sub.- Parameters:
wSub- The new value for the fieldw_sub
-
readHSub
public @org.jspecify.annotations.Nullable int @Nullable [] readHSub()Read the value of the fieldh_sub.- Returns:
- The value of the field
h_sub
-
writeHSub
Write a value in the fieldh_sub.- Parameters:
hSub- The new value for the fieldh_sub
-
readUnpackFormat
Read the value of the fieldunpack_format.- Returns:
- The value of the field
unpack_format
-
writeUnpackFormat
Write a value in the fieldunpack_format.- Parameters:
unpackFormat- The new value for the fieldunpack_format
-
readUnpackFunc
Read the value of the fieldunpack_func.- Returns:
- The value of the field
unpack_func
-
writeUnpackFunc
Write a value in the fieldunpack_func.- Parameters:
unpackFunc- The new value for the fieldunpack_func_arena- to control the memory allocation scope
-
readPackLines
public int readPackLines()Read the value of the fieldpack_lines.- Returns:
- The value of the field
pack_lines
-
writePackLines
public void writePackLines(int packLines) Write a value in the fieldpack_lines.- Parameters:
packLines- The new value for the fieldpack_lines
-
readPackFunc
Read the value of the fieldpack_func.- Returns:
- The value of the field
pack_func
-
writePackFunc
Write a value in the fieldpack_func.- Parameters:
packFunc- The new value for the fieldpack_func_arena- to control the memory allocation scope
-
readTileMode
Read the value of the fieldtile_mode.- Returns:
- The value of the field
tile_mode
-
writeTileMode
Write a value in the fieldtile_mode.- Parameters:
tileMode- The new value for the fieldtile_mode
-
readTileWs
public int readTileWs()Read the value of the fieldtile_ws.- Returns:
- The value of the field
tile_ws
-
writeTileWs
public void writeTileWs(int tileWs) Write a value in the fieldtile_ws.- Parameters:
tileWs- The new value for the fieldtile_ws
-
readTileHs
public int readTileHs()Read the value of the fieldtile_hs.- Returns:
- The value of the field
tile_hs
-
writeTileHs
public void writeTileHs(int tileHs) Write a value in the fieldtile_hs.- Parameters:
tileHs- The new value for the fieldtile_hs
-
readTileInfo
Read the value of the fieldtile_info.- Returns:
- The value of the field
tile_info
-
writeTileInfo
Write a value in the fieldtile_info.- Parameters:
tileInfo- The new value for the fieldtile_info
-
component
Fillcomponentswith the number of all the components packed in planepfor the formatinfo.A value of -1 incomponentsindicates that no more components are packed in the plane.- Parameters:
plane- a plane numbercomponents- array used to store component numbers- Since:
- 1.18
-
extrapolateStride
public int extrapolateStride(int plane, int stride) Extrapolateplanestride from the first stride of an image. This helper is useful to support legacy API were only one stride is supported.- Parameters:
plane- a plane numberstride- The fist plane stride- Returns:
- The extrapolated stride for
plane - Since:
- 1.22
-