From a0233040009c5c6c7acfa374b9fa0c7b31328710 Mon Sep 17 00:00:00 2001 From: DJLevel3 Date: Wed, 3 Sep 2025 06:12:13 -0400 Subject: [PATCH 1/4] Fix goniometer --- Source/visualiser/VisualiserRenderer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/visualiser/VisualiserRenderer.cpp b/Source/visualiser/VisualiserRenderer.cpp index e42380f9..33d0b8fa 100644 --- a/Source/visualiser/VisualiserRenderer.cpp +++ b/Source/visualiser/VisualiserRenderer.cpp @@ -103,7 +103,7 @@ void VisualiserRenderer::runTask(const std::vector &points) { #if OSCI_PREMIUM if (parameters.isGoniometer()) { // x and y go to a diagonal currently, so we need to scale them down, and rotate them - point.scale(1.0 / std::sqrt(2.0), 1.0 / std::sqrt(2.0), 1.0); + point.scale(1.0 / std::sqrt(2.0), -1.0 / std::sqrt(2.0), 1.0); point.rotate(0, 0, -juce::MathConstants::pi / 4); } #endif From fcd6ef2525bb28e0291f39ae55f360fdecb54cb5 Mon Sep 17 00:00:00 2001 From: DJLevel3 Date: Wed, 3 Sep 2025 06:25:50 -0400 Subject: [PATCH 2/4] Invert the correct axis --- Source/visualiser/VisualiserRenderer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Source/visualiser/VisualiserRenderer.cpp b/Source/visualiser/VisualiserRenderer.cpp index 33d0b8fa..7225524d 100644 --- a/Source/visualiser/VisualiserRenderer.cpp +++ b/Source/visualiser/VisualiserRenderer.cpp @@ -103,7 +103,7 @@ void VisualiserRenderer::runTask(const std::vector &points) { #if OSCI_PREMIUM if (parameters.isGoniometer()) { // x and y go to a diagonal currently, so we need to scale them down, and rotate them - point.scale(1.0 / std::sqrt(2.0), -1.0 / std::sqrt(2.0), 1.0); + point.scale(-1.0 / std::sqrt(2.0), 1.0 / std::sqrt(2.0), 1.0); point.rotate(0, 0, -juce::MathConstants::pi / 4); } #endif From 1f871232ff3fbf972e967646712ddd5b0fa7ed97 Mon Sep 17 00:00:00 2001 From: James H Ball Date: Wed, 3 Sep 2025 19:23:21 +0100 Subject: [PATCH 3/4] Add skew effect and fix multiplex delay --- Resources/svg/skew.svg | 1 + Source/PluginProcessor.cpp | 2 ++ Source/audio/MultiplexEffect.h | 4 ++-- Source/audio/SkewEffect.h | 38 ++++++++++++++++++++++++++++++++++ osci-render.jucer | 2 ++ 5 files changed, 45 insertions(+), 2 deletions(-) create mode 100644 Resources/svg/skew.svg create mode 100644 Source/audio/SkewEffect.h diff --git a/Resources/svg/skew.svg b/Resources/svg/skew.svg new file mode 100644 index 00000000..c95c188f --- /dev/null +++ b/Resources/svg/skew.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Source/PluginProcessor.cpp b/Source/PluginProcessor.cpp index 6e25aaec..7c577688 100644 --- a/Source/PluginProcessor.cpp +++ b/Source/PluginProcessor.cpp @@ -25,6 +25,7 @@ #include "audio/RippleEffect.h" #include "audio/SwirlEffect.h" #include "audio/BounceEffect.h" +#include "audio/SkewEffect.h" #include "parser/FileParser.h" #include "parser/FrameProducer.h" @@ -54,6 +55,7 @@ OscirenderAudioProcessor::OscirenderAudioProcessor() : CommonAudioProcessor(Buse toggleableEffects.push_back(KaleidoscopeEffect(*this).build()); toggleableEffects.push_back(BounceEffect().build()); toggleableEffects.push_back(TwistEffect().build()); + toggleableEffects.push_back(SkewEffect().build()); #endif auto scaleEffect = ScaleEffectApp().build(); diff --git a/Source/audio/MultiplexEffect.h b/Source/audio/MultiplexEffect.h index 3df402e8..4bef9f91 100644 --- a/Source/audio/MultiplexEffect.h +++ b/Source/audio/MultiplexEffect.h @@ -9,13 +9,13 @@ public: explicit MultiplexEffect(OscirenderAudioProcessor &p) : audioProcessor(p) {} osci::Point apply(int index, osci::Point input, const std::vector>& values, double sampleRate) override { - jassert(values.size() >= 5); + jassert(values.size() == 5); double gridX = values[0].load() + 0.0001; double gridY = values[1].load() + 0.0001; double gridZ = values[2].load() + 0.0001; double interpolation = values[3].load(); - double gridDelay = values[5].load(); + double gridDelay = values[4].load(); head++; if (head >= (int)buffer.size()) { diff --git a/Source/audio/SkewEffect.h b/Source/audio/SkewEffect.h new file mode 100644 index 00000000..1e3e4976 --- /dev/null +++ b/Source/audio/SkewEffect.h @@ -0,0 +1,38 @@ +#pragma once +#include +#include + +// Simple shear (skew) along each axis: X += skewX * Y, Y += skewY * Z, Z += skewZ * X +// Useful subtle perspective-like distortion that can be layered with scale/rotate. +class SkewEffect : public osci::EffectApplication { +public: + SkewEffect() {} + + osci::Point apply(int /*index*/, osci::Point input, const std::vector>& values, double /*sampleRate*/) override { + jassert(values.size() == 3); + double tx = values[0].load(); // skew X by Y + double ty = values[1].load(); // skew Y by Z + double tz = values[2].load(); // skew Z by X + + // Apply sequential shears; keep original components where appropriate to avoid compounding order surprises. + osci::Point out = input; + out.x += tx * input.y; // shear X by Y + out.y += ty * input.z; // shear Y by Z + out.z += tz * input.x; // shear Z by X + return out; + } + + std::shared_ptr build() const override { + auto eff = std::make_shared( + std::make_shared(), + std::vector{ + new osci::EffectParameter("Skew X", "Skews (shears) the shape horizontally based on vertical position.", "skewX", VERSION_HINT, 0.0, -1.0, 1.0, 0.0001f, osci::LfoType::Sine, 0.2f), + new osci::EffectParameter("Skew Y", "Skews (shears) the shape vertically based on depth.", "skewY", VERSION_HINT, 0.0, -1.0, 1.0), + new osci::EffectParameter("Skew Z", "Skews (shears) the shape in depth based on horizontal position.", "skewZ", VERSION_HINT, 0.0, -1.0, 1.0), + } + ); + eff->setName("Skew"); + eff->setIcon(BinaryData::skew_svg); + return eff; + } +}; diff --git a/osci-render.jucer b/osci-render.jucer index 98a4786c..c77d7694 100644 --- a/osci-render.jucer +++ b/osci-render.jucer @@ -137,6 +137,7 @@ + @@ -165,6 +166,7 @@ + From 51b6cb7a8a35fc2d13431c81822b6c569ae3aa75 Mon Sep 17 00:00:00 2001 From: James H Ball Date: Thu, 4 Sep 2025 07:32:44 +0100 Subject: [PATCH 4/4] Set build timeout to 30 minutes --- .github/workflows/build.yaml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index f878339b..ea5f3d10 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -10,6 +10,7 @@ jobs: build: name: Build (${{ matrix.project }} ${{ matrix.version }} @ ${{ matrix.os }}) runs-on: ${{ matrix.os }} + timeout-minutes: 30 strategy: fail-fast: false matrix: