Package org.freedesktop.gstreamer.video
Class VideoCodecFrame
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.freedesktop.gstreamer.video.VideoCodecFrame
- All Implemented Interfaces:
Proxy
A
GstVideoCodecFrame
represents a video frame both in raw and
encoded form.-
Constructor Summary
ConstructorDescriptionAllocate a new VideoCodecFrame.VideoCodecFrame
(int refCount, int flags, int systemFrameNumber, int decodeFrameNumber, int presentationFrameNumber, ClockTime dts, ClockTime pts, ClockTime duration, int distanceFromSync, Buffer inputBuffer, Buffer outputBuffer, ClockTime deadline, MemorySegment userData, DestroyNotify userDataDestroyNotify) Allocate a new VideoCodecFrame with the fields set to the provided values.VideoCodecFrame
(int refCount, int flags, int systemFrameNumber, int decodeFrameNumber, int presentationFrameNumber, ClockTime dts, ClockTime pts, ClockTime duration, int distanceFromSync, Buffer inputBuffer, Buffer outputBuffer, ClockTime deadline, MemorySegment userData, DestroyNotify userDataDestroyNotify, Arena arena) Allocate a new VideoCodecFrame with the fields set to the provided values.VideoCodecFrame
(Arena arena) Allocate a new VideoCodecFrame.VideoCodecFrame
(MemorySegment address) Create a VideoCodecFrame proxy instance for the provided memory address. -
Method Summary
Modifier and TypeMethodDescriptionstatic MemoryLayout
The memory layout of the native struct.static Type
getType()
Get the GType of the VideoCodecFrame classGets private data set on the frame by the subclass via gst_video_codec_frame_set_user_data() previously.Read the value of the fielddeadline
.int
Read the value of the fielddecode_frame_number
.int
Read the value of the fielddistance_from_sync
.readDts()
Read the value of the fielddts
.Read the value of the fieldduration
.int
Read the value of the fieldflags
.Read the value of the fieldinput_buffer
.Read the value of the fieldoutput_buffer
.int
Read the value of the fieldpresentation_frame_number
.readPts()
Read the value of the fieldpts
.int
Read the value of the fieldref_count
.int
Read the value of the fieldsystem_frame_number
.Read the value of the fielduser_data
.Read the value of the fielduser_data_destroy_notify
.ref()
Increases the refcount of the given frame by one.void
SetsuserData
on the frame and theGDestroyNotify
that will be called when the frame is freed.void
unref()
Decreases the refcount of the frame.void
writeDeadline
(ClockTime deadline) Write a value in the fielddeadline
.void
writeDecodeFrameNumber
(int decodeFrameNumber) Write a value in the fielddecode_frame_number
.void
writeDistanceFromSync
(int distanceFromSync) Write a value in the fielddistance_from_sync
.void
Write a value in the fielddts
.void
writeDuration
(ClockTime duration) Write a value in the fieldduration
.void
writeFlags
(int flags) Write a value in the fieldflags
.void
writeInputBuffer
(Buffer inputBuffer) Write a value in the fieldinput_buffer
.void
writeOutputBuffer
(Buffer outputBuffer) Write a value in the fieldoutput_buffer
.void
writePresentationFrameNumber
(int presentationFrameNumber) Write a value in the fieldpresentation_frame_number
.void
Write a value in the fieldpts
.void
writeRefCount
(int refCount) Write a value in the fieldref_count
.void
writeSystemFrameNumber
(int systemFrameNumber) Write a value in the fieldsystem_frame_number
.void
writeUserData
(MemorySegment userData) Write a value in the fielduser_data
.void
writeUserDataDestroyNotify
(DestroyNotify userDataDestroyNotify, Arena _arena) Write a value in the fielduser_data_destroy_notify
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
VideoCodecFrame
Create a VideoCodecFrame proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
VideoCodecFrame
Allocate a new VideoCodecFrame.- Parameters:
arena
- to control the memory allocation scope
-
VideoCodecFrame
public VideoCodecFrame()Allocate a new VideoCodecFrame. The memory is allocated withArena.ofAuto()
. -
VideoCodecFrame
public VideoCodecFrame(int refCount, int flags, int systemFrameNumber, int decodeFrameNumber, int presentationFrameNumber, ClockTime dts, ClockTime pts, ClockTime duration, int distanceFromSync, Buffer inputBuffer, Buffer outputBuffer, ClockTime deadline, MemorySegment userData, DestroyNotify userDataDestroyNotify, Arena arena) Allocate a new VideoCodecFrame with the fields set to the provided values.- Parameters:
refCount
- value for the fieldrefCount
flags
- value for the fieldflags
systemFrameNumber
- value for the fieldsystemFrameNumber
decodeFrameNumber
- value for the fielddecodeFrameNumber
presentationFrameNumber
- value for the fieldpresentationFrameNumber
dts
- value for the fielddts
pts
- value for the fieldpts
duration
- value for the fieldduration
distanceFromSync
- value for the fielddistanceFromSync
inputBuffer
- value for the fieldinputBuffer
outputBuffer
- value for the fieldoutputBuffer
deadline
- value for the fielddeadline
userData
- value for the fielduserData
userDataDestroyNotify
- value for the fielduserDataDestroyNotify
arena
- to control the memory allocation scope
-
VideoCodecFrame
public VideoCodecFrame(int refCount, int flags, int systemFrameNumber, int decodeFrameNumber, int presentationFrameNumber, ClockTime dts, ClockTime pts, ClockTime duration, int distanceFromSync, Buffer inputBuffer, Buffer outputBuffer, ClockTime deadline, MemorySegment userData, DestroyNotify userDataDestroyNotify) Allocate a new VideoCodecFrame with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
refCount
- value for the fieldrefCount
flags
- value for the fieldflags
systemFrameNumber
- value for the fieldsystemFrameNumber
decodeFrameNumber
- value for the fielddecodeFrameNumber
presentationFrameNumber
- value for the fieldpresentationFrameNumber
dts
- value for the fielddts
pts
- value for the fieldpts
duration
- value for the fieldduration
distanceFromSync
- value for the fielddistanceFromSync
inputBuffer
- value for the fieldinputBuffer
outputBuffer
- value for the fieldoutputBuffer
deadline
- value for the fielddeadline
userData
- value for the fielduserData
userDataDestroyNotify
- value for the fielduserDataDestroyNotify
-
-
Method Details
-
getType
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readRefCount
public int readRefCount()Read the value of the fieldref_count
.- Returns:
- The value of the field
ref_count
-
writeRefCount
public void writeRefCount(int refCount) Write a value in the fieldref_count
.- Parameters:
refCount
- The new value for the fieldref_count
-
readFlags
public int readFlags()Read the value of the fieldflags
.- Returns:
- The value of the field
flags
-
writeFlags
public void writeFlags(int flags) Write a value in the fieldflags
.- Parameters:
flags
- The new value for the fieldflags
-
readSystemFrameNumber
public int readSystemFrameNumber()Read the value of the fieldsystem_frame_number
.- Returns:
- The value of the field
system_frame_number
-
writeSystemFrameNumber
public void writeSystemFrameNumber(int systemFrameNumber) Write a value in the fieldsystem_frame_number
.- Parameters:
systemFrameNumber
- The new value for the fieldsystem_frame_number
-
readDecodeFrameNumber
public int readDecodeFrameNumber()Read the value of the fielddecode_frame_number
.- Returns:
- The value of the field
decode_frame_number
-
writeDecodeFrameNumber
public void writeDecodeFrameNumber(int decodeFrameNumber) Write a value in the fielddecode_frame_number
.- Parameters:
decodeFrameNumber
- The new value for the fielddecode_frame_number
-
readPresentationFrameNumber
public int readPresentationFrameNumber()Read the value of the fieldpresentation_frame_number
.- Returns:
- The value of the field
presentation_frame_number
-
writePresentationFrameNumber
public void writePresentationFrameNumber(int presentationFrameNumber) Write a value in the fieldpresentation_frame_number
.- Parameters:
presentationFrameNumber
- The new value for the fieldpresentation_frame_number
-
readDts
-
writeDts
Write a value in the fielddts
.- Parameters:
dts
- The new value for the fielddts
-
readPts
-
writePts
Write a value in the fieldpts
.- Parameters:
pts
- The new value for the fieldpts
-
readDuration
Read the value of the fieldduration
.- Returns:
- The value of the field
duration
-
writeDuration
Write a value in the fieldduration
.- Parameters:
duration
- The new value for the fieldduration
-
readDistanceFromSync
public int readDistanceFromSync()Read the value of the fielddistance_from_sync
.- Returns:
- The value of the field
distance_from_sync
-
writeDistanceFromSync
public void writeDistanceFromSync(int distanceFromSync) Write a value in the fielddistance_from_sync
.- Parameters:
distanceFromSync
- The new value for the fielddistance_from_sync
-
readInputBuffer
Read the value of the fieldinput_buffer
.- Returns:
- The value of the field
input_buffer
-
writeInputBuffer
Write a value in the fieldinput_buffer
.- Parameters:
inputBuffer
- The new value for the fieldinput_buffer
-
readOutputBuffer
Read the value of the fieldoutput_buffer
.- Returns:
- The value of the field
output_buffer
-
writeOutputBuffer
Write a value in the fieldoutput_buffer
.- Parameters:
outputBuffer
- The new value for the fieldoutput_buffer
-
readDeadline
Read the value of the fielddeadline
.- Returns:
- The value of the field
deadline
-
writeDeadline
Write a value in the fielddeadline
.- Parameters:
deadline
- The new value for the fielddeadline
-
readUserData
Read the value of the fielduser_data
.- Returns:
- The value of the field
user_data
-
writeUserData
Write a value in the fielduser_data
.- Parameters:
userData
- The new value for the fielduser_data
-
readUserDataDestroyNotify
Read the value of the fielduser_data_destroy_notify
.- Returns:
- The value of the field
user_data_destroy_notify
-
writeUserDataDestroyNotify
Write a value in the fielduser_data_destroy_notify
.- Parameters:
userDataDestroyNotify
- The new value for the fielduser_data_destroy_notify
_arena
- to control the memory allocation scope
-
getUserData
Gets private data set on the frame by the subclass via gst_video_codec_frame_set_user_data() previously.- Returns:
- The previously set user_data
-
ref
-
setUserData
public void setUserData()SetsuserData
on the frame and theGDestroyNotify
that will be called when the frame is freed. Allows to attach private data by the subclass to frames.If a
userData
was previously set, then the previous setnotify
will be called before theuserData
is replaced. -
unref
public void unref()Decreases the refcount of the frame. If the refcount reaches 0, the frame will be freed.
-