Package org.freedesktop.gstreamer.video
Class VideoFormatInfo
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.freedesktop.gstreamer.video.VideoFormatInfo
-
Constructor Summary
ConstructorDescriptionAllocate 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 TypeMethodDescriptionvoid
Fillcomponents
with the number of all the components packed in planep
for the format this VideoFormatInfo.int
extrapolateStride
(int plane, int stride) Extrapolateplane
stride from the first stride of an image.static MemoryLayout
The memory layout of the native struct.int
readBits()
Read the value of the fieldbits
.int[]
Read the value of the fielddepth
.Read the value of the fielddescription
.Read the value of the fieldflags
.Read the value of the fieldformat
.int[]
readHSub()
Read the value of the fieldh_sub
.readName()
Read the value of the fieldname
.int
Read the value of the fieldn_components
.int
Read the value of the fieldn_planes
.Read the value of the fieldpack_func
.int
Read the value of the fieldpack_lines
.int[]
Read the value of the fieldpixel_stride
.int[]
Read the value of the fieldplane
.int[]
Read the value of the fieldpoffset
.int[]
Read the value of the fieldshift
.int
Read the value of the fieldtile_hs
.Read the value of the fieldtile_info
.Read the value of the fieldtile_mode
.int
Read the value of the fieldtile_ws
.Read the value of the fieldunpack_format
.Read the value of the fieldunpack_func
.int[]
readWSub()
Read the value of the fieldw_sub
.void
writeBits
(int bits) Write a value in the fieldbits
.void
writeDepth
(int[] depth, Arena _arena) Write a value in the fielddepth
.void
writeDescription
(String description, Arena _arena) Write a value in the fielddescription
.void
writeFlags
(Set<VideoFormatFlags> flags) Write a value in the fieldflags
.void
writeFormat
(VideoFormat format) Write a value in the fieldformat
.void
Write a value in the fieldh_sub
.void
Write a value in the fieldname
.void
writeNComponents
(int nComponents) Write a value in the fieldn_components
.void
writeNPlanes
(int nPlanes) Write a value in the fieldn_planes
.void
writePackFunc
(VideoFormatPack packFunc, Arena _arena) Write a value in the fieldpack_func
.void
writePackLines
(int packLines) Write a value in the fieldpack_lines
.void
writePixelStride
(int[] pixelStride, Arena _arena) Write a value in the fieldpixel_stride
.void
writePlane
(int[] plane, Arena _arena) Write a value in the fieldplane
.void
writePoffset
(int[] poffset, Arena _arena) Write a value in the fieldpoffset
.void
writeShift
(int[] shift, Arena _arena) Write a value in the fieldshift
.void
writeTileHs
(int tileHs) Write a value in the fieldtile_hs
.void
writeTileInfo
(VideoTileInfo[] tileInfo, Arena _arena) Write a value in the fieldtile_info
.void
writeTileMode
(VideoTileMode tileMode) Write a value in the fieldtile_mode
.void
writeTileWs
(int tileWs) Write a value in the fieldtile_ws
.void
writeUnpackFormat
(VideoFormat unpackFormat) Write a value in the fieldunpack_format
.void
writeUnpackFunc
(VideoFormatUnpack unpackFunc, Arena _arena) Write a value in the fieldunpack_func
.void
Write a value in the fieldw_sub
.Methods inherited from class io.github.jwharm.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 fieldformat
name
- value for the fieldname
description
- value for the fielddescription
flags
- value for the fieldflags
bits
- value for the fieldbits
nComponents
- value for the fieldnComponents
shift
- value for the fieldshift
depth
- value for the fielddepth
pixelStride
- value for the fieldpixelStride
nPlanes
- value for the fieldnPlanes
plane
- value for the fieldplane
poffset
- value for the fieldpoffset
wSub
- value for the fieldwSub
hSub
- value for the fieldhSub
unpackFormat
- value for the fieldunpackFormat
unpackFunc
- value for the fieldunpackFunc
packLines
- value for the fieldpackLines
packFunc
- value for the fieldpackFunc
tileMode
- value for the fieldtileMode
tileWs
- value for the fieldtileWs
tileHs
- value for the fieldtileHs
tileInfo
- value for the fieldtileInfo
arena
- 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 fieldformat
name
- value for the fieldname
description
- value for the fielddescription
flags
- value for the fieldflags
bits
- value for the fieldbits
nComponents
- value for the fieldnComponents
shift
- value for the fieldshift
depth
- value for the fielddepth
pixelStride
- value for the fieldpixelStride
nPlanes
- value for the fieldnPlanes
plane
- value for the fieldplane
poffset
- value for the fieldpoffset
wSub
- value for the fieldwSub
hSub
- value for the fieldhSub
unpackFormat
- value for the fieldunpackFormat
unpackFunc
- value for the fieldunpackFunc
packLines
- value for the fieldpackLines
packFunc
- value for the fieldpackFunc
tileMode
- value for the fieldtileMode
tileWs
- value for the fieldtileWs
tileHs
- value for the fieldtileHs
tileInfo
- 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 int[] 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
_arena
- to control the memory allocation scope
-
readDepth
public int[] 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
_arena
- to control the memory allocation scope
-
readPixelStride
public int[] readPixelStride()Read the value of the fieldpixel_stride
.- Returns:
- The value of the field
pixel_stride
-
writePixelStride
Write a value in the fieldpixel_stride
.- Parameters:
pixelStride
- The new value for the fieldpixel_stride
_arena
- to control the memory allocation scope
-
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 int[] 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
_arena
- to control the memory allocation scope
-
readPoffset
public int[] 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
_arena
- to control the memory allocation scope
-
readWSub
public int[] 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
_arena
- to control the memory allocation scope
-
readHSub
public int[] 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
_arena
- to control the memory allocation scope
-
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
_arena
- to control the memory allocation scope
-
component
Fillcomponents
with the number of all the components packed in planep
for the format this VideoFormatInfo. A value of -1 incomponents
indicates that no more components are packed in the plane.- Parameters:
plane
- a plane numbercomponents
- array used to store component numbers
-
extrapolateStride
public int extrapolateStride(int plane, int stride) Extrapolateplane
stride 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
-