hydrogen 1.2.6
Song.h
Go to the documentation of this file.
1/*
2 * Hydrogen
3 * Copyright(c) 2002-2008 by Alex >Comix< Cominu [comix@users.sourceforge.net]
4 * Copyright(c) 2008-2025 The hydrogen development team [hydrogen-devel@lists.sourceforge.net]
5 *
6 * http://www.hydrogen-music.org
7 *
8 * This program is free software; you can redistribute it and/or modify
9 * it under the terms of the GNU General Public License as published by
10 * the Free Software Foundation; either version 2 of the License, or
11 * (at your option) any later version.
12 *
13 * This program is distributed in the hope that it will be useful,
14 * but WITHOUT ANY WARRANTY, without even the implied warranty of
15 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
16 * GNU General Public License for more details.
17 *
18 * You should have received a copy of the GNU General Public License
19 * along with this program. If not, see https://www.gnu.org/licenses
20 *
21 */
22
23#ifndef SONG_H
24#define SONG_H
25
26
27#include <QString>
28#include <QDomNode>
29#include <vector>
30#include <map>
31#include <memory>
32
33#include <core/License.h>
34#include <core/Object.h>
36#include <core/Helpers/Xml.h>
37
38class TiXmlNode;
39
40namespace H2Core
41{
42
43class ADSR;
44class Sample;
45class Note;
46class Instrument;
47class InstrumentList;
48class Pattern;
49class Drumkit;
51class PatternList;
52class AutomationPath;
53class Timeline;
54
60class Song : public H2Core::Object<Song>, public std::enable_shared_from_this<Song>
61{
63 public:
64 enum class Mode {
66 Song = 1,
69 None = 2
70 };
71
74 enum class ActionMode {
83 None = 2
84 };
85
86 enum class LoopMode {
95 };
96
101 enum class PatternMode {
111 };
112
115 enum class PlaybackTrack {
119 Muted = 1,
125 };
126
127 Song( const QString& sName, const QString& sAuthor, float fBpm, float fVolume );
128 ~Song();
129
130 static std::shared_ptr<Song> getEmptySong();
131
132 static std::shared_ptr<Song> load( const QString& sFilename, bool bSilent = false );
133 bool save( const QString& sFilename, bool bSilent = false );
134
135 static constexpr int nDefaultResolution = 48;
136 bool getIsTimelineActivated() const;
137 void setIsTimelineActivated( bool bIsTimelineActivated );
138
139 bool getIsPatternEditorLocked() const;
140 void setIsPatternEditorLocked( bool bIsPatternEditorLocked );
141
142 bool getIsMuted() const;
143 void setIsMuted( bool bIsMuted );
144
145 unsigned getResolution() const;
146 void setResolution( unsigned resolution );
147
148 float getBpm() const;
149 void setBpm( float fBpm );
150
151 const QString& getName() const;
152 void setName( const QString& sName );
153
154 void setVolume( float fVolume );
155 float getVolume() const;
156
157 void setMetronomeVolume( float fVolume );
158 float getMetronomeVolume() const;
159
161 void setPatternList( PatternList* pList );
162
166 std::vector<PatternList*>* getPatternGroupVector();
170 const std::vector<PatternList*>* getPatternGroupVector() const;
171
176 void setPatternGroupVector( std::vector<PatternList*>* pGroupVect );
177
179 long lengthInTicks() const;
180
181 std::shared_ptr<InstrumentList> getInstrumentList() const;
182 void setInstrumentList( std::shared_ptr<InstrumentList> pList );
183
184 void setNotes( const QString& sNotes );
185 const QString& getNotes() const;
186
187 void setLicense( const License& license );
188 const License& getLicense() const;
189
190 void setAuthor( const QString& sAuthor );
191 const QString& getAuthor() const;
192
193 const QString& getFilename() const;
194 void setFilename( const QString& sFilename );
195
196 LoopMode getLoopMode() const;
197 void setLoopMode( LoopMode loopMode );
198 bool isLoopEnabled() const;
199
201 void setPatternMode( PatternMode patternMode );
202
203 float getHumanizeTimeValue() const;
204 void setHumanizeTimeValue( float fValue );
205
206 float getHumanizeVelocityValue() const;
207 void setHumanizeVelocityValue( float fValue );
208
209 float getSwingFactor() const;
210 void setSwingFactor( float fFactor );
211
212 Mode getMode() const;
213 void setMode( Mode mode );
214
215 bool getIsModified() const;
216 void setIsModified( bool bIsModified);
217
218 std::shared_ptr<std::vector<std::shared_ptr<DrumkitComponent>>> getComponents() const;
219
221
222 std::shared_ptr<DrumkitComponent> getComponent( int nID ) const;
223
224 void readTempPatternList( const QString& sFilename );
225 bool writeTempPatternList( const QString& sFilename );
226
227 QString copyInstrumentLineToString( int selectedInstrument );
228 bool pasteInstrumentLineFromString( const QString& sSerialized, int nSelectedInstrument, std::list<Pattern *>& patterns );
229
230 int getLatestRoundRobin( float fStartVelocity );
231 void setLatestRoundRobin( float fStartVelocity, int nLatestRoundRobin );
233 const QString& getPlaybackTrackFilename() const;
235 void setPlaybackTrackFilename( const QString sFilename );
236
238 bool getPlaybackTrackEnabled() const;
242 void setPlaybackTrackEnabled( const bool bEnabled );
243
245 float getPlaybackTrackVolume() const;
247 void setPlaybackTrackVolume( const float fVolume );
248
250
251
253 void setActionMode( const ActionMode actionMode );
254
257 bool hasMissingSamples() const;
258 void clearMissingSamples();
259
260 void setPanLawType( int nPanLawType );
261 int getPanLawType() const;
262 void setPanLawKNorm( float fKNorm );
263 float getPanLawKNorm() const;
264
265 bool isPatternActive( int nColumn, int nRow ) const;
266
267 std::shared_ptr<Timeline> getTimeline() const;
268
269 void setDrumkit( std::shared_ptr<Drumkit> pDrumkit, bool bConditional );
270 void removeInstrument( int nInstrumentNumber, bool bConditional );
271
272 std::vector<std::shared_ptr<Note>> getAllNotes() const;
273
279 int findExistingComponent( const QString& sComponentName ) const;
280 int findFreeComponentID( int nStartingID = 0 ) const;
283 QString makeComponentNameUnique( const QString& sComponentName ) const;
284
285
286 const QString& getLastLoadedDrumkitName() const;
287 void setLastLoadedDrumkitName( const QString& sName );
288 QString getLastLoadedDrumkitPath() const;
289 void setLastLoadedDrumkitPath( const QString& sPath );
290
299 QString toQString( const QString& sPrefix = "", bool bShort = true ) const override;
300
301private:
302
303 static std::shared_ptr<Song> loadFrom( XMLNode* pNode, const QString& sFilename, bool bSilent = false );
304 void writeTo( XMLNode* pNode, bool bSilent = false );
305
306 void loadVirtualPatternsFrom( XMLNode* pNode, bool bSilent = false );
307 void loadPatternGroupVectorFrom( XMLNode* pNode, bool bSilent = false );
308 void writeVirtualPatternsTo( XMLNode* pNode, bool bSilent = false );
309 void writePatternGroupVectorTo( XMLNode* pNode, bool bSilent = false );
310
314
317 unsigned m_resolution;
324 float m_fBpm;
325
327 QString m_sName;
329 QString m_sAuthor;
330
335 QString m_sNotes;
339 std::vector<PatternList*>* m_pPatternGroupSequence;
341 std::shared_ptr<InstrumentList> m_pInstrumentList;
343 std::shared_ptr<std::vector<std::shared_ptr<DrumkitComponent>>> m_pComponents;
344 QString m_sFilename;
345
370 std::map< float, int> m_latestRoundRobins;
372
403
406
417
419 // k such that L^k+R^k = 1. Used in constant k-Norm pan law
421
422 void setTimeline( std::shared_ptr<Timeline> pTimeline );
423 std::shared_ptr<Timeline> m_pTimeline;
424
443
444};
445
446inline bool Song::getIsTimelineActivated() const {
448}
449inline void Song::setIsTimelineActivated( bool bIsTimelineActivated ) {
450 m_bIsTimelineActivated = bIsTimelineActivated;
451}
454}
455inline void Song::setIsPatternEditorLocked( bool bIsPatternEditorLocked ) {
456 m_bIsPatternEditorLocked = bIsPatternEditorLocked;
457}
458inline std::shared_ptr<Timeline> Song::getTimeline() const {
459 return m_pTimeline;
460}
461inline void Song::setTimeline( std::shared_ptr<Timeline> pTimeline ) {
462 m_pTimeline = pTimeline;
463}
464
465inline bool Song::getIsMuted() const
466{
467 return m_bIsMuted;
468}
469
470inline void Song::setIsMuted( bool bIsMuted )
471{
472 m_bIsMuted = bIsMuted;
473}
474
475inline unsigned Song::getResolution() const
476{
477 return m_resolution;
478}
479
480inline void Song::setResolution( unsigned resolution )
481{
482 m_resolution = resolution;
483}
484
485inline float Song::getBpm() const
486{
487 return m_fBpm;
488}
489
490inline void Song::setName( const QString& sName )
491{
492 m_sName = sName;
493}
494
495inline const QString& Song::getName() const
496{
497 return m_sName;
498}
499
500inline float Song::getVolume() const
501{
502 return m_fVolume;
503}
504
505inline void Song::setVolume( float fValue )
506{
507 m_fVolume = fValue;
508}
509
510inline float Song::getMetronomeVolume() const
511{
512 return m_fMetronomeVolume;
513}
514
515inline void Song::setMetronomeVolume( float fValue )
516{
517 m_fMetronomeVolume = fValue;
518}
519
520inline bool Song::getIsModified() const
521{
522 return m_bIsModified;
523}
524
525inline std::shared_ptr<InstrumentList> Song::getInstrumentList() const
526{
527 return m_pInstrumentList;
528}
529
530inline void Song::setInstrumentList( std::shared_ptr<InstrumentList> pList )
531{
532 m_pInstrumentList = pList;
533}
534
536{
537 return m_pPatternList;
538}
539
541{
542 m_pPatternList = pList;
543}
544
545inline std::vector<PatternList*>* Song::getPatternGroupVector() {
547}
548
549inline const std::vector<PatternList*>* Song::getPatternGroupVector() const
550{
552}
553
554inline void Song::setPatternGroupVector( std::vector<PatternList*>* pGroupVector )
555{
556 m_pPatternGroupSequence = pGroupVector;
557}
558
559inline void Song::setNotes( const QString& sNotes )
560{
561 m_sNotes = sNotes;
562}
563
564inline const QString& Song::getNotes() const
565{
566 return m_sNotes;
567}
568
569inline void Song::setLicense( const License& license )
570{
571 m_license = license;
572}
573
574inline const License& Song::getLicense() const
575{
576 return m_license;
577}
578
579inline void Song::setAuthor( const QString& sAuthor )
580{
581 m_sAuthor = sAuthor;
582}
583
584inline const QString& Song::getAuthor() const
585{
586 return m_sAuthor;
587}
588
589inline const QString& Song::getFilename() const
590{
591 return m_sFilename;
592}
593
594inline void Song::setFilename( const QString& sFilename )
595{
596 m_sFilename = sFilename;
597}
598
599inline bool Song::isLoopEnabled() const
600{
601 return m_loopMode == LoopMode::Enabled ||
603}
604
606{
607 return m_loopMode;
608}
609inline void Song::setLoopMode( Song::LoopMode loopMode )
610{
611 m_loopMode = loopMode;
612}
613
615{
616 return m_patternMode;
617}
618inline void Song::setPatternMode( Song::PatternMode patternMode )
619{
620 m_patternMode = patternMode;
621}
622
623inline float Song::getHumanizeTimeValue() const
624{
626}
627
628inline void Song::setHumanizeTimeValue( float fValue )
629{
630 m_fHumanizeTimeValue = fValue;
631}
632
634{
636}
637
638inline void Song::setHumanizeVelocityValue( float fValue )
639{
641}
642
643inline float Song::getSwingFactor() const
644{
645 return m_fSwingFactor;
646}
647
649{
650 return m_mode;
651}
652
653inline void Song::setMode( Song::Mode mode )
654{
655 m_mode = mode;
656}
657
658inline std::shared_ptr<std::vector<std::shared_ptr<DrumkitComponent>>> Song::getComponents() const
659{
660 return m_pComponents;
661}
662
667
668inline int Song::getLatestRoundRobin( float fStartVelocity )
669{
670 if ( m_latestRoundRobins.find( fStartVelocity ) == m_latestRoundRobins.end() ) {
671 return 0;
672 } else {
673 return m_latestRoundRobins[ fStartVelocity ];
674 }
675}
676
677inline void Song::setLatestRoundRobin( float fStartVelocity, int nLatestRoundRobin )
678{
679 m_latestRoundRobins[ fStartVelocity ] = nLatestRoundRobin;
680}
681
682inline const QString& Song::getPlaybackTrackFilename() const
683{
685}
686
687inline void Song::setPlaybackTrackFilename( const QString sFilename )
688{
689 m_sPlaybackTrackFilename = sFilename;
690}
691
693{
695}
696
697inline void Song::setPlaybackTrackEnabled( const bool bEnabled )
698{
699 m_bPlaybackTrackEnabled = bEnabled;
700}
701
703{
705}
706
707inline void Song::setPlaybackTrackVolume( const float fVolume )
708{
709 m_fPlaybackTrackVolume = fVolume;
710}
712 if ( m_sPlaybackTrackFilename.isEmpty() ) {
714 }
715
716 if ( ! m_bPlaybackTrackEnabled ) {
718 }
719
721}
722
724 return m_actionMode;
725}
726
727inline void Song::setPanLawType( int nPanLawType ) {
728 m_nPanLawType = nPanLawType;
729}
730
731inline int Song::getPanLawType() const {
732 return m_nPanLawType;
733}
734
735inline float Song::getPanLawKNorm() const {
736 return m_fPanLawKNorm;
737}
738
739inline const QString& Song::getLastLoadedDrumkitName() const
740{
742}
743inline void Song::setLastLoadedDrumkitName( const QString& sName )
744{
746}
747inline void Song::setLastLoadedDrumkitPath( const QString& sPath )
748{
750}
751};
752
753#endif
#define H2_OBJECT(name)
Definition Object.h:227
Attack Decay Sustain Release envelope.
Definition Adsr.h:38
Drumkit info.
Definition Drumkit.h:45
InstrumentList is a collection of instruments used within a song, a drumkit, ...
Instrument class.
Definition Instrument.h:55
Wrapper class to help Hydrogen deal with the license information specified in a drumkit.
Definition License.h:48
A note plays an associated instrument with a velocity left and right pan.
Definition Note.h:101
PatternList is a collection of patterns.
Definition PatternList.h:43
Pattern class is a Note container.
Definition Pattern.h:46
void setPatternMode(PatternMode patternMode)
Definition Song.h:618
std::vector< PatternList * > * getPatternGroupVector()
Return a pointer to a vector storing all Pattern present in the Song.
Definition Song.h:545
bool m_bIsTimelineActivated
Whether the Timeline button was pressed in the GUI or it was activated via an OSC command.
Definition Song.h:313
void setPanLawKNorm(float fKNorm)
Definition Song.cpp:1254
bool getIsTimelineActivated() const
Definition Song.h:446
std::shared_ptr< Timeline > m_pTimeline
Definition Song.h:423
void loadVirtualPatternsFrom(XMLNode *pNode, bool bSilent=false)
Definition Song.cpp:655
std::shared_ptr< InstrumentList > getInstrumentList() const
Definition Song.h:525
PatternList * getPatternList() const
Definition Song.h:535
const QString & getNotes() const
Definition Song.h:564
int m_nPanLawType
Definition Song.h:418
void setPlaybackTrackVolume(const float fVolume)
Definition Song.h:707
bool getIsMuted() const
Definition Song.h:465
QString m_sName
author of the song
Definition Song.h:327
bool getIsPatternEditorLocked() const
Definition Song.h:452
QString m_sFilename
Definition Song.h:344
float getPlaybackTrackVolume() const
Definition Song.h:702
bool save(const QString &sFilename, bool bSilent=false)
Save a song to file.
Definition Song.cpp:611
Song(const QString &sName, const QString &sAuthor, float fBpm, float fVolume)
Definition Song.cpp:67
bool isLoopEnabled() const
Definition Song.h:599
void setPatternList(PatternList *pList)
Definition Song.h:540
const QString & getLastLoadedDrumkitName() const
Definition Song.h:739
void setDrumkit(std::shared_ptr< Drumkit > pDrumkit, bool bConditional)
Definition Song.cpp:1263
ActionMode m_actionMode
Stores the type of interaction with the SongEditor.
Definition Song.h:405
PatternList * m_pPatternList
Sequence of pattern groups.
Definition Song.h:337
const QString & getName() const
Definition Song.h:495
static constexpr int nDefaultResolution
Definition Song.h:135
std::map< float, int > m_latestRoundRobins
Definition Song.h:370
void setIsTimelineActivated(bool bIsTimelineActivated)
Definition Song.h:449
float m_fVolume
Metronome volume.
Definition Song.h:332
@ None
Used in case no song is set and both pattern and song editor are not ready to operate yet.
Definition Song.h:69
QString getLastLoadedDrumkitPath() const
Definition Song.cpp:1497
void setPlaybackTrackFilename(const QString sFilename)
Definition Song.h:687
void setMode(Mode mode)
Definition Song.h:653
bool writeTempPatternList(const QString &sFilename)
Definition Song.cpp:1118
QString m_sAuthor
volume of the song (0.0..1.0)
Definition Song.h:329
void setMetronomeVolume(float fVolume)
Definition Song.h:515
float getHumanizeVelocityValue() const
Definition Song.h:633
unsigned getResolution() const
Definition Song.h:475
ActionMode getActionMode() const
Definition Song.h:723
void readTempPatternList(const QString &sFilename)
Definition Song.cpp:1102
static std::shared_ptr< Song > load(const QString &sFilename, bool bSilent=false)
Load a song from file.
Definition Song.cpp:191
PlaybackTrack getPlaybackTrackState() const
Definition Song.h:711
void setIsPatternEditorLocked(bool bIsPatternEditorLocked)
Definition Song.h:455
bool hasMissingSamples() const
Song was incompletely loaded from file (missing samples)
Definition Song.cpp:1084
void setBpm(float fBpm)
Definition Song.cpp:132
void setResolution(unsigned resolution)
Definition Song.h:480
std::shared_ptr< std::vector< std::shared_ptr< DrumkitComponent > > > getComponents() const
Definition Song.h:658
long lengthInTicks() const
get the length of the song, in tick units
Definition Song.cpp:154
LoopMode m_loopMode
The three states of this enum is just a way to handle the playback within Hydrogen.
Definition Song.h:352
ActionMode
Defines the type of user interaction experienced in the SongEditor.
Definition Song.h:74
@ selectMode
Holding a pressed left mouse key will draw a rectangle to select a group of Notes.
Definition Song.h:77
@ drawMode
Holding a pressed left mouse key will draw/delete patterns in all grid cells encountered.
Definition Song.h:80
Mode getMode() const
Definition Song.h:648
@ Finishing
Transport is still in loop mode (frames and ticks larger than song size are allowed) but playback end...
Definition Song.h:94
float m_fBpm
Current speed in beats per minutes.
Definition Song.h:324
bool pasteInstrumentLineFromString(const QString &sSerialized, int nSelectedInstrument, std::list< Pattern * > &patterns)
Definition Song.cpp:1150
void setHumanizeTimeValue(float fValue)
Definition Song.h:628
void setLoopMode(LoopMode loopMode)
Definition Song.h:609
const QString & getFilename() const
Definition Song.h:589
PlaybackTrack
Determines the state of the Playback track with respect to audio processing.
Definition Song.h:115
@ Enabled
Valid file set and ready for playback.
Definition Song.h:121
@ Unavailable
No proper playback track file set yet.
Definition Song.h:117
@ Muted
Valid file set but the playback track is muted via the GUI.
Definition Song.h:119
bool isPatternActive(int nColumn, int nRow) const
Definition Song.cpp:170
std::shared_ptr< Timeline > getTimeline() const
Definition Song.h:458
std::shared_ptr< DrumkitComponent > getComponent(int nID) const
Definition Song.cpp:1037
float getBpm() const
Definition Song.h:485
void clearMissingSamples()
Definition Song.cpp:1095
void setVolume(float fVolume)
Definition Song.h:505
QString makeComponentNameUnique(const QString &sComponentName) const
Ensures sComponentName is not used by any other component loaded into the song yet.
Definition Song.cpp:1488
const QString & getAuthor() const
Definition Song.h:584
std::shared_ptr< InstrumentList > m_pInstrumentList
list of drumkit component
Definition Song.h:341
void writeTo(XMLNode *pNode, bool bSilent=false)
Definition Song.cpp:791
void writePatternGroupVectorTo(XMLNode *pNode, bool bSilent=false)
Definition Song.cpp:776
bool m_bIsModified
Definition Song.h:369
void removeInstrument(int nInstrumentNumber, bool bConditional)
Definition Song.cpp:1366
PatternMode getPatternMode() const
Definition Song.h:614
void setActionMode(const ActionMode actionMode)
Definition Song.cpp:150
float m_fPanLawKNorm
Definition Song.h:420
AutomationPath * m_pVelocityAutomationPath
license of the song
Definition Song.h:400
float getPanLawKNorm() const
Definition Song.h:735
void loadPatternGroupVectorFrom(XMLNode *pNode, bool bSilent=false)
Definition Song.cpp:707
QString m_sNotes
Pattern list.
Definition Song.h:335
float getHumanizeTimeValue() const
Definition Song.h:623
int findFreeComponentID(int nStartingID=0) const
Definition Song.cpp:1469
float getMetronomeVolume() const
Definition Song.h:510
void setFilename(const QString &sFilename)
Definition Song.h:594
License m_license
Definition Song.h:402
void setLastLoadedDrumkitPath(const QString &sPath)
Definition Song.h:747
void setSwingFactor(float fFactor)
Definition Song.cpp:1049
LoopMode getLoopMode() const
Definition Song.h:605
float m_fPlaybackTrackVolume
Volume of the playback track.
Definition Song.h:399
std::shared_ptr< std::vector< std::shared_ptr< DrumkitComponent > > > m_pComponents
Definition Song.h:343
void setPanLawType(int nPanLawType)
Definition Song.h:727
std::vector< PatternList * > * m_pPatternGroupSequence
Instrument list.
Definition Song.h:339
static std::shared_ptr< Song > getEmptySong()
Definition Song.cpp:964
void setLicense(const License &license)
Definition Song.h:569
void setNotes(const QString &sNotes)
Definition Song.h:559
void setLastLoadedDrumkitName(const QString &sName)
Definition Song.h:743
PatternMode m_patternMode
Definition Song.h:353
void setIsModified(bool bIsModified)
Definition Song.cpp:1060
float m_fSwingFactor
Definition Song.h:368
bool m_bIsMuted
Resolution of the song (number of ticks per quarter)
Definition Song.h:315
bool getPlaybackTrackEnabled() const
Definition Song.h:692
int getLatestRoundRobin(float fStartVelocity)
Definition Song.h:668
void setTimeline(std::shared_ptr< Timeline > pTimeline)
Definition Song.h:461
QString toQString(const QString &sPrefix="", bool bShort=true) const override
Formatted string version for debugging purposes.
Definition Song.cpp:1502
void setInstrumentList(std::shared_ptr< InstrumentList > pList)
Definition Song.h:530
bool m_bIsPatternEditorLocked
If set to true, the user won't be able to select a pattern via the SongEditor.
Definition Song.h:416
void setName(const QString &sName)
Definition Song.h:490
PatternMode
Determines how patterns will be added to AudioEngine::m_pPlayingPatterns if transport is in Song::Mod...
Definition Song.h:101
@ Stacked
An arbitrary number of pattern can be played.
Definition Song.h:103
@ Selected
Only one pattern - the one currently selected in the GUI - will be played back.
Definition Song.h:106
const License & getLicense() const
Definition Song.h:574
float m_fHumanizeVelocityValue
Factor to scale the random contribution when humanizing velocity between 0 and AudioEngine::fHumanize...
Definition Song.h:367
void setAuthor(const QString &sAuthor)
Definition Song.h:579
AutomationPath * getVelocityAutomationPath() const
Definition Song.h:663
float m_fHumanizeTimeValue
Factor to scale the random contribution when humanizing timing between 0 and AudioEngine::fHumanizeTi...
Definition Song.h:360
void setPlaybackTrackEnabled(const bool bEnabled)
Specifies whether a playback track should be used.
Definition Song.h:697
QString copyInstrumentLineToString(int selectedInstrument)
Definition Song.cpp:1129
QString m_sLastLoadedDrumkitName
Convenience variable holding the name of the drumkit last loaded.
Definition Song.h:442
void setLatestRoundRobin(float fStartVelocity, int nLatestRoundRobin)
Definition Song.h:677
Mode m_mode
Definition Song.h:371
unsigned m_resolution
Definition Song.h:317
bool getIsModified() const
Definition Song.h:520
float m_fMetronomeVolume
Definition Song.h:334
std::vector< std::shared_ptr< Note > > getAllNotes() const
Definition Song.cpp:1416
float getVolume() const
Definition Song.h:500
void writeVirtualPatternsTo(XMLNode *pNode, bool bSilent=false)
Definition Song.cpp:762
int getPanLawType() const
Definition Song.h:731
int findExistingComponent(const QString &sComponentName) const
Checks whether a component of name sComponentName exists in m_pComponents.
Definition Song.cpp:1460
static std::shared_ptr< Song > loadFrom(XMLNode *pNode, const QString &sFilename, bool bSilent=false)
Definition Song.cpp:233
QString m_sPlaybackTrackFilename
Name of the file to be loaded as playback track.
Definition Song.h:381
bool m_bPlaybackTrackEnabled
Whether the playback track should be used at all.
Definition Song.h:390
void setIsMuted(bool bIsMuted)
Definition Song.h:470
float getSwingFactor() const
Definition Song.h:643
void setHumanizeVelocityValue(float fValue)
Definition Song.h:638
void setPatternGroupVector(std::vector< PatternList * > *pGroupVect)
Sets the vector storing all Pattern present in the Song m_pPatternGroupSequence.
Definition Song.h:554
QString m_sLastLoadedDrumkitPath
Unique identifier of the drumkit last loaded.
Definition Song.h:439
const QString & getPlaybackTrackFilename() const
Definition Song.h:682
Timeline class storing and handling all TempoMarkers and Tags.
Definition Timeline.h:68
XMLNode is a subclass of QDomNode with read and write values methods.
Definition Xml.h:39