StormByte-Multimedia 3.3.2
C++26 multimedia processing module of the StormByte suite
Loading...
Searching...
No Matches
StormByte::Multimedia::Pipeline::Track Class Reference

One source stream that enters the tube. More...

#include <StormByte/multimedia/pipeline/track.hxx>

Inheritance diagram for StormByte::Multimedia::Pipeline::Track:
Collaboration diagram for StormByte::Multimedia::Pipeline::Track:

Public Member Functions

PointerType Clone () const override
 Deep copy.
PointerType Move () override
 Move into a new pointer.
Lifecycle
 Track (int in, enum StormByte::Multimedia::Type type) noexcept
 Track without a config leaf.
 Track (int in, const Config::Base &config)
 Builds a track; clones config and copies its type.
 Track (int in, Config::Base &&config)
 Builds a track; moves config and copies its type.
 Track (const Track &other)
 Copy constructor.
 Track (Track &&other) noexcept
 Move constructor.
virtual ~Track () noexcept override
 Destructor.
Track & operator= (const Track &other)
 Copy assignment.
Track & operator= (Track &&other) noexcept
 Move assignment.
Intention
enum StormByte::Multimedia::Type Type () const noexcept
 Media stamped at construction.
int In () const noexcept
 Origin stream index.
const Config::Base * Config () const noexcept
 Track config leaf, if any.
Public Member Functions inherited from StormByte::Safe::Clonable< Track, StormByte::Safe::Shared< Track > >
constexpr Clonable ()=default
constexpr Clonable & operator= (const Clonable &)=default
virtual constexpr ~Clonable () noexcept=default

Additional Inherited Members

Public Types inherited from StormByte::Safe::Clonable< Track, StormByte::Safe::Shared< Track > >
typedef SmartPointer PointerType
Static Public Member Functions inherited from StormByte::Safe::Clonable< Track, StormByte::Safe::Shared< Track > >
static PointerType MakePointer (Args &&... args)

Detailed Description

One source stream that enters the tube.

Intention only. Does not check that In exists on the origin File, nor that Type matches that stream. Consumers of Plan validate.

Mux slot is the index of this track in Tracks, not a field. Type is always stored. When a config is passed, Type is copied from the leaf. A null Config is an attachment (or no leaf). A non-null config with codec nullptr means Remux.

Constructor & Destructor Documentation

◆ Track() [1/5]

StormByte::Multimedia::Pipeline::Track::Track ( int in,
enum StormByte::Multimedia::Type type )
noexcept

Track without a config leaf.

Parameters
inOrigin stream index.
typeMedia type (typically StormByte::Multimedia::Type::Attachment).

◆ Track() [2/5]

StormByte::Multimedia::Pipeline::Track::Track ( int in,
const Config::Base & config )

Builds a track; clones config and copies its type.

Parameters
inOrigin stream index.
configLeaf config.
Note
Provider clone allocation failures propagate to the caller.

◆ Track() [3/5]

StormByte::Multimedia::Pipeline::Track::Track ( int in,
Config::Base && config )

Builds a track; moves config and copies its type.

Parameters
inOrigin stream index.
configLeaf config.
Note
Provider move allocation failures propagate to the caller.

◆ Track() [4/5]

StormByte::Multimedia::Pipeline::Track::Track ( const Track & other)

Copy constructor.

Deep-copies Config if present.

Parameters
otherSource track.

◆ Track() [5/5]

StormByte::Multimedia::Pipeline::Track::Track ( Track && other)
noexcept

Move constructor.

Parameters
otherTrack to take.

◆ ~Track()

virtual StormByte::Multimedia::Pipeline::Track::~Track ( )
overridevirtualnoexcept

Destructor.

Member Function Documentation

◆ Clone()

PointerType StormByte::Multimedia::Pipeline::Track::Clone ( ) const
overridevirtual

Deep copy.

Returns
Owning pointer to a new Track.
Note
Derived tracks must override in their provider module and construct Shared<Track>::MakePointer<Derived> without slicing.

Implements StormByte::Safe::Clonable< Track, StormByte::Safe::Shared< Track > >.

◆ Config()

const Config::Base * StormByte::Multimedia::Pipeline::Track::Config ( ) const
inlinenoexcept

Track config leaf, if any.

Returns
Leaf, or nullptr for attachments / no config.

◆ In()

int StormByte::Multimedia::Pipeline::Track::In ( ) const
inlinenoexcept

Origin stream index.

Returns
Index in the Plan source File.

◆ Move()

PointerType StormByte::Multimedia::Pipeline::Track::Move ( )
overridevirtual

Move into a new pointer.

Returns
Owning pointer to the moved Track.
Note
Derived tracks must override in their provider module and retain the exact payload's creator-module destructor.

Implements StormByte::Safe::Clonable< Track, StormByte::Safe::Shared< Track > >.

◆ operator=() [1/2]

Track & StormByte::Multimedia::Pipeline::Track::operator= ( const Track & other)

Copy assignment.

Deep-copies Config if present.

Parameters
otherSource track.
Returns
*this.

◆ operator=() [2/2]

Track & StormByte::Multimedia::Pipeline::Track::operator= ( Track && other)
noexcept

Move assignment.

Parameters
otherTrack to take.
Returns
*this.

◆ Type()

enum StormByte::Multimedia::Type StormByte::Multimedia::Pipeline::Track::Type ( ) const
inlinenoexcept

Media stamped at construction.

Returns
Type from the no-config ctor or from the leaf.

The documentation for this class was generated from the following file:
  • lib/public/StormByte/multimedia/pipeline/track.hxx