Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Utility functions for scope, meter, etc. #35

Open
julianrubisch opened this issue Dec 13, 2020 · 2 comments
Open

Utility functions for scope, meter, etc. #35

julianrubisch opened this issue Dec 13, 2020 · 2 comments

Comments

@julianrubisch
Copy link

I don't know if this project takes pull requests, but I've written myself some simple utility functions that could be handy for others too:

(defun jr/sclang-nodetree ()
  "Open scsynth nodeTree."
  (interactive)
  (sclang-eval-string "s.plotTree;"))

(defun jr/sclang-meter ()
  "Open scsynth meter."
  (interactive)
  (sclang-eval-string "s.meter;"))

(defun jr/sclang-scope ()
  "Open scsynth scope."
  (interactive)
  (sclang-eval-string "s.scope;"))

(defun jr/sclang-freqscope ()
  "Open scsynth freqscope."
  (interactive)
  (sclang-eval-string "FreqScope.new;"))

Let me know if that is of interest...

@TatriX
Copy link

TatriX commented Dec 15, 2020

Perhaps a section in README showing that it's trivial to add these features to a personal config would be a nice alternative.

@kflak
Copy link

kflak commented Jul 28, 2024

This is gold, thank you! I'm getting into emacs after years of vimming, and this is exactly the kind of stuff I need...

Here are my contributions:

(defun kf/sclang-japa () 
 "Open Japa. Linux only. Requires japa and the linuxutils quark: 
https://github.com/madskjeldgaard/linuxutils-quark."
  (interactive)
  (sclang-eval-string "Japa.new"))

(defun kf/sclang-record ()
  "Toggle recording. The file name is constructed by the git hash and a 
timestamp, and puts into a directory called rec in the current process directory. 
If the directory does not exist, it will be created."
  (interactive)
  (sclang-eval-expression "if(s.isRecording){s.stopRecording}{s.record(\"rec\"+/+Git(thisProcess.nowExecutingPath.dirname).sha[0..5]++\"_\"++Date.localtime.stamp++\".wav\", numChannels: s.options.numOutputBusChannels)}"))

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants