One decoded access unit.
More...
#include <StormByte/multimedia/pipeline/frame.hxx>
|
|
| const std::optional< Property::Duration > & | Pts () const noexcept |
| | Presentation timestamp on the stream clock.
|
| |
| const std::optional< Property::Duration > & | Dts () const noexcept |
| | Decode timestamp on the stream clock.
|
| |
| const std::optional< Property::Duration > & | Duration () const noexcept |
| | Frame duration on the stream clock.
|
| |
| const std::optional< std::string > & | Language () const noexcept |
| | Stream language tag copied from File metadata.
|
| |
| const std::optional< std::string > & | Title () const noexcept |
| | Stream title tag copied from File metadata.
|
| |
|
| const std::optional< std::uint64_t > & | Serial () const noexcept |
| | Monotonic lineage id assigned when the unit enters the pipe.
|
| |
| std::uint64_t | Part () const noexcept |
| | Sub-id inside Serial when one demuxed unit yields several frames.
|
| |
|
| const std::optional< Property::Video > & | Video () const noexcept |
| | Video properties (includes HDR10 when set).
|
| |
| const std::optional< Property::Audio > & | Audio () const noexcept |
| | Audio properties (layout, rate, channels).
|
| |
| const std::vector< class SideData > & | Attachments () const noexcept |
| | Raw side data captured at receive.
|
| |
|
| StormByte::Buffer::FIFO & | Payload () noexcept |
| | Payload.
|
| |
| const StormByte::Buffer::FIFO & | Payload () const noexcept |
| | Payload already materialised, or empty.
|
| |
| Kind | Kind () const noexcept |
| | Whether this unit is a frame or a packet.
|
| |
| enum StormByte::Multimedia::Type | Type () const noexcept |
| | Media of this access unit.
|
| |
| int | Track () const noexcept |
| | Origin track index.
|
| |
| enum Producer | Producer () const noexcept |
| | Stage that created this unit.
|
| |
| virtual | ~Item () noexcept=default |
| | Destructor.
|
| |
|
| | Frame () noexcept |
| | Empty frame.
|
| |
| | Frame (int track, enum StormByte::Multimedia::Type type, enum Producer producer, StormByte::Buffer::FIFO payload, std::optional< Property::Duration > pts, std::optional< Property::Duration > duration, std::optional< Property::Video > video, std::vector< class SideData > attachments, std::optional< Property::Audio > audio, std::uint64_t serial, std::uint64_t part) noexcept |
| | Builds a frame without a backend buffer.
|
| |
| | Frame (Frame &&other) noexcept |
| | Move constructor.
|
| |
| | ~Frame () noexcept override |
| | Destructor.
|
| |
| Frame & | operator= (Frame &&other) noexcept |
| | Move assignment.
|
| |
|
| | Item (const Item &other) noexcept=default |
| | Copy constructor.
|
| |
| | Item (Item &&other) noexcept=default |
| | Move constructor.
|
| |
| Item & | operator= (const Item &other) noexcept=default |
| | Copy assignment.
|
| |
| Item & | operator= (Item &&other) noexcept=default |
| | Move assignment.
|
| |
One decoded access unit.
In libav that is an AVFrame: one picture or one block of samples after decode. In Multimedia it is what process and analytics filters, and Encoder, see — pixels or samples, timestamps and the stream tags the decoder copied across.
- See also
- Item
-
Packet
◆ PointerType
◆ Frame() [1/3]
◆ Frame() [2/3]
| StormByte::Multimedia::Pipeline::Frame::Frame |
( |
int |
track, |
|
|
enum StormByte::Multimedia::Type |
type, |
|
|
enum Producer |
producer, |
|
|
StormByte::Buffer::FIFO |
payload, |
|
|
std::optional< Property::Duration > |
pts, |
|
|
std::optional< Property::Duration > |
duration, |
|
|
std::optional< Property::Video > |
video, |
|
|
std::vector< class SideData > |
attachments, |
|
|
std::optional< Property::Audio > |
audio, |
|
|
std::uint64_t |
serial, |
|
|
std::uint64_t |
part |
|
) |
| |
|
noexcept |
Builds a frame without a backend buffer.
- Parameters
-
| track | Origin container stream index. |
| type | Media of this unit (Video, Audio or Subtitle). |
| producer | Step that created this unit. |
| payload | Owned sample / plane bytes. |
| pts | Presentation timestamp, if known. |
| duration | Frame duration, if known. |
| video | Video properties, if this is a video frame. |
| attachments | Raw side-data blobs. |
| audio | Audio properties, if this is an audio frame. |
| serial | Lineage id born at the demuxer for this origin track. |
| part | Sub-id inside serial. Zero when the demuxed unit did not split. |
Dts starts empty. Decoder stamps it from the packet that produced this frame. There is no public setter.
◆ Frame() [3/3]
Move constructor.
- Parameters
-
Container-safe: other becomes the empty sentinel (Item::Type Unknown, track -1, no backend). ~Frame on a moved-from object is a no-op. Copy stays private.
◆ ~Frame()
| StormByte::Multimedia::Pipeline::Frame::~Frame |
( |
| ) |
|
|
overridenoexcept |
◆ Attachments()
| const std::vector< class SideData > & StormByte::Multimedia::Pipeline::Frame::Attachments |
( |
| ) |
const |
|
inlinenoexcept |
Raw side data captured at receive.
Read-only.
- Returns
- Blobs. MDM/CLL also appear in Video() HDR10 when the decoder could map them.
◆ Audio()
| const std::optional< Property::Audio > & StormByte::Multimedia::Pipeline::Frame::Audio |
( |
| ) |
const |
|
inlinenoexcept |
Audio properties (layout, rate, channels).
- Returns
- Audio, or empty.
◆ Dts()
| const std::optional< Property::Duration > & StormByte::Multimedia::Pipeline::Frame::Dts |
( |
| ) |
const |
|
inlinenoexcept |
Decode timestamp on the stream clock.
Copied by Decoder from the compressed packet that produced this frame. Empty when that packet had no Dts, or when the unit was not stamped. There is no public setter; friendship writes m_dts.
- Returns
- Dts, or empty.
◆ Duration()
| const std::optional< Property::Duration > & StormByte::Multimedia::Pipeline::Frame::Duration |
( |
| ) |
const |
|
inlinenoexcept |
Frame duration on the stream clock.
- Returns
- Duration, or empty.
◆ Language()
| const std::optional< std::string > & StormByte::Multimedia::Pipeline::Frame::Language |
( |
| ) |
const |
|
inlinenoexcept |
Stream language tag copied from File metadata.
- Returns
- Language, or empty if the stream had none.
◆ operator=()
| Frame & StormByte::Multimedia::Pipeline::Frame::operator= |
( |
Frame && |
other | ) |
|
|
noexcept |
Move assignment.
- Parameters
-
- Returns
- *this.
Same as the move constructor: other is left empty.
◆ Part()
| std::uint64_t StormByte::Multimedia::Pipeline::Frame::Part |
( |
| ) |
const |
|
inlinenoexcept |
Sub-id inside Serial when one demuxed unit yields several frames.
- Returns
- Zero when the unit did not split; 0, 1, … after a split.
Downstream stages copy this value. It is not a pipe-wide counter.
◆ Payload() [1/2]
| const StormByte::Buffer::FIFO & StormByte::Multimedia::Pipeline::Frame::Payload |
( |
| ) |
const |
|
inlinenoexcept |
Payload already materialised, or empty.
- Returns
- FIFO. Does not pull planes out of the backend.
◆ Payload() [2/2]
| StormByte::Buffer::FIFO & StormByte::Multimedia::Pipeline::Frame::Payload |
( |
| ) |
|
|
noexcept |
Payload.
Materialises planes on first call if a backend frame is held.
- Returns
- FIFO.
After materialisation the backend stays alive; a later filter Save replaces it and this FIFO is cleared.
◆ Pts()
| const std::optional< Property::Duration > & StormByte::Multimedia::Pipeline::Frame::Pts |
( |
| ) |
const |
|
inlinenoexcept |
Presentation timestamp on the stream clock.
- Returns
- Pts, or empty.
◆ Serial()
| const std::optional< std::uint64_t > & StormByte::Multimedia::Pipeline::Frame::Serial |
( |
| ) |
const |
|
inlinenoexcept |
Monotonic lineage id assigned when the unit enters the pipe.
- Returns
- Serial born at the demuxer for this origin track; empty on the sentinel.
This is not a decoded-frame count and not an FFmpeg nb_frames / nb_read_frames figure. It identifies one demuxed access unit as it travels Demuxer → … → Muxer. Downstream stages copy it. Part distinguishes several frames born from the same serial.
◆ Title()
| const std::optional< std::string > & StormByte::Multimedia::Pipeline::Frame::Title |
( |
| ) |
const |
|
inlinenoexcept |
Stream title tag copied from File metadata.
- Returns
- Title, or empty if the stream had none.
◆ Video()
| const std::optional< Property::Video > & StormByte::Multimedia::Pipeline::Frame::Video |
( |
| ) |
const |
|
inlinenoexcept |
Video properties (includes HDR10 when set).
- Returns
- Video, or empty.
◆ Backend::Pipeline::Frame
| friend class Backend::Pipeline::Frame |
|
friend |
◆ Decoder
◆ Encoder
◆ Filter::FFmpeg
◆ operator>> [1/2]
◆ operator>> [2/2]
The documentation for this class was generated from the following file:
- lib/public/StormByte/multimedia/pipeline/frame.hxx