Browse Source

Rename

tags/22.02
falkTX 3 years ago
parent
commit
0845a0ffa2
17 changed files with 86 additions and 71 deletions
  1. +4
    -4
      .gitmodules
  2. +14
    -16
      Makefile
  3. +3
    -1
      README.md
  4. +29
    -20
      plugins/Cardinal/CardinalPlugin.cpp
  5. +25
    -15
      plugins/Cardinal/CardinalUI.cpp
  6. +5
    -5
      plugins/Cardinal/DistrhoPluginInfo.h
  7. +3
    -3
      plugins/Cardinal/Makefile
  8. +0
    -0
      plugins/Cardinal/Rack
  9. +0
    -0
      plugins/Cardinal/ResizeHandle.hpp
  10. +3
    -7
      plugins/Cardinal/Window.cpp
  11. +0
    -0
      plugins/Cardinal/mingw-compat/Shlobj.h
  12. +0
    -0
      plugins/Cardinal/mingw-compat/Shlwapi.h
  13. +0
    -0
      plugins/Cardinal/mingw-compat/Windows.h
  14. +0
    -0
      plugins/Cardinal/mingw-compat/condition_variable
  15. +0
    -0
      plugins/Cardinal/mingw-compat/mutex
  16. +0
    -0
      plugins/Cardinal/mingw-compat/thread
  17. +0
    -0
      plugins/Cardinal/mingw-std-threads

+ 4
- 4
.gitmodules View File

@@ -1,9 +1,9 @@
[submodule "plugins/CVCRack/Rack"]
path = plugins/CVCRack/Rack
[submodule "plugins/Cardinal/Rack"]
path = plugins/Cardinal/Rack
url = https://github.com/VCVRack/Rack.git
[submodule "dpf"]
path = dpf
url = https://github.com/DISTRHO/DPF.git
[submodule "plugins/CVCRack/mingw-std-threads"]
path = plugins/CVCRack/mingw-std-threads
[submodule "plugins/Cardinal/mingw-std-threads"]
path = plugins/Cardinal/mingw-std-threads
url = https://github.com/meganz/mingw-std-threads.git

+ 14
- 16
Makefile View File

@@ -8,15 +8,13 @@ include dpf/Makefile.base.mk

all: dgl plugins gen

SKIP_NANOVG = true

# --------------------------------------------------------------

dgl:
$(MAKE) -C dpf/dgl opengl
$(MAKE) SKIP_NANOVG=true -C dpf/dgl opengl

plugins: dgl
$(MAKE) all -C plugins/CVCRack
$(MAKE) all -C plugins/Cardinal

ifneq ($(CROSS_COMPILING),true)
gen: plugins dpf/utils/lv2_ttl_generator
@@ -36,19 +34,19 @@ endif
clean:
$(MAKE) clean -C dpf/dgl
$(MAKE) clean -C dpf/utils/lv2-ttl-generator
$(MAKE) clean -C plugins/CVCRack
$(MAKE) clean -C plugins/Cardinal
rm -rf bin build
rm -rf plugins/CVCRack/Rack/dep/bin
rm -rf plugins/CVCRack/Rack/dep/include
rm -rf plugins/CVCRack/Rack/dep/lib
rm -rf plugins/CVCRack/Rack/dep/share
rm -rf plugins/CVCRack/Rack/dep/curl-7.66.0
rm -rf plugins/CVCRack/Rack/dep/glew-2.1.0
rm -rf plugins/CVCRack/Rack/dep/jansson-2.12
rm -rf plugins/CVCRack/Rack/dep/libarchive-3.4.3
rm -rf plugins/CVCRack/Rack/dep/openssl-1.1.1d
rm -rf plugins/CVCRack/Rack/dep/speexdsp-SpeexDSP-1.2rc3
rm -rf plugins/CVCRack/Rack/dep/zstd-1.4.5
rm -rf plugins/Cardinal/Rack/dep/bin
rm -rf plugins/Cardinal/Rack/dep/include
rm -rf plugins/Cardinal/Rack/dep/lib
rm -rf plugins/Cardinal/Rack/dep/share
rm -rf plugins/Cardinal/Rack/dep/curl-7.66.0
rm -rf plugins/Cardinal/Rack/dep/glew-2.1.0
rm -rf plugins/Cardinal/Rack/dep/jansson-2.12
rm -rf plugins/Cardinal/Rack/dep/libarchive-3.4.3
rm -rf plugins/Cardinal/Rack/dep/openssl-1.1.1d
rm -rf plugins/Cardinal/Rack/dep/speexdsp-SpeexDSP-1.2rc3
rm -rf plugins/Cardinal/Rack/dep/zstd-1.4.5

# --------------------------------------------------------------



+ 3
- 1
README.md View File

@@ -1,4 +1,6 @@
# DISTRHO CVCRack
# DISTRHO Cardinal

*Cardinal, bring forth the Rack!*

WORK IN PROGRESS - nothing to see here



plugins/CVCRack/CVCRackPlugin.cpp → plugins/Cardinal/CardinalPlugin.cpp View File

@@ -1,17 +1,18 @@
/*
* DISTRHO CVCRack Plugin
* DISTRHO Cardinal Plugin
* Copyright (C) 2021 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
* permission notice appear in all copies.
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 3 of
* the License, or any later version.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD
* TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN
* NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
* DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
* IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* For a full copy of the GNU General Public License see the LICENSE file.
*/
#include <asset.hpp>
@@ -35,6 +36,15 @@
START_NAMESPACE_DISTRHO
// -----------------------------------------------------------------------------------------------------------
// The following code was based from VCVRack adapters/standalone.cpp
/*
Copyright (C) 2016-2021 VCV
This program is free software: you can redistribute it and/or modify it under the terms of the
GNU General Public License as published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
*/
struct Initializer {
Initializer()
@@ -121,13 +131,12 @@ static const Initializer& getInitializerInstance()
return init;
}
/**
Plugin to demonstrate parameter outputs using meters.
*/
class CVCRackPlugin : public Plugin
// -----------------------------------------------------------------------------------------------------------
class CardinalPlugin : public Plugin
{
public:
CVCRackPlugin()
CardinalPlugin()
: Plugin(0, 0, 0)
{
}
@@ -142,7 +151,7 @@ protected:
*/
const char* getLabel() const override
{
return "CVCRack";
return "Cardinal";
}
/**
@@ -166,7 +175,7 @@ protected:
*/
const char* getHomePage() const override
{
return "https://github.com/DISTRHO/CVCRack";
return "https://github.com/DISTRHO/Cardinal";
}
/**
@@ -192,7 +201,7 @@ protected:
*/
int64_t getUniqueId() const override
{
return d_cconst('d', 'C', 'V', 'C');
return d_cconst('d', 'C', 'd', 'n');
}
/* --------------------------------------------------------------------------------------------------------
@@ -223,7 +232,7 @@ private:
/**
Set our plugin class as non-copyable and add a leak detector just in case.
*/
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CVCRackPlugin)
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CardinalPlugin)
};
/* ------------------------------------------------------------------------------------------------------------
@@ -232,7 +241,7 @@ private:
Plugin* createPlugin()
{
getInitializerInstance();
return new CVCRackPlugin();
return new CardinalPlugin();
}
// -----------------------------------------------------------------------------------------------------------

plugins/CVCRack/CVCRackUI.cpp → plugins/Cardinal/CardinalUI.cpp View File

@@ -1,17 +1,18 @@
/*
* DISTRHO CVCRack Plugin
* DISTRHO Cardinal Plugin
* Copyright (C) 2021 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
* permission notice appear in all copies.
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 3 of
* the License, or any later version.
*
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD
* TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN
* NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL
* DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER
* IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN
* CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* For a full copy of the GNU General Public License see the LICENSE file.
*/

#include <app/common.hpp>
@@ -64,16 +65,25 @@ static const Initializer2& getInitializer2Instance()
return init;
}

class CVCRackUI : public UI
class CardinalUI : public UI
{
ResizeHandle fResizeHandle;
public:
CVCRackUI()
CardinalUI()
: UI(1280, 720),
fResizeHandle(this)
{
using namespace rack;

/*
The following code was based from VCVRack adapters/standalone.cpp

Copyright (C) 2016-2021 VCV

This program is free software: you can redistribute it and/or modify it under the terms of the
GNU General Public License as published by the Free Software Foundation, either version 3 of the
License, or (at your option) any later version.
*/
// Initialize context
INFO("Initializing context");
window::lastUI = this;
@@ -92,7 +102,7 @@ public:
APP->engine->startFallbackThread();
}

~CVCRackUI() override
~CardinalUI() override
{
using namespace rack;

@@ -183,7 +193,7 @@ private:
/**
Set our UI class as non-copyable and add a leak detector just in case.
*/
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CVCRackUI)
DISTRHO_DECLARE_NON_COPYABLE_WITH_LEAK_DETECTOR(CardinalUI)
};

/* ------------------------------------------------------------------------------------------------------------
@@ -192,7 +202,7 @@ private:
UI* createUI()
{
getInitializer2Instance();
return new CVCRackUI();
return new CardinalUI();
}

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

plugins/CVCRack/DistrhoPluginInfo.h → plugins/Cardinal/DistrhoPluginInfo.h View File

@@ -1,10 +1,10 @@
/*
* DISTRHO CVCRack Plugin
* DISTRHO Cardinal Plugin
* Copyright (C) 2021 Filipe Coelho <falktx@falktx.com>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of
* published by the Free Software Foundation; either version 3 of
* the License, or any later version.
*
* This program is distributed in the hope that it will be useful,
@@ -12,15 +12,15 @@
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* For a full copy of the license see the LICENSE file.
* For a full copy of the GNU General Public License see the LICENSE file.
*/

#ifndef DISTRHO_PLUGIN_INFO_H_INCLUDED
#define DISTRHO_PLUGIN_INFO_H_INCLUDED

#define DISTRHO_PLUGIN_BRAND "DISTRHO"
#define DISTRHO_PLUGIN_NAME "CVCRack"
#define DISTRHO_PLUGIN_URI "http://distrho.sf.net/plugins/CVCRack"
#define DISTRHO_PLUGIN_NAME "Cardinal"
#define DISTRHO_PLUGIN_URI "https://distrho.kx.studio/plugins/cardinal"

#define DISTRHO_PLUGIN_HAS_UI 1
#define DISTRHO_PLUGIN_NUM_INPUTS 2

plugins/CVCRack/Makefile → plugins/Cardinal/Makefile View File

@@ -7,16 +7,16 @@
# --------------------------------------------------------------
# Project name, used for binaries

NAME = CVCRack
NAME = Cardinal

# --------------------------------------------------------------
# Files to build (DPF stuff)

FILES_DSP = \
CVCRackPlugin.cpp
CardinalPlugin.cpp

FILES_UI = \
CVCRackUI.cpp \
CardinalUI.cpp \
Window.cpp

# --------------------------------------------------------------

plugins/CVCRack/Rack → plugins/Cardinal/Rack View File


plugins/CVCRack/ResizeHandle.hpp → plugins/Cardinal/ResizeHandle.hpp View File


plugins/CVCRack/Window.cpp → plugins/Cardinal/Window.cpp View File

@@ -72,15 +72,10 @@ struct Window::Internal {

std::string lastWindowTitle;

int lastWindowX = 0;
int lastWindowY = 0;
int lastWindowWidth = 0;
int lastWindowHeight = 0;

int frame = 0;
bool ignoreNextMouseDelta = false;
int frameSwapInterval = -1;
double monitorRefreshRate = 0.0;
double monitorRefreshRate = 60.0; // FIXME
double frameTime = 0.0;
double lastFrameDuration = 0.0;

@@ -131,6 +126,7 @@ Window::Window() {
osdialog_message(OSDIALOG_ERROR, OSDIALOG_OK, "Could not initialize NanoVG. Does your graphics card support OpenGL 2.0 or greater? If so, make sure you have the latest graphics drivers installed.");
exit(1);
}
d_stderr2("framebuffer is %p", fbVg);

// Load default Blendish font
uiFont = loadFont(asset::system("res/fonts/DejaVuSans.ttf"));
@@ -305,7 +301,7 @@ void Window::cursorUnlock() {


bool Window::isCursorLocked() {
return false;
return internal->ignoreNextMouseDelta;
}



plugins/CVCRack/mingw-compat/Shlobj.h → plugins/Cardinal/mingw-compat/Shlobj.h View File


plugins/CVCRack/mingw-compat/Shlwapi.h → plugins/Cardinal/mingw-compat/Shlwapi.h View File


plugins/CVCRack/mingw-compat/Windows.h → plugins/Cardinal/mingw-compat/Windows.h View File


plugins/CVCRack/mingw-compat/condition_variable → plugins/Cardinal/mingw-compat/condition_variable View File


plugins/CVCRack/mingw-compat/mutex → plugins/Cardinal/mingw-compat/mutex View File


plugins/CVCRack/mingw-compat/thread → plugins/Cardinal/mingw-compat/thread View File


plugins/CVCRack/mingw-std-threads → plugins/Cardinal/mingw-std-threads View File


Loading…
Cancel
Save