[Csnd] STK opcodes
Date | 2013-02-20 19:44 |
From | Louis Cohen |
Subject | [Csnd] STK opcodes |
This family of opcodes appears in the manual, but apparently they are not installed in my OSX installation of Csound 5.18. I noticed in an old post that they were not included in some releases. Is there a reason for this? could they be included soon? best, Lou Cohen www.jolc.net www.opensound.org |
Date | 2013-02-22 12:18 |
From | Steven Yi |
Subject | Re: [Csnd] STK opcodes |
Hi Lou, I don't see any particular reason why this couldn't be added. Could you add a bug in the bug tracker? For the interim, I've zipped up my copy of libstk.dylib and put it up at: http://www.kunstmusik.com/libstk.zip It has the stk sources compiled in so shouldn't have any issues with linking. You can try putting it in: /Library/Frameworks/CsoundLib64.framework/Resources/Opcodes64 and (hopefully) should just work there. Thanks! steven On Wed, Feb 20, 2013 at 7:44 PM, Louis Cohen |
Date | 2013-02-22 12:42 |
From | Louis Cohen |
Subject | Re: [Csnd] STK opcodes |
Steven, I will be happy to post the bug, but I've never done this for csound before (only for qtcsound.) The forums provided at http://www.csounds.com/forum/ don't seem to include a forum for bugs. Please advise. Thanks for sending me the stk library libstk.dylib. I installed it as you directed, but apparently something more needs to be done. I used the csd example from the manual (reprinted below) and got the error shown following the csd: |
Date | 2013-02-22 12:58 |
From | Steven Yi |
Subject | Re: [Csnd] STK opcodes |
Hi Lou, There's a link to the bug tracker at the end of emails on the list; it redirects now to: http://sourceforge.net/p/csound/bugs/ I see that you are using the float build of csound. I've recompiled the STK lib and placed it at: http://www.kunstmusik.com/libstk-f.zip Could you try placing it in: /Library/Frameworks/CsoundLib.framework/Resources/Opcodes Thanks! steven On Fri, Feb 22, 2013 at 12:42 PM, Louis Cohen |
Date | 2013-02-22 13:35 |
From | Louis Cohen |
Subject | Re: [Csnd] STK opcodes |
Steven, I have now posted the bug at sourceforge. Sorry I overlooked the ever-present link! Thanks again for the new library which I placed as you directed. Still no luck, however. After restarting qtsound, which seemed prudent, I ran the same csd as before and got the output at the bottom of this email. There is a (smaller) family of opcodes related to the STK opcodes, which IS present in my version of Csound. These are the "wg" opcodes, apparently originating from Perry Cook, author of the STK opcodes, but reprogrammed for csound by John ffitch. Perhaps the STK opcodes are redundant if the wg opcodes are present? I lack enough expert knowledge to know; I've just started to explore these. -Lou WARNING: could not open library '/Library/Frameworks/CsoundLib.framework/Versions/5.2/Resources/Opcodes/libjacko.dylib' (-1) WARNING: could not open library '/Library/Frameworks/CsoundLib.framework/Versions/5.2/Resources/Opcodes/libjackTransport.dylib' (-1) WARNING: could not open library '/Library/Frameworks/CsoundLib.framework/Versions/5.2/Resources/Opcodes/librtjack.dylib' (-1) Csound version 5.18.03 (float samples) Oct 6 2012 Creating options Creating orchestra Creating score Error: define environment variable RAWWAVE_PATH (points to rawwaves directory) to use STK opcodes. using callback interface error: syntax error, unexpected T_IDENT_S, expecting T_OPCODE or ',' (token "STKBowed") line 23: >>>asig STKBowed <<< Parsing failed due to invalid input! Stopping on parser failure On Feb 22, 2013, at 7:58 AM, Steven Yi |
Date | 2013-02-22 15:25 |
From | Michael Gogins |
Subject | Re: [Csnd] STK opcodes |
The STK opcodes (which I wrote) are a complete encapsulation of ALL of Perry Cook's instruments, just as he wrote them in C++, as Csound opcodes. The others you mention are ports to C of some of these by John ffitch (I think by him). I advise you to try them all and use the ones that work best for you. For myself, I use the STK opcodes and the others as well, depending on the sound I want. The RAWWAVE_PATH is an environment variable that must point to a directory where the wavetable files used by STK reside. You need to have these files as well as the library. If you download the STK, you will find these files.
Hope this helps, Mike On Fri, Feb 22, 2013 at 8:35 AM, Louis Cohen <loucohen@jolc.net> wrote: Steven, Michael Gogins Irreducible Productions http://www.michael-gogins.com Michael dot Gogins at gmail dot com |
Date | 2013-02-22 16:20 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] STK opcodes |
Dear Michael, This info is helpful for sure but I am hoping that we can make it easier for Csounders to use this work without all the additional includes, searching, and setup. For instance: It would be nice if....
- the files were distributed with the binaries - if they are needed. It would be nice it the libraries were compiled and distributes - as they are needed
It would be nice if CsoundQt had a line in the Environment Tab - that encouraged one to define a RAWWAVE_Path It would be nice if all these "unique" instructions and needs could be explained in the Manual
- or better, just set up in the builds and included materials with the distributions. Hoping that the next build/release of CsoundQt and Csound includes all this as it does with the other libraries and materials.
-dB (If possible, it would be nice to include Jack too - since we seem to produce many "warnings" when it is not included - all my students think that it is something that they are doing wrong... and me too for that matter. Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 10:25 AM, Michael Gogins <michael.gogins@gmail.com> wrote:
|
Date | 2013-02-22 16:34 |
From | Louis Cohen |
Subject | Re: [Csnd] STK opcodes |
On Feb 22, 2013, at 10:25 AM, Michael Gogins |
Date | 2013-02-22 19:39 |
From | menno |
Subject | [Csnd] Re: STK opcodes |
There are instructions for the STK opcodes in the manual: http://www.csounds.com/manual/html/STKTop.html (I could add the following thing Michael mentioned: The RAWWAVE_PATH is an environment variable that must point to a directory where the wavetable files used by STK reside. You need to have these files as well as the library. If you download the STK, you will find these files.) -- View this message in context: http://csound.1045644.n5.nabble.com/STK-opcodes-tp5720232p5720294.html Sent from the Csound - General mailing list archive at Nabble.com. |
Date | 2013-02-22 19:50 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
Thanks Menno, This is good to see. And any more info/advice/links would be helpful - like how to set up this "path" on a Mac. But....
Why do we have to do so much extra work for these? - especially when other libraries are installed and other samples are included? It would be great if the path was to the included samples folder
It would be great if the dylib was built and distributed with the binaries It would be great if they just "worked" out of the box like all the other Csound opcodes. Especially, when Michael tells me/us that his Windows .exe requires no additional setup and does include all the rawWaves, the path, etc. -dB Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 2:39 PM, menno <nabob_cd@yahoo.com> wrote: There are instructions for the STK opcodes in the manual: |
Date | 2013-02-22 20:25 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
I think the issue may be that STK is its own project / library. Unlike other libraries it also needs resources beyond the headers and the linked library itself (the sound files). The library could be made a requirement for csound, except there are valid reasons to want to build and distribute csound without those opcodes. A path will be, by convention, an environment variable which points to the location of some resource. usually you would put something like RAWWAVE_PATH=/foo/bar/baz # put the actual directory path holding the resources here
export RAWWAVE_PATH in your login preferences file (.bashrc or .profile if you are using bash, which is the default shell with osX) the syntax may vary if you are using a shell other than sh / bash
On Fri, Feb 22, 2013 at 11:50 AM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: Thanks Menno, |
Date | 2013-02-22 20:48 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
Thanks Justin, These instructions should probably be added to the manual. -dB
Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 3:25 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:05 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
This almost worked. On Mac OSX only the ~/.bash_profile is executed when you open a new terminal. So, one needs to put these lines into that file. RAWWAVE_PATH=/Users/dB/Samples/_rawwaves
export RAWWAVE_PATH Also, of note... the manual example does not run from CsoundQt: Csound version 5.19.02 (double samples) Jan 20 2013 Error: define environment variable RAWWAVE_PATH (points to rawwaves directory) to use STK opcodes. using blocking interface error: syntax error, unexpected T_IDENT_S, expecting T_OPCODE or ',' (token "STKBowed") line 19: >>>asig STKBowed <<< Stopping on parser failure It does run from the terminal but with errors: DelayL::setDelay: argument (-9.42112) less than zero! DelayL::setDelay: argument (-9.42128) less than zero!
DelayL::setDelay: argument (-9.42144) less than zero! DelayL::setDelay: argument (-9.42158) less than zero! DelayL::setDelay: argument (-9.42171) less than zero! DelayL::setDelay: argument (-9.42185) less than zero! DelayL::setDelay: argument (-9.42198) less than zero!
DelayL::setDelay: argument (-9.42211) less than zero! DelayL::setDelay: argument (-9.42224) less than zero! DelayL::setDelay: argument (-9.42236) less than zero! DelayL::setDelay: argument (-9.42247) less than zero! DelayL::setDelay: argument (-9.42257) less than zero!
DelayL::setDelay: argument (-9.42268) less than zero! DelayL::setDelay: argument (-9.42279) less than zero! DelayL::setDelay: argument (-9.4229) less than zero! DelayL::setDelay: argument (-9.42298) less than zero! DelayL::setDelay: argument (-9.42307) less than zero! B 0.000 .. 5.000 T 5.000 TT 5.000 M: 1.17329 1.17329 number of samples out of range: 36 36 B 5.000 .. 8.000 T 8.000 TT 8.000 M: 0.54256 0.54256 new alloc for instr 1: B 8.000 .. 11.000 T 11.000 TT 11.000 M: 1.61518 1.61518 number of samples out of range: 2291 2291 B 11.000 .. 12.000 T 12.000 TT 12.000 M: 0.00015 0.00015 Score finished in csoundPerform(). inactive allocs returned to freespace end of score. overall amps: 1.61518 1.61518 overall samples out of range: 2327 2327 0 errors in performance Elapsed time at end of performance: real: 12.293s, CPU: 0.596s 517 2048 sample blks of 32-bit floats written to dac Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 3:25 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:08 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
Using the old parser in CsoundQt gives these errors: Csound version 5.19.02 (double samples) Jan 20 2013 Error: define environment variable RAWWAVE_PATH (points to rawwaves directory) to use STK opcodes. ******************** * USING OLD PARSER * ******************** orch compiler: instr 1 error: illegal character ( ^ error: illegal character ) ^ error: no legal opcodeerror: input arg 'asig' used before defined 4 syntax errors in orchestra. compilation invalid Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 4:05 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: This almost worked. |
Date | 2013-02-22 21:09 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
http://www.joshstaiger.org/archives/2005/07/bash_profile_vs.html .bash_profile is only for new logins (shells that are spawned as a "login shell"). you can force this by running "exec bash -l"
usually, whether a shell in a terminal is a login shell is a configurable option for that terminal On Fri, Feb 22, 2013 at 1:05 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: This almost worked. |
Date | 2013-02-22 21:11 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
notice you still don't have that path defined to see all environment variable settings you can run env if the variable is set you will see it in the output of env
On Fri, Feb 22, 2013 at 1:08 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: Using the old parser in CsoundQt gives these errors: |
Date | 2013-02-22 21:12 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
thanks for the clarification, but it did not work until I looked up this alternative and typed in this alternative... and so, which do you think we should put in the manual for beginners? Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 4:09 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:18 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
thanks for the env command, but hopefully you can appreciate that most MacUsers of Csound don't use the env command much or edit their .bashrc or .profile much or run Csound from the terminal that often. hum....
terminal and env seem to indicate that the path is defined, but CsoundQt does not. dB => env TERM_PROGRAM=Apple_Terminal TERM=xterm-256color
SHELL=/bin/bash TMPDIR=/var/folders/jb/kl2ckq5517ddy8mq7ymjqyb00000gn/T/ Apple_PubSub_Socket_Render=/tmp/launch-i9ayvD/Render TERM_PROGRAM_VERSION=309 TERM_SESSION_ID=C9A0650D-4A7D-4DBD-8B83-4063BB430415
USER=dB COMMAND_MODE=unix2003 SSH_AUTH_SOCK=/tmp/launch-BVWepn/Listeners __CF_USER_TEXT_ENCODING=0x1F5:0:0 Apple_Ubiquity_Message=/tmp/launch-VLRF9l/Apple_Ubiquity_Message
PATH=/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin PWD=/Users/dB LANG=en_US.UTF-8 PS1= dB => RAWWAVE_PATH=/Users/dB/Samples/_rawwaves SHLVL=1 HOME=/Users/dB
LOGNAME=dB _=/usr/bin/env dB => Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 4:11 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:19 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
This is a difficult question. I think environment variables are intrinsically non user friendly nowadays, and most people would expect either a settings panel on a gui, or at least a config file that is specific to the app being run. We had an issue recently at work, where we needed to set up environment variables to control certain functionalities in our development setup. Even with people who are professional programmers there was much confusion and complaint about the inconvenience of specifying things this way.
If you look into the documentation for bash, bash will load .bash_profile on login if it exists, if that does not exist it will load .profile or .login. For all shells it will load .bashrc. if I recall.
On Fri, Feb 22, 2013 at 1:12 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: thanks for the clarification, but it did not work until I looked up this alternative and typed in this alternative... and so, which do you think we should put in the manual for beginners? |
Date | 2013-02-22 21:20 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
environment is not a global config, it inherited from the shell to it's child processes - try "open /path/to/csoundQT" in the shell where that var is defined On Fri, Feb 22, 2013 at 1:18 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: thanks for the env command, but hopefully you can appreciate that most MacUsers of Csound don't use the env command much or edit their .bashrc or .profile much or run Csound from the terminal that often. |
Date | 2013-02-22 21:22 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
Thanks so much for your insight, clarification, and advice - and also for understanding that I am in no way complaining at all here. I will be able to get it to work for sure, but what I am hoping is that we get it to be supported in the CsoundQt interface, or get it to be a default setup that is
part of Csound itself. It just doesn't seem right for all these opcodes to be there (in the manual at least) and then be so complex to set up - at least on some systems. Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 4:19 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:27 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
any c++ program has the ability to set environment variables for itself and for child processes the function in question is setenv, and is found in the library libc, and I am 100% certain csoundqt is already using that library
On Fri, Feb 22, 2013 at 1:22 PM, Dr. Richard Boulanger <rboulanger@berklee.edu> wrote: Thanks so much for your insight, clarification, and advice - and also for understanding that I am in no way complaining at all here. I will be able to get it to work for sure, but what I am hoping |
Date | 2013-02-22 21:30 |
From | Justin Smith |
Subject | Re: [Csnd] Re: STK opcodes |
on further reflection, csound could similarly check for the location of the raw waves at compile time, and if it finds them and the overriding option is not set at run time, insert their expected location into the environment
On Fri, Feb 22, 2013 at 1:27 PM, Justin Smith <noisesmith@gmail.com> wrote:
|
Date | 2013-02-22 21:34 |
From | "Dr. Richard Boulanger" |
Subject | Re: [Csnd] Re: STK opcodes |
one can set all sort of paths in the environment tab of CsoundQt, but not this one. Dr. Richard Boulanger, Ph.D. Professor of Electronic Production and Design Professional Writing and Music Technology Division Office @ 161 Mass Ave - 4th Floor 617-747-2485 (office) 774-488-9166 (cell) http://csounds.com/boulanger http://csounds.com/mathews http://boulangerlabs.com http://csoundforlive.com http://csounds.com On Fri, Feb 22, 2013 at 4:30 PM, Justin Smith <noisesmith@gmail.com> wrote:
|