spa_data Struct Reference
SPA » Buffers

Data for a buffer this stays constant for a buffer. More...

## Data Fields

uint32_t | type
| memory type, one of enum spa_data_type, when allocating memory, the type contains a bitmask of allowed types. More...
uint32_t | flags
| data flags More...
int64_t | fd
| optional fd for data More...
uint32_t | mapoffset
| offset to map fd at More...
uint32_t | maxsize
| max size of data More...
void * | data
| optional data pointer More...
struct spa_chunk * | chunk
| valid chunk of memory More...

## Detailed Description

Data for a buffer this stays constant for a buffer.

Examples
  export-source.c, spa/examples/adapter-control.c, spa/examples/example-control.c, spa/examples/local-libcamera.c, spa/examples/local-v4l2.c, video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## Field Documentation

## type

uint32_t spa_data::type

memory type, one of enum spa_data_type, when allocating memory, the type contains a bitmask of allowed types.

SPA_ID_INVALID is a special value for the allocator to indicate that the other side did not explicitly specify any supported data types. It should probably use a memory type that does not require special handling in addition to simple mmap/munmap.

Examples
  export-sink.c, export-source.c, local-v4l2.c, video-play-fixate.c, video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## flags

uint32_t spa_data::flags

data flags

Examples
  video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## fd

int64_t spa_data::fd

optional fd for data

Examples
  export-sink.c, export-source.c, local-v4l2.c, video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## mapoffset

uint32_t spa_data::mapoffset

offset to map fd at

Examples
  export-sink.c, export-source.c, local-v4l2.c, video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## maxsize

uint32_t spa_data::maxsize

max size of data

Examples
  audio-src.c, export-sink.c, export-source.c, local-v4l2.c, tutorial4.c, video-src-alloc.c, video-src-fixate.c, and video-src-reneg.c.

## data

void* spa_data::data

optional data pointer

Examples
  audio-src.c, export-sink.c, export-source.c, local-v4l2.c, spa/examples/local-libcamera.c, spa/examples/local-v4l2.c, tutorial4.c, tutorial5.c, video-dsp-play.c, video-play-fixate.c, video-play-pull.c, video-play-reneg.c, video-play.c, video-src-alloc.c, video-src-fixate.c, video-src-reneg.c, and video-src.c.

## chunk

struct spa_chunk* spa_data::chunk

valid chunk of memory

Examples
  audio-src.c, export-sink.c, export-source.c, local-v4l2.c, spa/examples/local-libcamera.c, spa/examples/local-v4l2.c, tutorial4.c, tutorial5.c, video-dsp-play.c, video-play-fixate.c, video-play-pull.c, video-play-reneg.c, video-play.c, video-src-alloc.c, video-src-fixate.c, video-src-reneg.c, and video-src.c.

The documentation for this struct was generated from the following file:

- spa/buffer/buffer.h