Package org.freedesktop.gstreamer.gst
Class ReferenceTimestampMeta
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.freedesktop.gstreamer.gst.ReferenceTimestampMeta
- All Implemented Interfaces:
Proxy
GstReferenceTimestampMeta
can be used to attach alternative timestamps and
possibly durations to a GstBuffer
. These are generally not according to
the pipeline clock and could be e.g. the NTP timestamp when the media was
captured.
The reference is stored as a GstCaps
in reference
. Examples of valid
references would be
timestamp/x-drivername-stream
: for timestamps that are locally generated by some driver nameddrivername
when generating the stream, e.g. based on a frame countertimestamp/x-ntp, host=pool.ntp.org, port=123
: for timestamps based on a specific NTP server. Note that the host/port parameters might not always be given.timestamp/x-ptp, version=IEEE1588-2008, domain=1
: for timestamps based on a given PTP clock.timestamp/x-unix
: for timestamps based on the UNIX epoch according to the local clock.
Since 1.24 it can be serialized using gst_meta_serialize() and gst_meta_deserialize().
-
Constructor Summary
ConstructorDescriptionAllocate a new ReferenceTimestampMeta.ReferenceTimestampMeta
(Arena arena) Allocate a new ReferenceTimestampMeta.ReferenceTimestampMeta
(MemorySegment address) Create a ReferenceTimestampMeta proxy instance for the provided memory address.ReferenceTimestampMeta
(Meta parent, Caps reference, ClockTime timestamp, ClockTime duration) Allocate a new ReferenceTimestampMeta with the fields set to the provided values.ReferenceTimestampMeta
(Meta parent, Caps reference, ClockTime timestamp, ClockTime duration, Arena arena) Allocate a new ReferenceTimestampMeta with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionstatic MetaInfo
getInfo()
Gets the globalGstMetaInfo
describing theGstReferenceTimestampMeta
meta.static MemoryLayout
The memory layout of the native struct.Read the value of the fieldduration
.Read the value of the fieldparent
.Read the value of the fieldreference
.Read the value of the fieldtimestamp
.void
writeDuration
(ClockTime duration) Write a value in the fieldduration
.void
writeParent
(Meta parent) Write a value in the fieldparent
.void
writeReference
(Caps reference) Write a value in the fieldreference
.void
writeTimestamp
(ClockTime timestamp) Write a value in the fieldtimestamp
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
ReferenceTimestampMeta
Create a ReferenceTimestampMeta proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
ReferenceTimestampMeta
Allocate a new ReferenceTimestampMeta.- Parameters:
arena
- to control the memory allocation scope
-
ReferenceTimestampMeta
public ReferenceTimestampMeta()Allocate a new ReferenceTimestampMeta. The memory is allocated withArena.ofAuto()
. -
ReferenceTimestampMeta
public ReferenceTimestampMeta(Meta parent, Caps reference, ClockTime timestamp, ClockTime duration, Arena arena) Allocate a new ReferenceTimestampMeta with the fields set to the provided values.- Parameters:
parent
- value for the fieldparent
reference
- value for the fieldreference
timestamp
- value for the fieldtimestamp
duration
- value for the fieldduration
arena
- to control the memory allocation scope
-
ReferenceTimestampMeta
Allocate a new ReferenceTimestampMeta with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
parent
- value for the fieldparent
reference
- value for the fieldreference
timestamp
- value for the fieldtimestamp
duration
- value for the fieldduration
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readParent
-
writeParent
Write a value in the fieldparent
.- Parameters:
parent
- The new value for the fieldparent
-
readReference
Read the value of the fieldreference
.- Returns:
- The value of the field
reference
-
writeReference
Write a value in the fieldreference
.- Parameters:
reference
- The new value for the fieldreference
-
readTimestamp
Read the value of the fieldtimestamp
.- Returns:
- The value of the field
timestamp
-
writeTimestamp
Write a value in the fieldtimestamp
.- Parameters:
timestamp
- The new value for the fieldtimestamp
-
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
-
getInfo
Gets the globalGstMetaInfo
describing theGstReferenceTimestampMeta
meta.- Returns:
- The
GstMetaInfo
-