Skip to content

Commit

Permalink
Fix win32 CI setup; Set audio port group hint; Sample rate changes
Browse files Browse the repository at this point in the history
Signed-off-by: falkTX <falktx@falktx.com>
  • Loading branch information
falkTX committed Jul 22, 2022
1 parent 2b247cd commit c2ee908
Show file tree
Hide file tree
Showing 6 changed files with 35 additions and 11 deletions.
18 changes: 14 additions & 4 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ jobs:
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get install -yqq --allow-downgrades libgd3/focal libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
- name: Set up dependencies
run: |
sudo dpkg --add-architecture arm64
Expand Down Expand Up @@ -60,7 +61,8 @@ jobs:
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get install -yqq --allow-downgrades libgd3/focal libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
- name: Set up dependencies
run: |
sudo dpkg --add-architecture armhf
Expand Down Expand Up @@ -98,7 +100,8 @@ jobs:
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get install -yqq --allow-downgrades libgd3/focal libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
- name: Set up dependencies
run: |
sudo dpkg --add-architecture i386
Expand Down Expand Up @@ -193,7 +196,8 @@ jobs:
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get install -yqq --allow-downgrades libgd3/focal libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
- name: Set up dependencies
run: |
sudo dpkg --add-architecture i386
Expand Down Expand Up @@ -226,6 +230,12 @@ jobs:
- uses: actions/checkout@v2
with:
submodules: recursive
- name: Fix GitHub's mess
run: |
sudo rm -f /etc/apt/sources.list.d/microsoft-prod.list
sudo apt-get update -qq
sudo apt-get install -yqq --allow-downgrades libgd3/focal libpcre2-8-0/focal libpcre2-16-0/focal libpcre2-32-0/focal libpcre2-posix2/focal
sudo apt-get purge -yqq libmono* moby* mono* php* libgdiplus libpcre2-posix3 libzip4
- name: Set up dependencies
run: |
sudo apt-get update -qq
Expand Down
3 changes: 0 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,6 @@ plugins:
ifneq ($(CROSS_COMPILING),true)
gen: plugins dpf/utils/lv2_ttl_generator
@$(CURDIR)/dpf/utils/generate-ttl.sh
ifeq ($(MACOS),true)
@$(CURDIR)/dpf/utils/generate-vst-bundles.sh
endif

dpf/utils/lv2_ttl_generator:
$(MAKE) -C dpf/utils/lv2-ttl-generator
Expand Down
2 changes: 1 addition & 1 deletion dpf
Submodule dpf updated 133 files
2 changes: 1 addition & 1 deletion plugins/Kars/DistrhoPluginInfo.h
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* DISTRHO Kars Plugin, based on karplong by Chris Cannam.
* Copyright (C) 2015 Filipe Coelho <falktx@falktx.com>
* Copyright (C) 2015-2022 Filipe Coelho <falktx@falktx.com>
*
* Permission to use, copy, modify, and/or distribute this software for any purpose with
* or without fee is hereby granted, provided that the above copyright notice and this
Expand Down
17 changes: 16 additions & 1 deletion plugins/Kars/DistrhoPluginKars.cpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* DISTRHO Kars Plugin, based on karplong by Chris Cannam.
* Copyright (C) 2015-2019 Filipe Coelho <falktx@falktx.com>
* Copyright (C) 2015-2022 Filipe Coelho <falktx@falktx.com>
*
* Permission to use, copy, modify, and/or distribute this software for any purpose with
* or without fee is hereby granted, provided that the above copyright notice and this
Expand Down Expand Up @@ -39,6 +39,13 @@ DistrhoPluginKars::DistrhoPluginKars()
// -----------------------------------------------------------------------
// Init

void DistrhoPluginKars::initAudioPort(bool input, uint32_t index, AudioPort& port)
{
port.groupId = kPortGroupMono;

Plugin::initAudioPort(input, index, port);
}

void DistrhoPluginKars::initParameter(uint32_t index, Parameter& parameter)
{
switch (index)
Expand Down Expand Up @@ -167,6 +174,14 @@ void DistrhoPluginKars::run(const float**, float** outputs, uint32_t frames, con
}
}

void DistrhoPluginKars::sampleRateChanged(double newSampleRate)
{
fSampleRate = getSampleRate();

for (int i=kMaxNotes; --i >= 0;)
fNotes[i].setSampleRate(newSampleRate);
}

void DistrhoPluginKars::addSamples(float* out, int voice, uint32_t frames)
{
const uint32_t start = fBlockStart;
Expand Down
4 changes: 3 additions & 1 deletion plugins/Kars/DistrhoPluginKars.hpp
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/*
* DISTRHO Kars Plugin, based on karplong by Chris Cannam.
* Copyright (C) 2015-2019 Filipe Coelho <falktx@falktx.com>
* Copyright (C) 2015-2022 Filipe Coelho <falktx@falktx.com>
*
* Permission to use, copy, modify, and/or distribute this software for any purpose with
* or without fee is hereby granted, provided that the above copyright notice and this
Expand Down Expand Up @@ -81,6 +81,7 @@ class DistrhoPluginKars : public Plugin
// -------------------------------------------------------------------
// Init

void initAudioPort(bool input, uint32_t index, AudioPort& port) override;
void initParameter(uint32_t index, Parameter& parameter) override;

// -------------------------------------------------------------------
Expand All @@ -94,6 +95,7 @@ class DistrhoPluginKars : public Plugin

void activate() override;
void run(const float**, float** outputs, uint32_t frames, const MidiEvent* midiEvents, uint32_t midiEventCount) override;
void sampleRateChanged(double newSampleRate) override;

// -------------------------------------------------------------------

Expand Down

0 comments on commit c2ee908

Please sign in to comment.