[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

RE: [sc-users] problem with /note argument in Pbindef



Thanks for the reply and for sorting it out. Embarassing mistake. Now I see that I have actually not used the /note argument prior to this incident but instead

/freq togheter with `+ (4*12).midicps. Glad to learn how to do it another way.

Thank you!

 

Sent from Mail for Windows 10

 

From: jamshark70@xxxxxxxxx
Sent: Saturday, 28 December 2019 01:55
To: sc-users
Subject: Re: [sc-users] problem with /note argument in Pbindef

 

On Sat, Dec 28, 2019 at 7:56 AM <nilswallgren@xxxxxxxxxxx> wrote:
> Can’t figure out why this wont work:
> (
>         \note, Pseq(([
>                 12,11,9,12,
>                 9,7,5,4,
>                 5,7,11,12
> ]+(4*12)).midicps,inf),
>
> I want to define the notes as “note” and transpose them. Not sure what is happening here. Just hearing some low initial tick.

\note represents a step along a chromatic gamut (n-step equal temperament).

note == 0 is, with default settings, middle C. That is, by default,
octave == 5 -- and note == 0 translates to midinote = note + (octave *
stepsPerOctave) = 60 (in 12ET). There are actually more variables in
play, but the point is, you don't need to transpose \note by octaves
-- so where you wrote `+ (4*12)`, this will actually put your notes in
octave 9. Pretty sure that isn't what you wanted.

note is *not* a frequency! So you should definitely not supply cps
here -- .midicps is not correct.

So what is happening is that you are starting with reasonable note
values, then transposing them up a few octaves so that they are rather
high, then converting these to cps which makes the numbers even
higher. *Then* the normal event conversions add (octave *
stepsPerOctave) for midinote, and do *another* midicps for \freq.

(note: (12 + (4*12)).midicps).play;

-> ( 'instrument': default, 'msgFunc': a Function, 'amp': 0.1,
'server': localhost,
  'note': 261.6255653006, 'sustain': 0.8, 'freq': 956699202.80129,
'hasGate': true, 'isPlaying': true,
  'id': [ 1002 ] )

'freq': 956699202.80129 -- again, I'm pretty sure that a billion
cycles per second isn't what you wanted.

http://doc.sccode.org/Tutorials/A-Practical-Guide/PG_07_Value_Conversions.html

The keys discussed in this document are not free for you to use any
way that you like. \note simply isn't in Hz.

hjh

_______________________________________________
sc-users mailing list

info (subscription, etc.): http://www.birmingham.ac.uk/facilities/ea-studios/research/supercollider/mailinglist.aspx
archive: https://listarc.bham.ac.uk/marchives/sc-users/
search: https://listarc.bham.ac.uk/lists/sc-users/search/