Deluge Firmware
Loading...
Searching...
No Matches
voicesampleplaybackguide.h
Go to the documentation of this file.
1/*
2 * Copyright © 2017-2023 Synthstrom Audible Limited
3 *
4 * This file is part of The Synthstrom Audible Deluge Firmware.
5 *
6 * The Synthstrom Audible Deluge Firmware is free software: you can redistribute it and/or modify it under the
7 * terms of the GNU General Public License as published by the Free Software Foundation,
8 * either version 3 of the License, or (at your option) any later version.
9 *
10 * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY;
11 * without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
12 * See the GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License along with this program.
15 * If not, see <https://www.gnu.org/licenses/>.
16 */
17
18#ifndef VOICE_SOURCE_H
19#define VOICE_SOURCE_H
20
21#include "definitions.h"
22#include "SamplePlaybackGuide.h"
23
24class Source;
25class Sample;
26class Voice;
27class SampleCache;
28
30public:
32 void setupPlaybackBounds(bool reversed);
34 int32_t getBytePosToStartPlayback(bool justLooped);
36 int getLoopingType(Source* source);
37
40
41 uint32_t loopStartPlaybackAtByte; // If no loop-start point defined, this will be the same as startPlaybackAtByte, so it can just be referred to when looping happens
42 uint32_t loopEndPlaybackAtByte; // 0 means disabled
43
45};
46
47#endif
Definition: SampleCache.h:27
Definition: Sample.h:49
Definition: SamplePlaybackGuide.h:28
uint32_t endPlaybackAtByte
Definition: SamplePlaybackGuide.h:51
Definition: source.h:31
Definition: voice.h:33
Definition: voicesampleplaybackguide.h:29
uint32_t loopStartPlaybackAtByte
Definition: voicesampleplaybackguide.h:41
bool shouldObeyLoopEndPointNow()
Definition: voicesampleplaybackguide.cpp:68
int32_t getBytePosToEndOrLoopPlayback()
Definition: voicesampleplaybackguide.cpp:80
uint32_t loopEndPlaybackAtByte
Definition: voicesampleplaybackguide.h:42
void setupPlaybackBounds(bool reversed)
Definition: voicesampleplaybackguide.cpp:30
uint32_t getLoopEndPlaybackAtByte()
Definition: voicesampleplaybackguide.h:39
uint32_t getLoopStartPlaybackAtByte()
Definition: voicesampleplaybackguide.h:38
VoiceSamplePlaybackGuide()
Definition: voicesampleplaybackguide.cpp:26
int getLoopingType(Source *source)
Definition: voicesampleplaybackguide.cpp:86
bool noteOffReceived
Definition: voicesampleplaybackguide.h:44
int32_t getBytePosToStartPlayback(bool justLooped)
Definition: voicesampleplaybackguide.cpp:74