Zrythm v2.0.0-alpha.1
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
zrythm::structure::arrangement::AudioSourceObject Class Referencefinal

Audio source for an AudioClip. More...

#include <src/structure/arrangement/audio_source_object.h>

Inheritance diagram for zrythm::structure::arrangement::AudioSourceObject:
Collaboration diagram for zrythm::structure::arrangement::AudioSourceObject:

Public Member Functions

 AudioSourceObject (const dsp::TempoMapWrapper &tempo_map_wrapper, utils::IObjectRegistry &registry, dsp::FileAudioSourceUuidReference source, QObject *parent=nullptr)
 Construct a new Audio Source Object object.
dsp::ContentPositionposition () const override
juce::PositionableAudioSource & get_audio_source () const
dsp::FileAudioSourcefile_audio_source () const
 Returns the underlying FileAudioSource.
dsp::FileAudioSourceUuidReference audio_source_ref () const
Public Member Functions inherited from zrythm::structure::arrangement::ArrangerObject
auto type () const
dsp::ContentPositionlength () const
ArrangerObjectNamename () const
ArrangerObjectColorcolor () const
ArrangerObjectMuteFunctionalitymute () const
Q_SIGNAL void propertiesChanged ()
 Emitted when any of the properties of the object changed.
ArrangerObjectparentObject () const
void setParentObject (ArrangerObject *object)
Q_SIGNAL void parentObjectChanged (QObject *parentObject)
const dsp::TempoMap & get_tempo_map () const
const dsp::TempoMapWrapperget_tempo_map_wrapper () const
virtual std::vector< ArrangerObjectListModel * > get_child_list_models () const
Public Member Functions inherited from zrythm::utils::UuidIdentifiableObject< ArrangerObject >
 UuidIdentifiableObject (QObject *parent=nullptr)
auto get_uuid () const
Public Member Functions inherited from zrythm::utils::UuidIdentifiableBase
 UuidIdentifiableBase (QObject *parent=nullptr)
 UuidIdentifiableBase (const QUuid &id, QObject *parent=nullptr)
QUuid raw_uuid () const

Friends

void init_from (AudioSourceObject &obj, const AudioSourceObject &other, utils::ObjectCloneType clone_type)
void to_json (nlohmann::json &j, const AudioSourceObject &obj)
void from_json (const nlohmann::json &j, AudioSourceObject &obj)

Additional Inherited Members

Public Types inherited from zrythm::structure::arrangement::ArrangerObject
enum class  Type : std::uint8_t {
  MidiClip , AudioClip , ChordClip , AutomationClip ,
  MidiControlEvent , MidiNote , ChordObject , ScaleObject ,
  Marker , AutomationPoint , AudioSourceObject , TempoObject ,
  TimeSignatureObject
}
 The type of the object. More...
Public Types inherited from zrythm::utils::UuidIdentifiableObject< ArrangerObject >
using uuid_base_type
 Exposes the CRTP parameter for concept checking.
Protected Types inherited from zrythm::structure::arrangement::ArrangerObject
enum class  ArrangerObjectFeatures : std::uint8_t {
  Bounds = 1 << 0 , Name = 1 << 1 , Color = 1 << 2 , Mute = 1 << 3 ,
  ClipOwned = 1 << 4
}
Protected Member Functions inherited from zrythm::structure::arrangement::ArrangerObject
 ArrangerObject (Type type, const dsp::TempoMapWrapper &tempo_map_wrapper, ArrangerObjectFeatures features, QObject *parent=nullptr) noexcept
 Construct a new ArrangerObject.
Protected Member Functions inherited from zrythm::utils::UuidIdentifiableBase
void set_raw_uuid (const QUuid &id)
Properties inherited from zrythm::structure::arrangement::ArrangerObject
QML_ELEMENT zrythm::structure::arrangement::ArrangerObjectparentObject
zrythm::structure::arrangement::ArrangerObject::Type type
zrythm::dsp::Positionposition
zrythm::dsp::ContentPositionlength
zrythm::structure::arrangement::ArrangerObjectNamename
zrythm::structure::arrangement::ArrangerObjectColorcolor
zrythm::structure::arrangement::ArrangerObjectMuteFunctionalitymute

Detailed Description

Audio source for an AudioClip.

This is a separate class so that clip linking can later be implemented more easily via a delegate to ArrangerObjectOwner (since audio clip is now also an ArrangerObjectOwner).

Definition at line 22 of file audio_source_object.h.

Constructor & Destructor Documentation

◆ AudioSourceObject()

zrythm::structure::arrangement::AudioSourceObject::AudioSourceObject ( const dsp::TempoMapWrapper & tempo_map_wrapper,
utils::IObjectRegistry & registry,
dsp::FileAudioSourceUuidReference source,
QObject * parent = nullptr )

Construct a new Audio Source Object object.

When constructing for deserialization, source can be a dummy source (from_json will generate the correct one).

Parameters
registry
source
tempo_map
parent

Member Function Documentation

◆ file_audio_source()

dsp::FileAudioSource & zrythm::structure::arrangement::AudioSourceObject::file_audio_source ( ) const

Returns the underlying FileAudioSource.

Carries the raw samples and the clip's permanent source BPM, which the clip needs to compute its musical length and stretch ratios.

◆ position()

dsp::ContentPosition * zrythm::structure::arrangement::AudioSourceObject::position ( ) const
inlineoverridevirtual

Reimplemented from zrythm::structure::arrangement::ArrangerObject.

Definition at line 48 of file audio_source_object.h.


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