Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update develop with humdrum branch #3865

Merged
merged 12 commits into from
Nov 25, 2024
61 changes: 60 additions & 1 deletion include/hum/humlib.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//
// Programmer: Craig Stuart Sapp <[email protected]>
// Creation Date: Sat Aug 8 12:24:49 PDT 2015
// Last Modified: Sun Sep 8 23:07:16 PDT 2024
// Last Modified: Wed Nov 13 13:08:51 PST 2024
// Filename: min/humlib.h
// URL: https://github.com/craigsapp/humlib/blob/master/min/humlib.h
// Syntax: C++11
Expand Down Expand Up @@ -5647,6 +5647,40 @@ class HumdrumFileSet {



class Tool_1520ify : public HumTool {
public:
Tool_1520ify (void);
~Tool_1520ify () {};

bool run (HumdrumFileSet& infiles);
bool run (HumdrumFile& infile);
bool run (const std::string& indata, std::ostream& out);
bool run (HumdrumFile& infile, std::ostream& out);

protected:
void initialize (HumdrumFile& infile);
void processFile (HumdrumFile& infile);
void updateKeySignatures(HumdrumFile& infile, int lineindex);
void checkDataLine (HumdrumFile& infile, int lineindex);
void clearStates (void);
void addBibliographicRecords(HumdrumFile& infile);
void deleteBreaks (HumdrumFile& infile);
void fixEditorialAccidentals(HumdrumFile& infile);
void fixInstrumentAbbreviations(HumdrumFile& infile);
void addTerminalLongs (HumdrumFile& infile);
void deleteDummyTranspositions(HumdrumFile& infile);
std::string getDate (void);
int getYear (void);
void adjustSystemDecoration(HumdrumFile& infile);

private:
std::vector<std::vector<int>> m_pstates;
std::vector<std::vector<int>> m_kstates;
std::vector<std::vector<bool>> m_estates;

};


class Tool_addic : public HumTool {
public:
Tool_addic (void);
Expand Down Expand Up @@ -5923,6 +5957,31 @@ class Tool_autostem : public HumTool {
};


class Tool_bardash : public HumTool {

public:
Tool_bardash (void);
~Tool_bardash() {};

bool run (HumdrumFileSet& infiles);
bool run (HumdrumFile& infile);
bool run (const std::string& indata, std::ostream& out);
bool run (HumdrumFile& infile, std::ostream& out);

protected:
void initialize (void);
void processFile (HumdrumFile& infile);
void removeBarStylings(HumdrumFile& infile);
void removeBarStylings(HTp spine);
void applyBarStylings(HumdrumFile& infile);
void applyBarStylings(HTp spine);

private:
bool m_removeQ = false; // used with -r option

};


class Tool_binroll : public HumTool {
public:
Tool_binroll (void);
Expand Down
3 changes: 3 additions & 0 deletions src/doc.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -397,6 +397,8 @@ void Doc::CalculateTimemap()

void Doc::ExportMIDI(smf::MidiFile *midiFile)
{
midiFile->absoluteTicks();

if (!this->HasTimemap()) {
// generate MIDI timemap before progressing
CalculateTimemap();
Expand Down Expand Up @@ -540,6 +542,7 @@ void Doc::ExportMIDI(smf::MidiFile *midiFile)
tempoEventTicks = generateMIDI.GetTempoEventTicks();
}
}
midiFile->sortTracks();
}

bool Doc::ExportTimemap(std::string &output, bool includeRests, bool includeMeasures, bool useFractions)
Expand Down
Loading
Loading