Package org.freedesktop.gstreamer.audio
Class AudioClippingMeta
java.lang.Object
io.github.jwharm.javagi.base.ProxyInstance
org.freedesktop.gstreamer.audio.AudioClippingMeta
- All Implemented Interfaces:
Proxy
Extra buffer metadata describing how much audio has to be clipped from
the start or end of a buffer. This is used for compressed formats, where
the first frame usually has some additional samples due to encoder and
decoder delays, and the last frame usually has some additional samples to
be able to fill the complete last frame.
This is used to ensure that decoded data in the end has the same amount of samples, and multiply decoded streams can be gaplessly concatenated.
Note: If clipping of the start is done by adjusting the segment, this meta has to be dropped from buffers as otherwise clipping could happen twice.
-
Constructor Summary
ConstructorDescriptionAllocate a new AudioClippingMeta.AudioClippingMeta
(Arena arena) Allocate a new AudioClippingMeta.AudioClippingMeta
(MemorySegment address) Create a AudioClippingMeta proxy instance for the provided memory address.AudioClippingMeta
(Meta meta, Format format, long start, long end) Allocate a new AudioClippingMeta with the fields set to the provided values.AudioClippingMeta
(Meta meta, Format format, long start, long end, Arena arena) Allocate a new AudioClippingMeta with the fields set to the provided values. -
Method Summary
Modifier and TypeMethodDescriptionstatic MetaInfo
getInfo()
static MemoryLayout
The memory layout of the native struct.long
readEnd()
Read the value of the fieldend
.Read the value of the fieldformat
.readMeta()
Read the value of the fieldmeta
.long
Read the value of the fieldstart
.void
writeEnd
(long end) Write a value in the fieldend
.void
writeFormat
(Format format) Write a value in the fieldformat
.void
Write a value in the fieldmeta
.void
writeStart
(long start) Write a value in the fieldstart
.Methods inherited from class io.github.jwharm.javagi.base.ProxyInstance
equals, handle, hashCode
-
Constructor Details
-
AudioClippingMeta
Create a AudioClippingMeta proxy instance for the provided memory address.- Parameters:
address
- the memory address of the native object
-
AudioClippingMeta
Allocate a new AudioClippingMeta.- Parameters:
arena
- to control the memory allocation scope
-
AudioClippingMeta
public AudioClippingMeta()Allocate a new AudioClippingMeta. The memory is allocated withArena.ofAuto()
. -
AudioClippingMeta
Allocate a new AudioClippingMeta with the fields set to the provided values.- Parameters:
meta
- value for the fieldmeta
format
- value for the fieldformat
start
- value for the fieldstart
end
- value for the fieldend
arena
- to control the memory allocation scope
-
AudioClippingMeta
Allocate a new AudioClippingMeta with the fields set to the provided values. The memory is allocated withArena.ofAuto()
.- Parameters:
meta
- value for the fieldmeta
format
- value for the fieldformat
start
- value for the fieldstart
end
- value for the fieldend
-
-
Method Details
-
getMemoryLayout
The memory layout of the native struct.- Returns:
- the memory layout
-
readMeta
-
writeMeta
Write a value in the fieldmeta
.- Parameters:
meta
- The new value for the fieldmeta
-
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
-
readStart
public long readStart()Read the value of the fieldstart
.- Returns:
- The value of the field
start
-
writeStart
public void writeStart(long start) Write a value in the fieldstart
.- Parameters:
start
- The new value for the fieldstart
-
readEnd
public long readEnd()Read the value of the fieldend
.- Returns:
- The value of the field
end
-
writeEnd
public void writeEnd(long end) Write a value in the fieldend
.- Parameters:
end
- The new value for the fieldend
-
getInfo
-