New Tool (3.0): Vsti From Menu

When I try it install the plugin causes and endless loop, until a termination dialogue appears.

The tool still works after termination, Load VSTi and Load AU menu are filled.

After termination:

'/Users/Ju/Library/Preferences/Renoise/V3.0.1/Scripts/Tools/ledger.scripts.VstiFromMenu.xrnx/main.lua' failed in one of its notifiers.
The notifier will be disabled to prevent further errors.

Please contact the author (Ledger) for assistance...

Script execution terminated by user.
stack traceback:
  main.lua:316: in function <main.lua:152>

second time:

'/Users/Ju/Library/Preferences/Renoise/V3.0.1/Scripts/Tools/ledger.scripts.VstiFromMenu.xrnx/main.lua' failed in one of its notifiers.
The notifier will be disabled to prevent further errors.

Please contact the author (Ledger) for assistance...

main.lua:260: Script execution terminated by user.
stack traceback:
  [string "do..."]:37: in function <[string "do..."]:35>
  main.lua:260: in function <main.lua:152>

thanks for report, will take a look

Some more observations:

  • If I remove the vst if- part of the type detection loop, it will the CPU usage will still go up with a huge pause, but the detection will pass.

  • if I print the vst names, I can see that it terminated always after last vst.

  • native detection should look for “native/” instead “native”, since some vst have “native” in their name,

  • don’t understand when this detection is triggered, maybe that’s the problem, so it called a million times? Why is it observable, because of the possibility to rescan plugins? Maybe there is a system observable?

EDIT:

  • Or is it some recursion problem, so if the observable is triggered if the plugin list changes and the detection function itself changes the plugin list, it would be called in some evil recursion. I guess I simply do not understand how the function is triggered…

Thanks for the further info. I`ve had a quick look here but this is could be quite difficult to troubleshoot at this end.

The observable is triggered on a new document (renoise song being loaded in). This is to prevent the tool trying to access the song variables before they exist. i.e. on loading renoise for the first time.

Could you run the script linked here from an earlier post and upload the .txt? These bugs seem to be naming issues, this way I can have a look at it. I`ll look at the native issue you mention too.

https://forum.renoise.com/t/new-tool-3-0-vsti-from-menu/31023

Man, I isolated the problem, it has nothing to do with the number of plugins.

The problem is this call:

renoise.tool():has_menu_entry(menu_roots[root]..menu_entry)

It seems to be very, very slow.

See post below!

I also littledisimproved youradd_vsts_to_mixer() function:

[SPOILER]

function add_vsts_to_mixer()
local rns_track_device_infos = renoise.song().tracks[1].available_device_infos

local plug_type = {}
local VSTs = 1
local no_of_vsts = #rns_track_device_infos

local hidden_plugs = {"*Formula Device",
                "*MIDI-CC Device",
              --"Distortion",
              --"Filter",
                "Filter 2",
              --"Gate",
              --"LofiMat",
                "MasterTrackVolPan",
              --"mpReverb",
                "SendTrackVolPan",
                "Shaper",
                "Stutter",
                "TrackVolPan"
                }
                                                
                
--get fx plugin names and add to table "plugins"
for VSTs = 1,no_of_vsts do
local vpath = rns_track_device_infos[VSTs].path;
  --routing
  if string.find(vpath , "/#",1, true ) then
    plug_type[VSTs] = "Routing"
  --meta
  elseif string.find(vpath , "/*", 1, true) then
    plug_type[VSTs] = "Meta" 
  --native is last as all renoise fx have native in path
  elseif string.find(vpath , "Native/") then
    plug_type[VSTs] = "Native"
   -- remove hidden/ compatability plugs
   for i = 1,#rns_track_device_infos[VSTs].short_name do
      if rns_track_device_infos[VSTs].short_name == hidden_plugs[i] then
        plug_type[VSTs] = "Void"
        break
      end
    end
 
  --Plugins
  elseif string.find(vpath , "VST/") then
    plug_type[VSTs] = "VST" 
    
  elseif string.find(vpath , "DSSI/") then
    plug_type[VSTs] = "DSSI"

  elseif string.find(vpath ,"AU/") then
    plug_type[VSTs] = "AU"
  end
  
end--for

[/SPOILER]

I think to fix the problem, we need some menu object cache to be used instead.

EDIT:

No, I think this is a OSX? / gui renoise only problem, the same as reported here:

https://forum.renoise.com/t/osx-gui-slows-down-on-renoise-app-show-status-calls/43129

So if you add an entry to a gui menu, renoise osx will immediately redraw the whole gui without any reason (since next screen frame is still far away). So if I have 1000 plugins installed, the OSX renoise gui will be redrawn on every single

renoise.tool():add_menu_entry()

call… In this example, like 5000 ? times or more. Within one frame tick.

Really hope the Taktik will fix this with the 3.1 update!

Really hope the Taktik will fix this with the 3.1 update!

And there`s the sentence that causes me a huge sigh of relief (sorry taktik!) :slight_smile:

I`ll take a look at your function improvement too, I guess its a bit of a speed up?

EDIT: I don’t know… all rubbish I wrote above.

the function

renoise.tool():add_menu_entry()

seems to be extremely slow.hmā reported above and obviously uses windows, so it’s maybe just so slow on every system.

I`ll take a look at your function improvement too, I guess its a bit of a speed up?

I have no clue about LUA, it’s only matching for path separator, “/”, too, for more exact matching. also it seems that luau’s string.find() function supports regular expressions? So a / or # or * might be problematic I thought. Or just needs a interpolation \ ? Dunno…

https://forum.renoise.com/t/new-tool-3-0-vsti-from-menu/31023

New beta: version 1.4

–Search improved so matches are found alphabetically and so if you type imf as the first letter, plugins beginning with f will be the first to appear. Before it could occur that a plugin containing a different starting letter but had f appearing later in its name, would appear first.

–Jureks / modification added to categorisation definitions.

v1.5 Lock Keyboard Focus state should now not be changed by the tool

1.5 In first post with quoted fix:

https://forum.renoise.com/t/new-tool-3-0-vsti-from-menu/31023

Not sure I’m getting this tool entirely. I can launch an effect/instrument search box with the key commands but can’t see where the load via right click menu’s are located. Am I missing something? Also what does the “Ed.” tickbock do?

For effects the right click menus are called from the DSP lane or the mixer ~Load Vst fx ~Load Native fx. For plugin instruments right click in the instrument list.

The “Ed” tick box means the editor will open automatically on loading if there is one. i.e. an AU or VST plugin with its own GUI. This setting doesnt do anything when renoise native effects are loaded.

Yeah looks like all it needed was a restart to show up. Great tool!

Ah, yes it requires a new song to fire the notifier. I will add that to the first post.

edit: done and v1.5 gone official on the tools page:

https://www.renoise.com/tools/vsti-from-menu

.My previous posting about an error being thrown on startup (and having to terminate the script) still stands - but the workaround is to reply ‘NO’ to terminate … I do this 4 or five times and then Renoise continue to load and your Tool then works fine.

Back to square one on loading Renoise again though.

So I think maybe the time-out needs to be extended somehow. I’ve got tons of plugs.

Cheers

Thal

It’s a Renoise internal problem…

RE: Script Timeouts on scanning

It can be worked around with a process slicer. I did have some problems with crashes before when using, but I think this has been fixed in a recent renoise release.

I can take a look at it sometime.

Would be great, yeah. Superb tool but just a bit of a killer on starting Renoise (for me) :slight_smile:

This is still one of the most useful tools in the box.

A thought; If I load a native DSP via the tool (such as the Send device) it might be useful if the DSP panel opened and showed the Send device if the ‘Ed’ box is checked.

All the best

Thal

Could make sense,

maybe for next update, not sure when though…