Skip to content

Commit

Permalink
squash
Browse files Browse the repository at this point in the history
Clang Format

add "global" table to Lua state plus redo voice data for formula editor

Default sandbox functions

Add back "global" table clear in setSurgeFunctionEnvironment()

Add stack test

squash

Fix segfault in testrunner

clang format

Move Nimbus from libsamplerate to our Lanczos downsampler (#7726)

1. Makes it ready to move to sst-effects
2. Makes it so we can almost remove libsamplerate (but some
   twist smidgeof work to do that)
3. Uses less CPU

Addresses #7359

Remove libsamplerate dependency (#7728)

After porting Nimbus ot lanczos in 4b3ffe6 we can now remove the
libsamplerate dependency altogether as long as we fix up the twist
fm (which we did with a simple application of another lanczos ds)
and remove src code from the unit tests (where it was explicitly
tested)

Move Nimbus to sst-effects (#7729)

* Move Nimbus to sst-effects

Addresses #7359

With an almost-complete port (param name dynamism is in surge
but not in the submodule yet)

* f

Update LFO and Step Seq presets to have the LFO EG enabled (#7732)

Code Checks github action, as part one of move to actions

Move to actions here will be a bit trickier, but we will
get there. Step one is have any action at all, so add a code
check action.

Pull Request moves to Github Actions (#7733)

The PullRequest support of our azure pipeline is now on GitHub actions, building in various configurations and running the tests. The azure pipeline still exists to trigger the release stage, which is what I'll port tomorrow, or maybe thursday, and then be done with the azure->actions project.

- Adds voice_id, voice_max, voice_count, is_display parameters to formula modulator
- Fakes voice_count of "1" and sets defaults for other params on display calls
- Adds "shared" table to formula modulator
- Sets entries of "shared" table to nil on new Lua function env
- Makes formula debugger also use "shared" table
- Adds lua_isfunction to formula debugger
- Some cleanup
  • Loading branch information
nuoun committed Aug 3, 2024
1 parent 5500999 commit 2346791
Show file tree
Hide file tree
Showing 52 changed files with 438 additions and 954 deletions.
106 changes: 106 additions & 0 deletions .github/workflows/build-pr.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,106 @@
name: Build Pull Request
on:
pull_request:

defaults:
run:
shell: bash

jobs:
build_plugin:
name: PR - ${{ matrix.name }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
include:
- name: "windows msvc"
os: windows-latest
target: surge-xt_Standalone
cmakeConfig: -A x64
cmakeOpt: DEBUG
runTests: false
- name: "windows msvc 32 bit"
os: windows-latest
target: surge-xt_Standalone
cmakeConfig: -A Win32
cmakeOpt: DEBUG
runTests: false
- name: "windows clang"
os: windows-latest
target: surge-xt_Standalone
cmakeConfig: -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang
cmakeOpt: DEBUG
runTests: false
- name: "ubuntu standalone"
os: ubuntu-latest
target: surge-xt_Standalone
cmakeConfig:
cmakeOpt: DEBUG
runTests: false
- name: "macos standalone"
os: macos-latest
target: surge-xt_Standalone
cmakeConfig: -DCMAKE_OSX_ARCHITECTURES="x86_64;arm64"
cmakeOpt: DEBUG
runTests: false

- name: "mac test runner"
os: macos-latest
target: surge-testrunner
cmakeConfig:
cmakeOpt: RELEASE
runTests: true
- name: "linux test runner"
os: ubuntu-latest
target: surge-testrunner
cmakeConfig:
cmakeOpt: RELEASE
runTests: true
- name: "windows test runner"
os: windows-latest
target: surge-testrunner
cmakeConfig: -A x64
cmakeOpt: RELEASE
runTests: true

steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: recursive

- name: Prepare for JUCE
uses: surge-synthesizer/sst-githubactions/prepare-for-juce@main
with:
os: ${{ runner.os }}

- name: Build pull request version
run: |
cmake -S . -B ./build -DCMAKE_BUILD_TYPE=${{ matrix.cmakeOpt }} ${{ matrix.cmakeConfig }}
cmake --build ./build --config ${{ matrix.cmakeOpt }} --target ${{ matrix.target }} --parallel 3
- name: Run Tests
if: ${{ matrix.runTests }}
run: |
set -e
cd build
ctest -j 4 || ctest --rerun-failed --output-on-failure
build_plugin_lindoc:
name: PR - U18 Docker
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
submodules: recursive

- name: Build in Docker
uses: surge-synthesizer/sst-githubactions/cmake-in-docker@main
with:
username: ${{ github.actor }}
token: ${{ secrets.GITHUB_TOKEN }}
cmakeArgs: -DCMAKE_BUILD_TYPE=Debug -GNinja
target: surge-xt_Standalone

17 changes: 17 additions & 0 deletions .github/workflows/code-checks.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
name: Format Check
on: [ pull_request ]
jobs:
formatting-check:
name: Clang Format Check
runs-on: ubuntu-latest
strategy:
matrix:
path: [ 'src' ]
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Run clang-format style check
uses: surge-synthesizer/sst-githubactions/clang-format-check@main
with:
path: ${{ matrix.path }}
3 changes: 0 additions & 3 deletions .gitmodules
Original file line number Diff line number Diff line change
Expand Up @@ -10,9 +10,6 @@
[submodule "libs/JUCE"]
path = libs/JUCE
url = https://github.com/surge-synthesizer/JUCE
[submodule "libs/libsamplerate"]
path = libs/libsamplerate
url = https://github.com/libsndfile/libsamplerate.git
[submodule "libs/luajitlib/LuaJIT"]
path = libs/luajitlib/LuaJIT
url = https://github.com/LuaJIT/LuaJIT.git
Expand Down
193 changes: 0 additions & 193 deletions azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,199 +29,6 @@ jobs:
displayName: Do Codequal
- job: BuildLinuxDocker
condition: eq(variables['Build.Reason'], 'PullRequest')
pool:
vmImage: 'ubuntu-20.04'

steps:
- checkout: self
fetchDepth: 1
# submodules: recursive # can't do submodules here b'cuz depth=1 fails with Github

- bash: |
set -x
export VUID=$(id -u)
export VGID=$(id -g)
docker pull baconpaul/sst-dockerimages-ubuntu18:3
docker create --user $VUID:$VGID --name surge-build-u18 --interactive --tty \
--volume=`pwd`:/home/build/surge baconpaul/sst-dockerimages-ubuntu18:3
docker start surge-build-u18
git submodule update --init --recursive
docker exec surge-build-u18 bash -c "(cd /home/build/surge && ./scripts/docker-build/build.sh build --target surge-xt_LV2 --parallel 6)"
docker stop surge-build-u18
ls build/surge_xt_products
displayName: Do Docker Build
- job: BuildForPR
condition: eq(variables['Build.Reason'], 'PullRequest')
variables:
defaultTargets: "surge-xt_Packaged surge-fx_Packaged"
strategy:
matrix:
macOS-unit-test:
imageName: 'macos-latest'
isMac: True
isMacUnitTest: True
isUnitTest: True
cmakeArguments: "-GNinja"
cmakeTarget: "surge-testrunner"
cmakeConfig: "Release"
windows-x86-32bit-msvc:
imageName: 'windows-2019'
isWindows: True
cmakeArguments: "-A Win32 -DCMAKE_BUILD_TYPE=Debug"
cmakeConfig: "Debug"
cmakeTarget: "surge-xt_CLAP" # just a subset for time
macOS-x86:
imageName: 'macos-latest'
isMac: True
isMacFat: True
cmakeArguments: "-GNinja -DCMAKE_BUILD_TYPE=Debug -D\"CMAKE_OSX_ARCHITECTURES=x86_64\""
cmakeTarget: $(defaultTargets)
cmakeConfig: "Debug"
macOS-arm:
imageName: 'macos-latest'
isMac: True
isMacFat: True
cmakeArguments: "-GNinja -DCMAKE_BUILD_TYPE=Debug -D\"CMAKE_OSX_ARCHITECTURES=arm64\""
cmakeTarget: $(defaultTargets)
cmakeConfig: "Debug"
windows-x64-msvc:
imageName: 'windows-2019'
isWindows: True
cmakeArguments: "-A x64 -DCMAKE_BUILD_TYPE=Debug"
cmakeConfig: "Debug"
cmakeTarget: $(defaultTargets)
#windows-x64-clang:
# imageName: 'windows-2022'
# isWindows: True
# cmakeArguments: "-GNinja -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_BUILD_TYPE=Debug"
# cmakeConfig: "Debug"
# cmakeTarget: $(defaultTargets)
windows-unittest-clang:
imageName: 'windows-2022'
isWindows: True
isWindowsUnitTest: True
isUnitTest: True
cmakeArguments: "-A x64 -DCMAKE_BUILD_TYPE=Release"
#cmakeArguments: "-GNinja -DCMAKE_CXX_COMPILER=clang++ -DCMAKE_C_COMPILER=clang -DCMAKE_BUILD_TYPE=Release"
cmakeConfig: "Release"
cmakeTarget: "surge-testrunner"
linux-juce-python-targets:
imageName: 'ubuntu-22.04'
isLinux: True
cmakeArguments: "-GNinja -DCMAKE_BUILD_TYPE=Debug -DSURGE_BUILD_PYTHON_BINDINGS=True"
cmakeTarget: "surge-xt_Packaged surge-fx_Packaged surgepy"
cmakeConfig: "Debug"
linux-unittest:
imageName: 'ubuntu-latest'
isLinux: True
isLinuxUnitTest: True
isUnitTest: True
cmakeArguments: "-DCMAKE_BUILD_TYPE=Release -DCMAKE_CXX_COMPILER=g++-12 -DCMAKE_C_COMPILER=gcc-12"
cmakeConfig: "Release"
cmakeTarget: "surge-testrunner"


pool:
vmImage: $(imageName)

steps:
- checkout: self
fetchDepth: 1
# submodules: recursive # can't do submodules here b'cuz depth=1 fails with Github

- bash: |
echo "BUILD REASON = " $BUILD_REASON
echo "cmakeArguments = " $(cmakeArguments)
echo "cmakeTarget = " $(cmakeTarget)
echo "cmakeConfig = " $(cmakeConfig)
echo "aptGetExtras = " $(aptGetExtras)
displayName: all - details on build
- bash: |
# do this here, because we're using a shallow clone and it fails using `submodules: recursive` above
# Pipelines be timin out. Try this thrice. Should be cheap if it works.
. ./scripts/misc/defensive-submodule.sh
. ./scripts/misc/defensive-submodule.sh
. ./scripts/misc/defensive-submodule.sh
displayName: all - submodule init
- bash: |
set -e
echo "aptGetExtras are $(aptGetExtras)"
sudo apt-get update
sudo apt-get install -y \
devscripts \
libxcb-cursor-dev \
libxcb-keysyms1-dev \
libxcb-util-dev \
libxkbcommon-dev \
libxkbcommon-x11-dev \
ninja-build \
xcb \
$(aptGetExtras)
# These are the JUCE deps
sudo apt-get install -y libgtk-3-dev
sudo apt-get install -y libwebkit2gtk-4.0
sudo apt-get install -y libwebkit2gtk-4.0-dev
sudo apt-get install -y libcurl4-openssl-dev
sudo apt-get install -y alsa
sudo apt-get install -y alsa-tools
sudo apt-get install -y libasound2-dev
sudo apt-get install -y libjack-dev
sudo apt-get install -y libfreetype6-dev
sudo apt-get install -y libxinerama-dev
sudo apt-get install -y libxcb-xinerama0
sudo apt-get install -y libxinerama1
sudo apt-get install -y x11proto-xinerama-dev
sudo apt-get install -y libxrandr-dev
sudo apt-get install -y libgl1-mesa-dev
sudo apt-get install -y libxcursor-dev
sudo apt-get install -y libxcursor1
sudo apt-get install -y libxcb-cursor-dev
sudo apt-get install -y libxcb-cursor0
sudo apt-get install -y --fix-missing
condition: variables.isLinux
displayName: linux - run apt-get
- bash: |
brew install ninja
sudo xcode-select -s /Applications/Xcode_13.4.1.app
displayName: Select XCode 13.4.1
condition: variables.isMac
- bash: |
set -e
cmake -Bbuild $(cmakeArguments)
displayName: all - configure with cmake
- bash: |
set -e
cmake --build build --config $(cmakeConfig) --target $(cmakeTarget) --parallel 8
displayName: all - build with cmake
- bash: |
set -e
cd build
ctest -j 4 || ctest --rerun-failed --output-on-failure
condition: variables.isUnitTest
displayName: all - run unit tests
- job: NotifyReleases
dependsOn: BuildCodeQuality
condition: and(succeeded(), not(eq(variables['Build.Reason'], 'PullRequest')))
Expand Down
1 change: 0 additions & 1 deletion libs/libsamplerate
Submodule libsamplerate deleted from d0ea53
12 changes: 6 additions & 6 deletions resources/data/modulator_presets/LFO/8th Note S&H.modpreset
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
<deform v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<trigmode i="1" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<unipolar i="0" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<attack v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<attack v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
</params>
</lfo>
12 changes: 6 additions & 6 deletions resources/data/modulator_presets/LFO/Delayed Vibrato.modpreset
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
<deform v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<trigmode i="1" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<unipolar i="0" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-1.125000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<attack v="-0.916666" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-1.125000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<attack v="-0.916666" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
</params>
</lfo>
12 changes: 6 additions & 6 deletions resources/data/modulator_presets/LFO/Noise.modpreset
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@
<deform v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<trigmode i="2" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<unipolar i="0" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<attack v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="1" />
<delay v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<hold v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<attack v="-8.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<decay v="0.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<sustain v="1.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
<release v="5.000000" temposync="0" deform_type="0" extend_range="0" deactivated="0" />
</params>
</lfo>
Loading

0 comments on commit 2346791

Please sign in to comment.