Dear All,
(win32 version only):
There was a bug in the type checker where it would crash
on calling functions in namespaces like std.rand( 1.0, 2.0 ).
(wrong # of arguments and type should be int)
The correct behavior is to (not crash, first of all and) return
meaningful message that it doesn't fit the prototype.
This has been fixed and will be in the next release. In the
meantime, there is an updated chuck_type.cpp and win32
executable:
http://chuck.cs.princeton.edu/release/snapshots/
This doesn't seem to affect other platforms (we are tracking
down why not) Thanks to ./rrm and Mikael for finding this.
Best,
Ge!
Just as a little benefit to everyone out there (and mainly because I
myself grew annoyed), I looked up the frequencies for a welltempered
scale, hacked out the ChucK commands assigning those frequencies to names
I could cope with, looked up a list of MANY canonical scales, hacked that
to a format I liked, and produced a small example ChucK script that will
play a mandolin tune in any "cultural" melodic context you want. =)
By the way. I WANT arrays. This'd be SO much easier with arrays!
Enjoy:
<<<<<<<< ChucK definitions for "common" note names >>>>>>>>
55.000=>float A0;
110.000=>float A1;
220.000=>float A2;
440.000=>float A3;
880.000=> float A4;
1760.000=>float A5;
58.270 =>float Bb0;
116.541 =>float Bb1;
233.082 =>float Bb2;
466.164 =>float Bb3;
932.328 =>float Bb4;
1864.655=>float Bb5;
61.735 =>float B0;
123.471=> float B1;
246.942=> float B2;
493.883=> float B3;
987.767=> float B4;
1975.533=>float B5;
65.406 =>float C0;
130.813 =>float C1;
261.626 =>float C2;
523.251 =>float C3;
1046.502 =>float C4;
2093.005=>float C5;
69.296 =>float Db0;
138.591 =>float Db1;
277.183 =>float Db2;
554.365 =>float Db3;
1108.731 =>float Db4;
2217.461=> float Db5;
73.416 =>float D0;
146.832 =>float D1;
293.665 =>float D2;
587.330 =>float D3;
1174.659 =>float D4;
2349.318=> float D5;
77.782 =>float Eb0;
155.563 =>float Eb1;
311.127 =>float Eb2;
622.254 =>float Eb3;
1244.508 =>float Eb4;
2489.016=>float Eb5;
82.407 =>float E0;
164.814 =>float E1;
329.628 =>float E2;
659.255 =>float E3;
1318.510 =>float E4;
2637.020=>float E5;
87.307 =>float F0;
174.614 =>float F1;
349.228 =>float F2;
698.456 =>float F3;
1396.913 =>float F4;
2793.826=>float F5;
92.499 =>float Gb0;
184.997 =>float Gb1;
369.994 =>float Gb2;
739.989 =>float Gb3;
1479.978 =>float Gb4;
2959.955=>float Gb5;
97.999 =>float G0;
195.998 =>float G1;
391.995 =>float G2;
783.991 =>float G3;
1567.982 =>float G4;
3135.963=>float G5;
103.826 =>float Ab0;
207.652 =>float Ab1;
415.305 =>float Ab2;
830.609 =>float Ab3;
1661.219 =>float Ab4;
3322.438=>float Ab5;
<<<<<<<< >>>>>>>>>
<<<<<<<< Commented list of scales >>>>>>>
// Scale references
// 1 2 3 4 5 6 7 8 9 10 11 12 13
// Chromatic C Db D Eb E F Gb G Ab A Bb B C
// Spanish 8 Tone C Db Eb E F Gb Ab Bb C
// Flamenco C Db Eb E F G Ab Bb C
// Symmetrical C Db Eb E Gb G A Bb C
// Diminished C D Eb F Gb Ab A B C
// Whole Tone C D E Gb Ab Bb C
// Augmented C Eb E G Ab B C
// 3 semitone C Eb Gb A C
// 4 semitone C E Ab C
//
// Ultra Locrian C Db Eb E Gb Ab A C
// Super Locrian C Db Eb E Gb Ab Bb C (Ravel)
// Indian-ish* C Db Eb E G Ab Bb C
// Locrian C Db Eb F Gb Ab Bb C
// Phrygian C Db Eb F G Ab Bb C
// Neapolitan Min C Db Eb F G Ab B C
// Javanese C Db Eb F G A Bb C
// Neapolitan Maj C Db Eb F G A B C
// Todi (Indian) C Db Eb Gb G Ab B C
// Persian C Db E F Gb Ab B C
// Oriental C Db E F Gb A Bb C
// Maj.Phryg. (Dom)C Db E F G Ab Bb C Spanish/ Jewish
// Double Harmonic C Db E F G Ab B C Gypsy/
Byzantine/ Charhargah
// Marva (Indian) C Db E Gb G A B C
// Enigmatic C Db E Gb Ab Bb B C
//
// Locrian Natural 2nd C D Eb F Gb Ab Bb C
// Minor (natural) C D Eb F G Ab Bb C Aeolian/
Algerian (oct2)
// Harmonic Minor C D Eb F G Ab B C Mohammedan
// Dorian C D Eb F G A Bb C
// Melodic Minor (Asc) C D Eb F G A B C Hawaiian
// Hungarian Gypsy C D Eb Gb G Ab Bb C
// Hungarian Minor C D Eb Gb G Ab B C Algerian (oct1)
// Romanian C D Eb Gb G A Bb C
//
// Maj. Locrian C D E F Gb Ab Bb C Arabian
// Hindu C D E F G Ab Bb C -
// Ethiopian C D E F G Ab B C
// Mixolydian C D E F G A Bb C -
// Major C D E F G A B C Ionian
// Mixolydian Aug. C D E F Ab A Bb C -
// Harmonic Major C D E F Ab A B C -
// Lydian Min. C D E Gb G Ab Bb C -
// Lydian Dominant C D E Gb G A Bb C Overtone
// Lydian C D E Gb G A B C -
// Lydian Aug. C D E Gb Ab A Bb C -
// Leading Whole Tone C D E Gb Ab Bb B C -
// Bluesy R&R* C Eb E F G A Bb C -
// Hungarian Major C Eb E Gb G A Bb C Lydian sharp2nd
//
// "pB" C Db Eb Gb Ab C -
// Balinechuck(a)lists.cs.princeton.eduse 1 C Db Eb G Ab C "pE"
// Pelog (Balinese) C Db Eb G Bb C -
// Iwato (Japanese) C Db F Gb Bb C -
// Japanese 1 C Db F G Ab C Kumoi
// Hirajoshi (Japanese) C D Eb G Ab C "pA"
// "pD" C D Eb G A C -
// Pentatonic Major C D E G A C Chinese 1/ Mongolian/ "pFCG"
// Egyptian C D F G Bb C -
// Pentatonic Minor C Eb F G Bb C -
// Chinese 2 C E Gb G B C -
<<<<<<<< ChucK script that, given the notes above, plays a tune in a
specified scale >>>>>>>
75::ms => dur T;
Mandolin s => Echo e => NRev r => dac;
0.2 => r.mix;
2::T => e.delay;
1 => int m;
0 => int tone;
2 => int octave;
5 => int n_tones;
while(true) {
if(m%2==0) tone+1 => tone;
if(m%3==0) tone-2 => tone;
if(m%5==0) tone+3 => tone;
if(m%7==0) tone-4 => tone;
if(m%11==0) tone+5 => tone;
std.rand2(0,3)+tone => tone;
while(tone<0) { tone+n_tones => tone; octave-1=>octave; }
while(tone>=n_tones) {tone-n_tones => tone; octave+1 => octave; }
// Egyptian C D F G Bb C -
if(tone==0)
C2 => s.freq;
if(tone==1)
D2 => s.freq;
if(tone==2)
E2 => s.freq;
if(tone==3)
G2 => s.freq;
if(tone==4)
A2 => s.freq;
if(tone==5)
A2 => s.freq;
if(tone==6)
Bb2 => s.freq;
if(tone==7)
Bb2 => s.freq;
m+1 => m;
1.0 => s.pluck;
std.rand2f(0.9,1.0)::T => now;
0.8 => s.pluck;
std.rand2f(0.9,1.0)::T => now;
0.9 => s.pluck;
std.rand2f(0.9,1.0)::T => now;
0.7 => s.pluck;
std.rand2f(0.9,1.0)::T => now;
// 5::T => now;
}
<<<<<<< >>>>>>>
--
Mikael Johansson To see the world in a grain of sand
mikael(a)johanssons.org And heaven in a wild flower
http://www.mikael.johanssons.org To hold infinity in the palm of your hand
http://blog.mikael.johanssons.org And eternity for an hour
Dear All,
chuck-1.1.5.4 is another incremental update with bug fixes
and one rather questionable new keyword:
http://chuck.cs.princeton.edu/
we apologize for the lack of language references. there is
now a somewhat definitive list of keywords:
http://chuck.cs.princeton.edu/doc/program/keywords.html
this is mirrored from the wiki - feel free to post stuff here:
http://wiki.cs.princeton.edu/index.php/ChucK_Keywords
Please let us know if there are any issues.
---
1.1.5.4 - 2004.11.18
- fixed clicks when using adc unit generator
(thanks to paul botelho for testing)
- added 'maybe' keyword
maybe == 0 or 1, with 50% probability each
new examples:
- maybe.ck : the maybe keyword - bad idea? maybe.
- maybecli.ck : maybe click, maybe not
adc examples work better:
- adc.ck
- echo.ck
- i-robot.ck
HappY ChucKing!
Best,
ChucK team
Dear All,
chuck-1.1.5.3 is released. We have resumed full-speed development
on the major release. Until that is done, there will be a few more
minor
releases (such as this one). Source + binaries (for OS X and win32):
http://chuck.cs.princeton.edu/
---
1.1.5.3 - 2004.11.9
- when a shred is removed from VM, all children shreds are
also recursively removed
(this fix crash due to removing shreds with active children shreds)
(to keep children around, put parent in infinite time-loop)
(this isn't always good - real solution coming soon)
- 'start' keyword now available - holds the a shred's begin time
updated examples:
- powerup.ck : start local variable changed name
- spork.ck : added infinite time loop to keep children active
HappY ChucKing!
Best,
ChucK team