-
-
Notifications
You must be signed in to change notification settings - Fork 26
Dev FAQ for VCV Rack
Questions are sorted from just starting out up to sharing your modules.
-
You need to get Rack build first before you can start building modules in the
plugins
dir. So see questions below. -
Clone the tutorial module into
Rack/plugins
Read the README.md. I would keep modifying the Tutorial Module until I had something I liked. This is easier than starting from scratch. -
Build your modules and create a new release on github. Try to build for the three main architectures, mac, windows, and linux. If you don't have access to all of those, ask for help, and somebody will do it for you.
-
Add your manifest file here when you are ready to release. (Then users can add your plugin on https://vcvrack.com and hit refresh plugins in rack)
-
I highly recommend these YouTube C++ Tutorials by EA developer Yan Chernikov "The Cherno"
-
Also this one page cheatsheet Learn C++ in X Minutes
-
You are going to want a good text editor and be comfortable in a terminal. These are purely a preference and you can pick whatever works for you. Sublime Text 3, iterm2, and VS Code are good tools.
-
Here are some good posts about Making Audio Plugins by Martin Finke. These can be used as a C++/DSP reference.
-
Here is another nice blog with visuals and detailed explanations: Lucid Mesh
-
You might also be interested in Vult which can generate high performance DSP Code.
Watch this video tutorial by Leonardo Laguna Ruiz
Watch this video tutorial by Leonardo Laguna Ruiz
You will need gcc, make, cmake, tar, unzip, and maybe more. Personally I had to install more packages than the Rack README.md says. So if you run into an error look for a package name, google it, and install it with apt-get.
NOTE: glibc 2.23 is required to run Rack binaries
Here is a good distro.
For Ubuntu based distributions you need to install these as well: libx11-dev libgl1-mesa-dev libxrandr-dev libxcursor-dev libxinerama-dev zlib1g-dev libasound-dev g++ libglu1-mesa-dev libgtk2.0-dev
.
The values at inputs[MY_INPUT].value
and outputs[MY_OUTPUT].value
are simply numbers which act like voltages in a hardware system.
1HP == 15px
3U == 380px
#define RACK_GRID_WIDTH 15
#define RACK_GRID_HEIGHT 380
inputs[MY_INPUT].active
outputs[MY_OUTPUT].active
- Inkscape is a free and open source alternative. Works perfect on Linux and Windows, in Mac it does not feel native.
- Gravit Designer is another free editor that can be used online or on Mac/Win/Linux.
- Affinity Designer it's a very affordable (around $50) alternative comparable to Illustrator. It works perfect on Mac and Windows. See how to export for VCV below.
File > Import. Then right click the image and click Trace Bitmap. Then play with the settings until you get the level of detail you want.
Text needs to be converted to paths in SVG.
From Michael Hetrick: "...Use Export As... instead of Save As... Then use the following settings: Inline Style, Convert to Outlines, Embed, Layer Name, 5. Disable Minify and Responsive. If that doesn't work for you, start with just MyModule.svg (the one in the tutorial repo) re-export it to verify that at least the basic file works. After that, add in your elements one by one and export each time until you figure out which element is broken."
Use File->Export
select SVG
and click in More
to define the following settings: Export Text as Curves
active, Use relative coordinates
active, and disable Set Viewbox
. Save this preset for future use.
Here is a gist by Andrew Belt
make debug
This starts GDB
If VERSION is defined in your Makefile
like the Tutorial:
make dist
If VERSION is not defined in your Makefile
like the old Tutorial:
make dist VERSION=0.5.0
This will make a zip file here dist/MyPlugin-0.5.0-myarch.zip
The name is based on the value inside the Makefile
Download this gist and run this:
./zipmerge.sh MyPlugin-0.5.0.zip MyPlugin-0.5.0-*.zip
zip -d MyPlugin-0.5.0-myarch.zip __MACOSX/*
zip -d MyPlugin-0.5.0-myarch.zip */.DS_Store
touch LICENSE
...and at some point choose a license
-
Don't change the module slug. Only the name should be changed. If you change the slug, existing patches with your module will break.
-
Don't change the order of the parameters. Existing patches will be affected.
-
Update your manifest file here
For example:
- Copy Tutorial to TutorialBlanks
- Change the slug in the new folder from
Tutorial
toTutorialBlanks
(Don't change the manufacturer) - Keep the builds separate. (Don't want to accidentally push closed source code)
https://github.com/VCVRack/Rack/issues
https://github.com/VCVRack/Rack/issues/258
Error
': not a valid identifierline 89: export: `dashless
Run this:
mv /mingw64/bin/envsubst.exe /mingw64/bin/envsubst.exe.old
then install:
pacman -S gettext
Thanks to Iūstus Henryson's post here https://www.facebook.com/groups/vcvrack/permalink/138808273445992/
Passing -lfoobar
to the compiler will prefer linking against the dynamic version of a library. To link against a static version of a library pass the full path to the static version, e.g. /usr/local/Cellar/libusb/1.0.21/lib/libusb-1.0.a
. If using a package that supports pkg-config
, this make snippet might be helpful for determining the full path to a static library.
LDFLAGS +=$(shell pkg-config --variable=libdir libusb-1.0)/libusb-1.0.a