Don't see any way to pass sclang options
ivxvm opened this issue · 5 comments
I found a way to specify scsynth executable path, but I don't see a similar way to specify sclang path.
Get the following error when trying to run the very first example from docs:
Error: spawn C:\Program Files (x86)\SuperCollider\sclang.exe ENOENT
at Process.ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:478:16)
at processTicksAndRejections (node:internal/process/task_queues:83:21) {
errno: -4058,
code: 'ENOENT',
syscall: 'spawn C:\\Program Files (x86)\\SuperCollider\\sclang.exe',
path: 'C:\\Program Files (x86)\\SuperCollider\\sclang.exe',
spawnargs: [
'-i',
...
PS: Sure I have SC installed, but I have x64 version and it's located in different folder, so I need a way to provide executable path
running into this as well
Hello, really sorry everyone for the late response.
The documentation does have broken links and I didn't manage to get it to link all the options arguments correctly.
Language interpreter
https://crucialfelix.github.io/supercolliderjs/#/packages/lang/SCLang
The options are:
supercolliderjs/packages/lang/src/options.ts
Lines 19 to 33 in 2e7c2b4
sclang
option is the path to the sclang executable.
default options are:
supercolliderjs/packages/lang/src/options.ts
Lines 63 to 100 in 2e7c2b4
audio Server
https://crucialfelix.github.io/supercolliderjs/#/packages/server/Server
The scsynth
option in the path to scsynth executable:
https://github.com/crucialfelix/supercolliderjs/blob/develop/packages/server/src/options.ts#L90-L136
You pass the options in
new SCLang(options: SCLangArgs)
// or I think:
sc.lang.boot({ sclang: 'path/to/sclang' }).then(async function(lang) {
});
thx! Got it working.
The option seems to be ignored. I boot with:
const sc = require("supercolliderjs");
sc.server.boot({
scsynth: '/Applications/SuperCollider.app/Contents/Resources/scsynth',
sclang: '/Applications/SuperCollider.app/Contents/MacOS/sclang'
}).then(async server => {
but it still fails with the error:
Error: spawn /Applications/SuperCollider/SuperCollider.app/Contents/MacOS/sclang ENOENT
at ChildProcess._handle.onexit (node:internal/child_process:283:19)
at onErrorNT (node:internal/child_process:476:16)
at process.processTicksAndRejections (node:internal/process/task_queues:82:21)
Notice that it tries to open /Application**/SuperCollider/**SuperCollider.app/ despite me explicitly passing the correct path in the boot options.
By the way, the path I'm passing (without the nested SuperCollider
folder inside /Applications
) seems to be the default when installing SuperCollider now