Zrythm v2.0.0-DEV
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
zrythm::engine::session::Metronome Class Referencefinal

Metronome settings. More...

#include <src/engine/session/metronome.h>

Public Types

enum class  Type { None , Emphasis , Normal }
 The type of the metronome sound. More...
using SampleBufferPtr = std::shared_ptr<zrythm::utils::audio::AudioBuffer>

Public Member Functions

 Metronome (device_io::AudioEngine &engine)
 Initializes the Metronome by loading the samples into memory.
void set_volume (float volume)
void queue_events (device_io::AudioEngine *engine, nframes_t loffset, nframes_t nframes)
 Queues metronome events (if any) within the current processing cycle.

Data Fields

fs::path emphasis_path_
 Absolute path of the "emphasis" sample.
fs::path normal_path_
 Absolute path of the "normal" sample.
SampleBufferPtr emphasis_
 The emphasis sample.
SampleBufferPtr normal_
 The normal sample.
float volume_ {}

Detailed Description

Metronome settings.

Definition at line 24 of file metronome.h.

Member Typedef Documentation

◆ SampleBufferPtr

using zrythm::engine::session::Metronome::SampleBufferPtr = std::shared_ptr<zrythm::utils::audio::AudioBuffer>

Definition at line 46 of file metronome.h.

Member Enumeration Documentation

◆ Type

The type of the metronome sound.

Definition at line 30 of file metronome.h.

Constructor & Destructor Documentation

◆ Metronome()

zrythm::engine::session::Metronome::Metronome ( device_io::AudioEngine & engine)

Initializes the Metronome by loading the samples into memory.

Exceptions
ZrythmExceptionif loading fails.

Member Function Documentation

◆ queue_events()

void zrythm::engine::session::Metronome::queue_events ( device_io::AudioEngine * engine,
nframes_t loffset,
nframes_t nframes )

Queues metronome events (if any) within the current processing cycle.

Parameters
loffsetLocal offset in this cycle.

Field Documentation

◆ emphasis_

SampleBufferPtr zrythm::engine::session::Metronome::emphasis_

The emphasis sample.

Definition at line 68 of file metronome.h.

◆ emphasis_path_

fs::path zrythm::engine::session::Metronome::emphasis_path_

Absolute path of the "emphasis" sample.

Definition at line 62 of file metronome.h.

◆ normal_

SampleBufferPtr zrythm::engine::session::Metronome::normal_

The normal sample.

Definition at line 71 of file metronome.h.

◆ normal_path_

fs::path zrythm::engine::session::Metronome::normal_path_

Absolute path of the "normal" sample.

Definition at line 65 of file metronome.h.

◆ volume_

float zrythm::engine::session::Metronome::volume_ {}

Definition at line 73 of file metronome.h.


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