scenepic 1.1.0
3D Visualization Made Easy
Public Member Functions | Friends | List of all members
scenepic::AudioTrack Class Reference

Audio track that can be connected to a canvas. More...

#include <audio_track.h>

Public Member Functions

void load (const std::string &path)
 Load an audio file from the disk. More...
 
std::string to_string () const
 Return a JSON string representing the object. More...
 
JsonValue to_json () const
 Convert this object into ScenePic json. More...
 
const std::string & audio_id () const
 A unique identifier for the audio. More...
 
const std::vector< std::uint8_t > & data () const
 The encoded binary audio data. More...
 
std::vector< std::uint8_t > & data ()
 The encoded binary audio data. More...
 
AudioTrackdata (const std::vector< std::uint8_t > &value)
 The encoded binary audio data. More...
 
const std::string & ext () const
 The extension of the audio track (e.g. More...
 
AudioTrackext (const std::string &value)
 The extension of the audio track (e.g. More...
 

Friends

class Scene
 

Detailed Description

Audio track that can be connected to a canvas.

Member Function Documentation

◆ audio_id()

const std::string & scenepic::AudioTrack::audio_id ( ) const

A unique identifier for the audio.

◆ data() [1/3]

std::vector< std::uint8_t > & scenepic::AudioTrack::data ( )

The encoded binary audio data.

◆ data() [2/3]

const std::vector< std::uint8_t > & scenepic::AudioTrack::data ( ) const

The encoded binary audio data.

◆ data() [3/3]

AudioTrack & scenepic::AudioTrack::data ( const std::vector< std::uint8_t > &  value)

The encoded binary audio data.

◆ ext() [1/2]

const std::string & scenepic::AudioTrack::ext ( ) const

The extension of the audio track (e.g.

MP3, OGG)

◆ ext() [2/2]

AudioTrack & scenepic::AudioTrack::ext ( const std::string &  value)

The extension of the audio track (e.g.

MP3, OGG)

◆ load()

void scenepic::AudioTrack::load ( const std::string &  path)

Load an audio file from the disk.

Parameters
paththe path to the audio file

◆ to_json()

JsonValue scenepic::AudioTrack::to_json ( ) const

Convert this object into ScenePic json.

Returns
a json value

◆ to_string()

std::string scenepic::AudioTrack::to_string ( ) const

Return a JSON string representing the object.

Friends And Related Function Documentation

◆ Scene

friend class Scene
friend

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