gi-gstaudio-1.0.28: GStreamerAudio bindings
CopyrightWill Thompson and Iñaki García Etxebarria
LicenseLGPL-2.1
MaintainerIñaki García Etxebarria
Safe HaskellSafe-Inferred
LanguageHaskell2010

GI.GstAudio.Structs.DsdPlaneOffsetMeta

Description

Buffer metadata describing planar DSD contents in the buffer. This is not needed for interleaved DSD data, and is required for non-interleaved (= planar) data.

The different channels in offsets are always in the GStreamer channel order. Zero-copy channel reordering can be implemented by swapping the values in offsets.

It is not allowed for channels to overlap in memory, i.e. for each i in [0, channels), the range [offsets[i], offsets[i] + numBytesPerChannel) must not overlap with any other such range.

It is, however, allowed to have parts of the buffer memory unused, by using offsets and numBytesPerChannel in such a way that leave gaps on it. This is used to implement zero-copy clipping in non-interleaved buffers.

Obviously, due to the above, it is not safe to infer the number of valid bytes from the size of the buffer. You should always use the numBytesPerChannel variable of this metadata.

Since: 1.24

Synopsis

Exported types

newtype DsdPlaneOffsetMeta Source #

Memory-managed wrapper type.

Constructors

DsdPlaneOffsetMeta (ManagedPtr DsdPlaneOffsetMeta) 

newZeroDsdPlaneOffsetMeta :: MonadIO m => m DsdPlaneOffsetMeta Source #

Construct a DsdPlaneOffsetMeta struct initialized to zero.

Methods

getInfo

dsdPlaneOffsetMetaGetInfo :: (HasCallStack, MonadIO m) => m MetaInfo Source #

No description available in the introspection data.

Properties

meta

parent Meta

getDsdPlaneOffsetMetaMeta :: MonadIO m => DsdPlaneOffsetMeta -> m Meta Source #

Get the value of the “meta” field. When overloading is enabled, this is equivalent to

get dsdPlaneOffsetMeta #meta

numBytesPerChannel

the number of valid bytes per channel in the buffer

getDsdPlaneOffsetMetaNumBytesPerChannel :: MonadIO m => DsdPlaneOffsetMeta -> m CSize Source #

Get the value of the “num_bytes_per_channel” field. When overloading is enabled, this is equivalent to

get dsdPlaneOffsetMeta #numBytesPerChannel

setDsdPlaneOffsetMetaNumBytesPerChannel :: MonadIO m => DsdPlaneOffsetMeta -> CSize -> m () Source #

Set the value of the “num_bytes_per_channel” field. When overloading is enabled, this is equivalent to

set dsdPlaneOffsetMeta [ #numBytesPerChannel := value ]

numChannels

number of channels in the DSD data

getDsdPlaneOffsetMetaNumChannels :: MonadIO m => DsdPlaneOffsetMeta -> m Int32 Source #

Get the value of the “num_channels” field. When overloading is enabled, this is equivalent to

get dsdPlaneOffsetMeta #numChannels

setDsdPlaneOffsetMetaNumChannels :: MonadIO m => DsdPlaneOffsetMeta -> Int32 -> m () Source #

Set the value of the “num_channels” field. When overloading is enabled, this is equivalent to

set dsdPlaneOffsetMeta [ #numChannels := value ]

offsets

the offsets (in bytes) where each channel plane starts in the buffer

getDsdPlaneOffsetMetaOffsets :: MonadIO m => DsdPlaneOffsetMeta -> m CSize Source #

Get the value of the “offsets” field. When overloading is enabled, this is equivalent to

get dsdPlaneOffsetMeta #offsets

setDsdPlaneOffsetMetaOffsets :: MonadIO m => DsdPlaneOffsetMeta -> CSize -> m () Source #

Set the value of the “offsets” field. When overloading is enabled, this is equivalent to

set dsdPlaneOffsetMeta [ #offsets := value ]