I wrote a serum random fm wavetable generator in C++

Started by danaadalaide
Avatar for danaadalaide

danaadalaide

It generates valid serum wavetable wav files (i just copied the header from an existing wavetable, the only way i could make it work)

https://pastebin.com/V7Ctd0Fe

If you want to use it semi-easily, just get the trial of clion and paste it in and run it

Avatar for darrenrichards

darrenrichards

Thank you so much for sharing. Worked like a charm on my Mac and the wavetable loaded into Serum 2.

% c++ random_wt.cpp -o random_wt
% ./random_wt
Attempt 1
Attempt 2
Attempt 3
Attempt 4
Attempt 5
Attempt 6
Attempt 7
Attempt 8
Attempt 9
Attempt 10
Attempt 11
Attempt 12
Attempt 13
Attempt 14
Attempt 15
Attempt 16
Attempt 17
Attempt 18
Attempt 19
Attempt 20
Attempt 21
Random, non-repeating, non-noisy wavetable created: random_wavetable.wav
Generated in 21 attempts.

Avatar for danaadalaide

danaadalaide

I'm glad you like it, i had planned to make an app with drag and drop but too busy with other things right now

Avatar for whitecat13

whitecat13

didn't work for me in CLion and Visual Studio Community 2022

its an interesting idea nevertheless.

hope you will have some free time in the near future to do a simple app with drag & drop

Avatar for flleeppyy

flleeppyy

Any chance this could be posted on Github?

Avatar for flleeppyy

flleeppyy

also for anyone trying to build using visual studio, you need these in your includes

#define _USE_MATH_DEFINES
#include <numeric>
#include <iostream>
#include <vector>
#include <cmath>
#include <fstream>
#include <algorithm>
#include <random> // For random number generation
#include <cstdint> // For fixed-size integer types
#include <tuple>
#include <string>
#include <sstream>
Avatar for flleeppyy

flleeppyy

If i wanted to import this into Vital, what would the window size be for the outputs? both the old main and new main outputs