Renoise Expressions (Redux)

An expression is essentially a small script that behaves much like a mathematical function. You enter parameters and it outputs a value based on variables.
For example you might input things like:
Volume = time; Which would make the volume increase linearly over time.
Pan = math.sin(time); Which would make the panning oscillate over a sinus curve.
Cutoff.Filter1 = 0.5*Gain.Gainer1; Which would set the Cutoff parameter of a filter named Filter1 to half the gain value on Gainer1

It is something that is very common in animation programs such as AfterEffects, Flash and Maya. It is a both simple and powerful tool and it really eases the workflow in most of the programs that use it.
It has been suggested a several times before (Math&Scripts, Renoise Expressions) but it has been a long time since it was last discussed and Renoise have evolved a lot since then. We now have several Meta Devices and LUA support which makes implementing this feature a lot more realistic.

So! I was wondering about what the current climate is for this. I can think of a lot of instances that could be easily done with this that I am not able to do with the metadevices, but I know that for example dBlue can do more with meta devices than I would be able to with expressions, so maybe they are not so useful. But personally I would love them.

Your wish is my command.

  
<?xml version="1.0" encoding="UTF-8"?>  
<filterdeviceclipboard doc_version="0"><br>
  <deviceslot type="FormulaMetaDevice"><br>
    <isactive>true</isactive><br>
  </deviceslot><br>
</filterdeviceclipboard>  
  

Copy & Paste into the Track DSP panel.

Tada!

As Conner_BW is indicating at, the device already exists it just hasn’t been officially released ;)

First thread it was mentioned publicly in dBlue made a blank (init state) preset for it so if you save this you can then load it from the DSP Chains sections of the Disk Op.

http://illformed.org/temp/formula-device.xrnt

For posterity’s sake, this device is the result of our resident madman kRAkEn/gORe.

ヽ(º∀º )ノ

Formula Device mentioned here https://forum.renoise.com/t/if-then-device/32575 as well.

The formula device gets anyone creamy first time hearing about it, then nothing happens as it is too l33t lol.

Well, Jonas, actually I made a FM synth based on dBlue’s tuned ringmod… as a test… it just doesn’t sound that good yet.
http://www.mediafire.com/?5z8t78a8ugen5ev

But be warned, it is really really bad! It’s only a test. I am sooo sorry T^T…
Please some fix it, it is broken, I am not good with FM synths… I don’t even know what it is!

upon first load your .xrns immediately crashed Renoise!

Probably my computer though, this is what the log says:

[details=“Click to view contents”] Application: Loading ‘FM.xrns’…

MIDI: Loading MIDI actions from file ‘C:\Program Files~AUDIO\AUDIO PROGZ\Renoise 2.7.2\Scripts\GlobalMidiActions.lua’…

Osc: Loading OSC actions from file ‘C:\Program Files~AUDIO\AUDIO PROGZ\Renoise 2.7.2\Scripts\GlobalOscActions.lua’…

Player: Constructing…
Player: Creating the slave threads…
Player: Start running…

GUI: Creating the Document GUI…

CrashLog: Handling Exception! Code : C0000005
CrashLog: 00B11EB7: xmlUCSIsCat +48ECD8
CrashLog: 00B1299C: xmlUCSIsCat +48F7BD
CrashLog: 00B12C85: xmlUCSIsCat +48FAA6
CrashLog: 00C01781: xmlUCSIsCat +57E5A2
CrashLog: 00401464: ??? +00000
CrashLog: 008FCADA: xmlUCSIsCat +2798FB
CrashLog: 00AC5811: xmlUCSIsCat +442632
CrashLog: 00926EB5: xmlUCSIsCat +2A3CD6
CrashLog: 0092CA23: xmlUCSIsCat +2A9844
CrashLog: 00C4ED23: xmlUCSIsCat +5CBB44
CrashLog: 00C4AC54: xmlUCSIsCat +5C7A75
CrashLog: 00C4AD86: xmlUCSIsCat +5C7BA7
CrashLog: 00B4E474: xmlUCSIsCat +4CB295
CrashLog: 76C5D0E9: BaseThreadInitThunk +00012
CrashLog: 774116C3: RtlInitializeExceptionChain +00063
CrashLog: 77411696: RtlInitializeExceptionChain +00036

GUI: Successfully constructed

Threads: Timeout while waiting for Thread2 to finish its commands!!

Application: Successfully loaded ‘FM.xrns’.
Application: Caught an unhandled exception (Thread: AUDIO)!
Application: Saving a backup…

Application: Terminating…

DirectSound: Stop Polling…

DirectSound: Timeout while waiting for DirectSound to shut down!!
DirectSound: Releasing Luidsprekers (E-MU 0202 | USB)…

MIDI: Shut down: Closing all acquired MIDI devices…
MIDI: Shutting down DirectMusic…
[/details]

Opening for a second time, does load it up initially, then Renoise dissapears just like that!

Log says:

[details=“Click to view contents”] Application: Loading ‘FM.xrns’…

MIDI: Loading MIDI actions from file ‘C:\Program Files~AUDIO\AUDIO PROGZ\Renoise 2.7.2\Scripts\GlobalMidiActions.lua’…

Osc: Loading OSC actions from file ‘C:\Program Files~AUDIO\AUDIO PROGZ\Renoise 2.7.2\Scripts\GlobalOscActions.lua’…

Player: Constructing…
Player: Creating the slave threads…
Player: Start running…

GUI: Creating the Document GUI…

CrashLog: Handling Exception! Code : C0000005
CrashLog: 00B11EB4: xmlUCSIsCat +48ECD5
CrashLog: 00B1299C: xmlUCSIsCat +48F7BD
CrashLog: 00B12C85: xmlUCSIsCat +48FAA6
CrashLog: 00C01781: xmlUCSIsCat +57E5A2
CrashLog: 00401464: ??? +00000
CrashLog: 008FCADA: xmlUCSIsCat +2798FB
CrashLog: 00AC5811: xmlUCSIsCat +442632
CrashLog: 00926EB5: xmlUCSIsCat +2A3CD6
CrashLog: 0092CA23: xmlUCSIsCat +2A9844
CrashLog: 00C4ED23: xmlUCSIsCat +5CBB44
CrashLog: 00C4AC54: xmlUCSIsCat +5C7A75
CrashLog: 00C4AD86: xmlUCSIsCat +5C7BA7
CrashLog: 00B4E474: xmlUCSIsCat +4CB295
CrashLog: 76C5D0E9: BaseThreadInitThunk +00012
CrashLog: 774116C3: RtlInitializeExceptionChain +00063
CrashLog: 77411696: RtlInitializeExceptionChain +00036

GUI: Successfully constructed

Threads: Timeout while waiting for Thread2 to finish its commands!!

Application: Successfully loaded ‘FM.xrns’.
Application: Caught an unhandled exception (Thread: AUDIO)!
Application: Saving a backup…

Application: Terminating…

DirectSound: Stop Polling…

DirectSound: Timeout while waiting for DirectSound to shut down!!
DirectSound: Releasing Luidsprekers (E-MU 0202 | USB)…

MIDI: Shut down: Closing all acquired MIDI devices…
MIDI: Shutting down DirectMusic…
[/details]

Will post this in the bug forum, would be interesting to know if other users also experience a crash.

(ps: Renoise 2.7.2, windows vista premium, 32 bit, 4 gig ram, core 2 duo)

Yep. Crashes here also. If I manually edit the Song.xml inside the .XRNS and disable the Formula devices, then the song loads normally. Once it’s loaded I can enable the Formula devices and everything is working again.

It’s clearly a bug with the Formula device anyway. We’ll try to look into it.

There’s a reason this device isn’t public yet :)

Crash here too. WinXP SP3.

Something about Unhandled Exception In Thread: Audio" mentioned in status bar.

[details=“Click to view contents”] Application: Loading ‘FM.xrns’…

MIDI: Loading MIDI actions from file ‘C:\Program Files\Renoise 2.7.2\Scripts\GlobalMidiActions.lua’…

Osc: Loading OSC actions from file ‘C:\Program Files\Renoise 2.7.2\Scripts\GlobalOscActions.lua’…

Timer: Seems safe to use the ‘QueryPerformance’ counters…

Player: Constructing…
Player: Creating the slave threads…
Player: Start running…

GUI: Creating the Document GUI…

CrashLog: Handling Exception! Code : C0000005
CrashLog: 00B11EB7: xmlUCSIsCat +48ECD8
CrashLog: 00B1299C: xmlUCSIsCat +48F7BD
CrashLog: 00B12C85: xmlUCSIsCat +48FAA6
CrashLog: 00C01781: xmlUCSIsCat +57E5A2
CrashLog: 00401464: ??? +00000
CrashLog: 008FCADA: xmlUCSIsCat +2798FB
CrashLog: 00AC5811: xmlUCSIsCat +442632
CrashLog: 00926EB5: xmlUCSIsCat +2A3CD6
CrashLog: 0092CA23: xmlUCSIsCat +2A9844
CrashLog: 00C4ED23: xmlUCSIsCat +5CBB44
CrashLog: 00C4AC54: xmlUCSIsCat +5C7A75
CrashLog: 00C4AD86: xmlUCSIsCat +5C7BA7
CrashLog: 00B4E474: xmlUCSIsCat +4CB295
CrashLog: 7C80B713: GetModuleFileNameA +001B4

Application: Caught an unhandled exception (Thread: AUDIO)!
Application: Saving a backup…

GUI: Successfully constructed

Application: Successfully loaded ‘FM.xrns’.

GraphPort: Initializing in WindowedMode
GraphPort: Successfully initialized

Application: Init OK
Application: Enter MainLoop…

Application: Terminating…

DirectSound: Stop Polling…

DirectSound: Timeout while waiting for DirectSound to shut down!!
DirectSound: Releasing Primary Sound Device…
DirectSound: Releasing Realtek HDA Primary input…

MIDI: Shut down: Closing all acquired MIDI devices…
MIDI: Shutting down DirectMusic…

[/details]