Zrythm v2.0.0-DEV
a highly automated and intuitive digital audio workstation
Loading...
Searching...
No Matches
zrythm::dsp::TimelineDataCache Class Referenceabstract

Base class for timeline data caches. More...

#include <src/dsp/timeline_data_cache.h>

Inheritance diagram for zrythm::dsp::TimelineDataCache:

Public Types

using IntervalType = std::pair<units::sample_t, units::sample_t>

Public Member Functions

virtual void clear ()=0
 Clears all cached data.
virtual void remove_sequences_matching_interval (IntervalType interval)=0
 Removes cached data matching the given interval.
virtual void finalize_changes ()=0
 Finalizes changes and prepares cached data for access.
virtual bool has_content () const =0
 Checks if the cache has any content.

Detailed Description

Base class for timeline data caches.

Provides common functionality for all timeline data cache types. This is an abstract base class that defines the interface that all derived cache classes must implement.

Definition at line 21 of file timeline_data_cache.h.

Member Typedef Documentation

◆ IntervalType

using zrythm::dsp::TimelineDataCache::IntervalType = std::pair<units::sample_t, units::sample_t>

Definition at line 24 of file timeline_data_cache.h.

Member Function Documentation

◆ clear()

virtual void zrythm::dsp::TimelineDataCache::clear ( )
pure virtual

◆ finalize_changes()

virtual void zrythm::dsp::TimelineDataCache::finalize_changes ( )
pure virtual

Finalizes changes and prepares cached data for access.

This should be called after all modifications are complete to prepare the cached data for real-time access.

Implemented in zrythm::dsp::AudioTimelineDataCache, zrythm::dsp::AutomationTimelineDataCache, and zrythm::dsp::MidiTimelineDataCache.

◆ has_content()

virtual bool zrythm::dsp::TimelineDataCache::has_content ( ) const
pure virtual

Checks if the cache has any content.

Returns
True if the cache contains any data, false otherwise.

Implemented in zrythm::dsp::AudioTimelineDataCache, zrythm::dsp::AutomationTimelineDataCache, and zrythm::dsp::MidiTimelineDataCache.

◆ remove_sequences_matching_interval()

virtual void zrythm::dsp::TimelineDataCache::remove_sequences_matching_interval ( IntervalType interval)
pure virtual

Removes cached data matching the given interval.

Parameters
intervalThe time interval to remove (in samples).

Implemented in zrythm::dsp::AudioTimelineDataCache, zrythm::dsp::AutomationTimelineDataCache, and zrythm::dsp::MidiTimelineDataCache.


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