Csound Csound-dev Csound-tekno Search About

[Csnd] GEN51 vs GEN2

Date2022-11-09 00:30
FromSUBSCRIBE CSOUND Anonymous <00000c641a512f08-dmarc-request@LISTSERV.HEANET.IE>
Subject[Csnd] GEN51 vs GEN2
Hi all,

I want to join everybody saying thank you Shane and everyone for this year incredible conference!

Just wanted to ask also..
What's the difference between GEN51 and GEN2? Is GEN51 deprecated?
I mean, in the cpstun family opcode both are shown, but I cannot figure out what changes.
When I try to use it for a tuning system Csound says "ftable 151: deferred size for GENs 1, 2, 23, 28 or 49 only"
Thank you!

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2022-11-09 08:12
From"Jeanette C."
SubjectRe: [Csnd] GEN51 vs GEN2
Nov 9 2022, SUBSCRIBE CSOUND Anonymous has written:
...
> What's the difference between GEN51 and GEN2? Is GEN51 deprecated?
...
These two generators have quite a different purpose. GEN02 is a very
simple generator, just taking values that you give it, either during
creation or later on. It does not do anything with them. So:
iList = ftgen(0, 0, 4, -2, 1, -2, 3, -4)
will fill iList with the values 1, -2, 3 and -4.

GEN51, however, takes the input parameters as controls to create a
microtuning scale, which a few Csound opcodes can use (cpstun, cpstuni,
cpstmid). So it's specific to those, though you can still use it in
other custom areas. If you plan to use it with MIDI you'd set a size of
128, because there are 128 MIDI notes (from 0 to 127). With bassfreq and
basskey you can specify one reference point. Say you want A440 on MIDI
key 69. You can use this value to "transpose" your tuning.

So you see, those two table generators are completely different beasts.
GEN51 actually calculates values for you. Be sure to use -51 as the
gen number when creating a tuning table. That means that values you give
it will not be rescale to a range between 0 and 1. It's one of those
things. It might not be necessary in the very latest versions anymore.

Best wishes,

Jeanette


-- 
  * Website: http://juliencoder.de - for summer is a state of sound
  * Youtube: https://www.youtube.com/channel/UCMS4rfGrTwz8W7jhC1Jnv7g
  * Audiobombs: https://www.audiobombs.com/users/jeanette_c
  * GitHub: https://github.com/jeanette-c

When you need someone, you just turn around and I will be there <3
(Britney Spears)

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here

Date2022-11-09 10:14
FromDave Seidel
SubjectRe: [Csnd] GEN51 vs GEN2
Jeanette is correct and eloquent as usual. :I use GEN51 (-51) in almost all of my pieces.

- Dave 

On Wed, Nov 9, 2022 at 3:14 AM Jeanette C. <julien@mail.upb.de> wrote:
Nov 9 2022, SUBSCRIBE CSOUND Anonymous has written:
...
> What's the difference between GEN51 and GEN2? Is GEN51 deprecated?
...
These two generators have quite a different purpose. GEN02 is a very
simple generator, just taking values that you give it, either during
creation or later on. It does not do anything with them. So:
iList = ftgen(0, 0, 4, -2, 1, -2, 3, -4)
will fill iList with the values 1, -2, 3 and -4.

GEN51, however, takes the input parameters as controls to create a
microtuning scale, which a few Csound opcodes can use (cpstun, cpstuni,
cpstmid). So it's specific to those, though you can still use it in
other custom areas. If you plan to use it with MIDI you'd set a size of
128, because there are 128 MIDI notes (from 0 to 127). With bassfreq and
basskey you can specify one reference point. Say you want A440 on MIDI
key 69. You can use this value to "transpose" your tuning.

So you see, those two table generators are completely different beasts.
GEN51 actually calculates values for you. Be sure to use -51 as the
gen number when creating a tuning table. That means that values you give
it will not be rescale to a range between 0 and 1. It's one of those
things. It might not be necessary in the very latest versions anymore.

Best wishes,

Jeanette


--
  * Website: http://juliencoder.de - for summer is a state of sound
  * Youtube: https://www.youtube.com/channel/UCMS4rfGrTwz8W7jhC1Jnv7g
  * Audiobombs: https://www.audiobombs.com/users/jeanette_c
  * GitHub: https://github.com/jeanette-c

When you need someone, you just turn around and I will be there <3
(Britney Spears)

Csound mailing list
Csound@listserv.heanet.ie
https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND
Send bugs reports to
        https://github.com/csound/csound/issues
Discussions of bugs and features can be posted here
Csound mailing list Csound@listserv.heanet.ie https://listserv.heanet.ie/cgi-bin/wa?A0=CSOUND Send bugs reports to https://github.com/csound/csound/issues Discussions of bugs and features can be posted here