Seeking Guidance on Creating Relative Paths to Max for Live Devices via node.script

tiago morais morgado's icon

tiago morais morgado

8月 30 2023 | 11:18 午前

Subject: Seeking Guidance on Creating Relative Paths to Max for Live Devices via node.script

Hello Max/MSP Community,

I hope this message finds you well. I am currently working on a project involving Max for Live devices and the node.script API. I'm in search of some insights and guidance from fellow enthusiasts who might have experience with this particular combination.

My challenge revolves around creating a relative path to a Max for Live device within the context of node.script. I am aware that the path needs to be constructed in a way that accommodates different installations and locations. While I'm familiar with relative paths in other contexts, I'm keen to understand how this can be achieved effectively within the Max for Live and node.script ecosystem.

If anyone has successfully tackled this task or possesses knowledge about creating relative paths to Max for Live devices via node.script, I would greatly appreciate your expertise. Any advice, code snippets, or pointers to resources would be incredibly valuable as I work towards a solution.

Feel free to reply here, or you can reach me directly through private messages or email at [Your Contact Information]. Your contribution will not only aid me but also benefit others in the community who might be facing a similar challenge.

Thank you for your time and consideration. Looking forward to learning from your experiences!

Best regards, Tiago Morais Morgado

you can find the code here
https://bpa.st/LXCHY

Florian Demmer's icon

Florian Demmer

9月 01 2023 | 9:12 午前

Hi Tiago,

have you looked at this document that explains some details of how to use node.script with project and Max for Live Devices?

tiago morais morgado's icon

tiago morais morgado

9月 03 2023 | 10:02 午前

hey florian

i did it. here is some relevant info:

// my project structure
- https://hastebin.com/share/liwolujeni.bash

// my bash script for renaming projects
- https://hastebin.com/share/olavupecex.bash

// my javsacript file for setting up random cues
- https://hastebin.com/share/nujivotosa.javascript

Max Patch
Copy patch and select New From Clipboard in Max.

so basically what i did:
- gave all my samples unique names using a bash script (a lot of files, so didn't do that manually);
- changed that in the node.script file;
- added the path of the project to the maxmsp system path