[.uhm] FM Synthesis in Hive
-
- KVRian
- 1461 posts since 26 Jun, 2002 from London, UK
Double post....sorry
Wavetables for DUNE2/3, Blofeld, IL Harmor, Hive and Serum etc: http://charlesdickens.neocities.org/
£10 for lifetime updates including wavetable editor for Windows.
Music: https://soundcloud.com/markholt
£10 for lifetime updates including wavetable editor for Windows.
Music: https://soundcloud.com/markholt
- KVRAF
- 4123 posts since 23 May, 2004 from Bad Vilbel, Germany
This particular thread is about scripting… no 'cheating' herecytospur wrote:If anyone wants to 'cheat' then there are wavetables available here:
- KVRAF
- 4123 posts since 23 May, 2004 from Bad Vilbel, Germany
drzhnn wrote:...practice until it clicks...
I distracted my reasonable self with a banana, while my rebellious self committed an impulse buy. Now I have to continue learning, otherwise I will blame myself for spending money on something that I won't use.
That tubular bell is great. Checked it out although I'm on the road -> Berlin!
Last edited by Howard on Tue Sep 25, 2018 9:04 am, edited 1 time in total.
-
- KVRian
- 1461 posts since 26 Jun, 2002 from London, UK
It was a joke. I think the scripting approach is brilliant and inspired. 'Fantastic' as I said in my first sentence of the post that you part quotedHoward wrote:This particular thread is about scripting… no 'cheating' herecytospur wrote:If anyone wants to 'cheat' then there are wavetables available here:
Wavetables for DUNE2/3, Blofeld, IL Harmor, Hive and Serum etc: http://charlesdickens.neocities.org/
£10 for lifetime updates including wavetable editor for Windows.
Music: https://soundcloud.com/markholt
£10 for lifetime updates including wavetable editor for Windows.
Music: https://soundcloud.com/markholt
- u-he
- Topic Starter
- 28065 posts since 8 Aug, 2002 from Berlin
The additive approach to sawtooth isdrzhnn wrote:I tried but the way I see it I need to create a sin(2*pi*phase*harmonic + x/harmonic) line for each harmonic, and there're 1024 harmonics... I tested up to 100 and it still wasn't saw-ish enough
sin(2*pi*phase*harmonic)/harmonic, starting with harmonic = 1
The easiest way to do this in Hive is
Spectrum "1/index", because index is the same as harmonic in the Spectrum function
Anyhow, the appraoch I posted above (using lowpass) is very effective in simulating FM feedback sawteeth.
#---
I totally agree that the workflow is tedious. But I also think it's surprisingly fast to get to good results compared to visual methods. Because every line is a batch process, it turns tedious frame-by-frame editing into a possibly strenuous one-time thought process. I think the "strenuousness" of this thought process will be countered by lists of numerous examples which people can easily copy and paste in to their own scripts.
#---
We might also need to explain some basic concepts a bit more visually, e.g. what exactly happens during the process of a Wave/Spectrum/Phase command.
- u-he
- Topic Starter
- 28065 posts since 8 Aug, 2002 from Berlin
I hardly switch between apps... I load the script I'm going to edit into Hive, put wavetable on auto and spend the rest of my time in the text editor. Whenever I save the changes to the text file, Hive automatically loads it in the background, and I keep playing away on the keyboard.hakey wrote:Same here. Any chance of a standalone .uhm/wavetable editor?drzhnn wrote: I was exhausted by switching between Hive, text editor
Thats aid, a standalone wavetable editor would be a great thing, but we won't be able to pull that off.
- KVRAF
- 4123 posts since 23 May, 2004 from Bad Vilbel, Germany
Tips: Use a simple host (e.g. Ju-X AUhosting), display Hive AND the text editor at the same time, "split screen". Click to switch focus, don't use cmd+tab (or whatever the equivalent is in the PC world).hakey wrote:Same here. Any chance of a standalone .uhm/wavetable editor?drzhnn wrote: I was exhausted by switching between Hive, text editor
As Urs says, unless you're building a preset you can just save (if necessary) and play most of the time, especially if you use the "Auto" scan in your testbed preset.
- KVRAF
- 5234 posts since 25 Feb, 2008
btw, for anyone using Notepad, scripts need to be saved with quotation marks - wavetable.uhm should be saved as "wavetable.uhm". Otherwise Notepad adds an invisible .txt extension.
Had me scratching my head for a while.
Had me scratching my head for a while.
- KVRist
- 429 posts since 4 Jun, 2018 from The UK
On Windows, I suggest you use Notepad++ instead of Notepad (it's what I've been using). Notepad can cause issues when scripting, such as adding hidden characters, and switching symbols like " to quotations, and not saving extensions (like you mentioned).hakey wrote:btw, for anyone using Notepad, scripts need to be saved with quotation marks - wavetable.uhm should be saved as "wavetable.uhm". Otherwise Notepad adds an invisible .txt extension.
Had me scratching my head for a while.
- u-he
- Topic Starter
- 28065 posts since 8 Aug, 2002 from Berlin
Back in the days (before I replaced myself with Windows-savvy developers) I think it was Ultraedit for me. But I also think the different licensing models were a mess. Not sure if there's a slim & free version.
- KVRian
- 544 posts since 1 Jan, 2013 from Saint-Petersburg, Russia
I not sure I understand the y variable. Is it a value of a sample at [current_index - 1] in -1.0 to 1.0 range?Urs wrote:We might also need to explain some basic concepts a bit more visually, e.g. what exactly happens during the process of a Wave/Spectrum/Phase command.
- u-he
- Topic Starter
- 28065 posts since 8 Aug, 2002 from Berlin
Almost...drzhnn wrote:I not sure I understand the y variable. Is it a value of a sample at [current_index - 1] in -1.0 to 1.0 range?Urs wrote:We might also need to explain some basic concepts a bit more visually, e.g. what exactly happens during the process of a Wave/Spectrum/Phase command.
The samples are not necessarily in -1/+1 range. You can do whatever range you want, but Hive automatically adjusts the RMS to fit the sawtooth (we think it's a bit low though, so we'll boost it a bit in the final version)
When I say almost, I mean that the values of the current frame are stored in a temporary buffer, then blended into the target buffer using the blend mode. Such that, in almost C, vastly simplified,
Code: Select all
Wave blend=multiply "sin(2*pi*phase + y) + x"
Code: Select all
for( frame = start; frame <= end; frame++ )
{
table = (frame-start)/(end-start);
// Pass 1: run equation on frame
for( index = 0; index < 2048; index++ )
{
y = tmp[ index - 1 ];
x = main[ frame ][ index ];
phase=index/2048;
tmp[ index ] = sin(2*pi*phase + y) + x;
}
// Pass 2: blend frame into buffer
for( index = 0; index < 2048; index++ )
{
main[ frame ][ index ] = doBlend(tmp[ index ], main[ frame ][ index ], multiply );
}
}