Skip to content

Commit

Permalink
Merge branch 'develop' into develop-facsimile-neume-line
Browse files Browse the repository at this point in the history
  • Loading branch information
lpugin committed May 14, 2024
2 parents 142e75b + 771f48a commit 35538a9
Show file tree
Hide file tree
Showing 22 changed files with 314 additions and 132 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -100,11 +100,11 @@ jobs:

- os: macos-latest
compiler: xcode
version: "13.1"
version: "14.3"

- os: macos-latest
compiler: xcode
version: "14.2"
version: "15.3"

- os: macos-11
compiler: g++
Expand Down
52 changes: 32 additions & 20 deletions .github/workflows/python-ci-wheel.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,13 +23,16 @@ jobs:
fail-fast: false
# Build the wheels for Linux, Windows and macOS
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
os: [macos-13, macos-14, windows-latest, ubuntu-latest]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12"]
architecture: [x86, x64]
architecture: [x86, x64, arm64]
include:
- os: macos-latest
- os: macos-13
architecture: x64
platform_id: macosx_*
platform_id: macosx_x86_64
- os: macos-14
architecture: arm64
platform_id: macosx_arm64
- os: windows-latest
architecture: x64
platform_id: win_amd64
Expand All @@ -40,24 +43,35 @@ jobs:
architecture: x64
platform_id: manylinux_x86_64
exclude:
- os: macos-latest
- os: macos-13
architecture: x86
- os: macos-13
architecture: arm64
- os: macos-14
architecture: x86
- os: macos-14
architecture: x64
- os: ubuntu-latest
architecture: x86
- os: ubuntu-latest
architecture: arm64
- os: windows-latest
architecture: arm64

steps:
#===============================================#
# Set up
- uses: actions/checkout@v4
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
fetch-depth: 0

- uses: nuget/setup-nuget@v1
- uses: nuget/setup-nuget@a21f25cd3998bf370fde17e3f1b4c12c175172f9 # v2.0.0
if: always() && runner.os == 'Windows'
with:
nuget-version: "latest"

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: ${{ matrix.python-version }}
architecture: ${{ matrix.architecture }}
Expand All @@ -82,16 +96,14 @@ jobs:
#===============================================#
# wheels
- name: Build wheels
uses: pypa/cibuildwheel@v2.16.5
uses: pypa/cibuildwheel@8d945475ac4b1aac4ae08b2fd27db9917158b6ce # v2.17.0
with:
output-dir: wheelhouse
env:
CIBW_SKIP: cp37-macosx_arm64
CIBW_BUILD: ${{ env.CIBW_BUILD_IDENTIFIER }}
CIBW_ARCHS_MACOS: x86_64 arm64
CIBW_ENVIRONMENT_MACOS:
MACOSX_DEPLOYMENT_TARGET=10.15
CIBW_TEST_SKIP: cp*-macosx_arm64
CIBW_MANYLINUX_X86_64_IMAGE: manylinux2014
CIBW_MANYLINUX_I686_IMAGE: manylinux2014
CIBW_BEFORE_ALL_MACOS: brew update && brew install swig
Expand Down Expand Up @@ -119,7 +131,7 @@ jobs:
- name: Install from wheel on macOS
working-directory: wheelhouse
if: always() && runner.os == 'macOS'
run: python -m pip install ./*x86_64.whl
run: python -m pip install ./*.whl

# Wildcard use is different with PowerShell
# cf. https://stackoverflow.com/a/43900040
Expand All @@ -134,9 +146,9 @@ jobs:

#===============================================#
# Upload artifacts
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
with:
name: cibuildwheel-${{ runner.os }}-python-${{ matrix.python-version }}
name: cibuildwheel-${{ runner.os }}-python-${{ matrix.python-version }}-${{ matrix.architecture }}
path: ./wheelhouse/*.whl

#===============================================#
Expand All @@ -149,12 +161,12 @@ jobs:
steps:
#===============================================#
# Set up
- uses: actions/checkout@v4
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4
with:
fetch-depth: 0

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v4
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: "3.9"

Expand Down Expand Up @@ -210,7 +222,7 @@ jobs:

#===============================================#
# Upload artifact
- uses: actions/upload-artifact@v3
- uses: actions/upload-artifact@65462800fd760344b1a7b4382951275a0abb4808 # v4.3.3
with:
name: sdist-${{ runner.os }}-python-3.9
path: dist/*.tar.gz
Expand All @@ -226,10 +238,10 @@ jobs:
steps:
#===============================================#
# Set up
- uses: actions/checkout@v4
- uses: actions/checkout@0ad4b8fadaa221de15dcec353f45205ec38ea70b # v4.1.4

- name: Set up Python 3.9
uses: actions/setup-python@v4
uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d # v5.1.0
with:
python-version: "3.9"
architecture: "x64"
Expand All @@ -244,7 +256,7 @@ jobs:
#===============================================#
# Prepare artifacts
- name: Download artifacts
uses: actions/download-artifact@v3
uses: actions/download-artifact@65a9edc5881444af0b9093a5e628f2fe47ea3b2e # v4.1.7
with:
path: bindings/python/artifacts/

Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/tests_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ jobs:
runs-on: ubuntu-22.04

steps:
- uses: FranzDiebold/github-env-vars-action@v2.7.0
- uses: FranzDiebold/github-env-vars-action@v2.8.0
- name: Get Short SHA
run: |
echo "SHORT_SHA=`echo ${{ github.event.pull_request.head.sha }} | cut -c1-7`" >> $GITHUB_ENV
Expand Down Expand Up @@ -109,14 +109,14 @@ jobs:
ls -al
- name: Upload results as artefacts
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: test-suite-diff
path: ${{ github.workspace }}/${{ env.OUTPUT_DIR }}/

- name: Check existence of the log.md file
id: check_files
uses: andstor/file-existence-action@v2
uses: andstor/file-existence-action@v3
with:
files: "${{ github.workspace }}/${{ env.OUTPUT_DIR }}/log.md"

Expand Down
8 changes: 8 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,16 @@
# Changelog

## [unreleased]

## [4.2.1] - 2024-05-07
* Fix GitHub actions (Python release only)

## [4.2.0] - 2024-05-05
* Support for `fTrem@unitdur` (@eNote-GmbH)
* Upgrade to C++20
* Update of the Midifile library
* Fix lyric position in MIDI output
* Fix string formatting output with some locale configurations (@ammatwain)

## [4.1.0] - 2023-12-15
* Support for staves ordered by `scoreDef`
Expand Down
2 changes: 1 addition & 1 deletion Verovio.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = 'Verovio'
s.version = '4.2.0-dev'
s.version = '4.3.0-dev'
s.license = { :type => 'LGPL', :file => 'COPYING' }
s.homepage = 'https://www.verovio.org/index.xhtml'
s.authors = { 'Contributors List' => 'https://github.com/rism-digital/verovio/graphs/contributors' }
Expand Down
2 changes: 1 addition & 1 deletion bindings/java/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

<groupId>org.rism.verovio</groupId>
<artifactId>VerovioToolkit</artifactId>
<version>4.2.0-dev</version>
<version>4.3.0-dev</version>
<packaging>jar</packaging>

<name>VerovioToolkit</name>
Expand Down
2 changes: 1 addition & 1 deletion bindings/python/.pypi-version
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
# dummy file used by setup.py for counting revisions when publishing to test.pypi
# counting can be reset by making a change to this file
4.2.0
4.3.0
4 changes: 4 additions & 0 deletions cmake/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,10 @@ else()
add_definitions(-DDEBUG)
endif()

if(WIN32)
include_directories(../include/win32)
endif()

# jsonxx raises -Wdollar-in-identifier-extension
# gcc 8.3.1 does not like -Wdollar-in-identifier-extension option.
add_definitions(-Wall -W -pedantic -Wno-unused-parameter -Wno-dollar-in-identifier-extension)
Expand Down
4 changes: 2 additions & 2 deletions codemeta.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,8 @@
"identifier": "Verovio",
"name": "Verovio",
"description": "Verovio is a fast, portable and lightweight open-source library for engraving Music Encoding Initiative (MEI) music scores into SVG.",
"softwareVersion": "4.2.0-dev",
"datePublished": "2023-12-15",
"softwareVersion": "4.3.0-dev",
"datePublished": "2024-05-07",
"license": "https://www.gnu.org/licenses/lgpl-3.0",
"programmingLanguage": [{
"@type": "ComputerLanguage",
Expand Down
2 changes: 1 addition & 1 deletion emscripten/npm/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "verovio",
"version": "4.2.0-alpha",
"version": "4.3.0-alpha",
"description": "This is the stable version of the verovio package",
"main": "dist/verovio-toolkit-wasm.js",
"exports": {
Expand Down
8 changes: 5 additions & 3 deletions include/midi/Binasc.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@
#ifndef _BINASC_H_INCLUDED
#define _BINASC_H_INCLUDED

#include <iostream>
#include <cstdlib>
#include <fstream>
#include <iostream>
#include <string>
#include <cstdlib>
#include <stdlib.h> /* needed for MinGW */


namespace smf {

Expand Down Expand Up @@ -149,6 +149,8 @@ class Binasc {
int getWord (std::string& word, const std::string& input,
const std::string& terminators, int index);

static const char *GMinstrument[128];

};

} // end of namespace smf
Expand Down
7 changes: 7 additions & 0 deletions include/midi/MidiEvent.h
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,11 @@
#define _MIDIEVENT_H_INCLUDED

#include "MidiMessage.h"

#include <ostream>
#include <vector>


namespace smf {

class MidiEvent : public MidiMessage {
Expand Down Expand Up @@ -63,6 +66,10 @@ class MidiEvent : public MidiMessage {

};


std::ostream& operator<<(std::ostream& out, MidiEvent& event);


} // end of namespace smf

#endif /* _MIDIEVENT_H_INCLUDED */
Expand Down
2 changes: 2 additions & 0 deletions include/midi/MidiEventList.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,10 @@
#define _MIDIEVENTLIST_H_INCLUDED

#include "MidiEvent.h"

#include <vector>


namespace smf {

class MidiEventList {
Expand Down
23 changes: 14 additions & 9 deletions include/midi/MidiFile.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,19 +16,24 @@

#include "MidiEventList.h"

#include <vector>
#include <string>
#include <istream>
#include <fstream>
#include <istream>
#include <string>
#include <vector>

#define TIME_STATE_DELTA 0
#define TIME_STATE_ABSOLUTE 1

#define TRACK_STATE_SPLIT 0
#define TRACK_STATE_JOINED 1

namespace smf {

enum {
TRACK_STATE_SPLIT = 0, // Tracks are separated into separate vector postions.
TRACK_STATE_JOINED = 1 // Tracks are merged into a single vector position,
}; // like a Type-0 MIDI file, but reversible.

enum {
TIME_STATE_DELTA = 0, // MidiMessage::ticks are in delta time format (like MIDI file).
TIME_STATE_ABSOLUTE = 1 // MidiMessage::ticks are in absolute time format (0=start time).
};

class _TickTime {
public:
int tick;
Expand Down Expand Up @@ -217,7 +222,7 @@ class MidiFile {
MidiEvent* addTempo (int aTrack, int aTick,
double aTempo);
MidiEvent* addKeySignature (int aTrack, int aTick,
int key, bool mode = 0);
int fifths, bool mode = 0);
MidiEvent* addTimeSignature (int aTrack, int aTick,
int top, int bottom,
int clocksPerClick = 24,
Expand Down
11 changes: 11 additions & 0 deletions include/midi/MidiMessage.h
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,12 @@
#ifndef _MIDIMESSAGE_H_INCLUDED
#define _MIDIMESSAGE_H_INCLUDED

#include <iostream>
#include <string>
#include <utility>
#include <vector>


namespace smf {

typedef unsigned char uchar;
Expand Down Expand Up @@ -122,6 +124,12 @@ class MidiMessage : public std::vector<uchar> {
void makePatchChange (int channel, int patchnum);
void makeTimbre (int channel, int patchnum);
void makeController (int channel, int num, int value);
void makePitchBend (int channel, int lsb, int msb);
void makePitchBend (int channel, int value);
void makePitchBendDouble (int channel, double value);
void makePitchbend (int channel, int lsb, int msb) { makePitchBend(channel, lsb, msb); }
void makePitchbend (int channel, int value) { makePitchBend(channel, value); }
void makePitchbendDouble (int channel, double value) { makePitchBendDouble(channel, value); }

// helper functions to create various continuous controller messages:
void makeSustain (int channel, int value);
Expand Down Expand Up @@ -199,6 +207,9 @@ class MidiMessage : public std::vector<uchar> {
};


std::ostream& operator<<(std::ostream& out, MidiMessage& event);


} // end of namespace smf


Expand Down
2 changes: 1 addition & 1 deletion include/vrv/vrvdef.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ namespace vrv {
//----------------------------------------------------------------------------

#define VERSION_MAJOR 4
#define VERSION_MINOR 2
#define VERSION_MINOR 3
#define VERSION_REVISION 0
// Adds "-dev" in the version number - should be set to false for releases
#define VERSION_DEV true
Expand Down
Loading

0 comments on commit 35538a9

Please sign in to comment.