electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links
Forum with support of Syndicator RSS
 FAQFAQ   CalendarCalendar   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   LinksLinks
 RegisterRegister   ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in  Chat RoomChat Room 
 Forum index » DIY Hardware and Software » ChucK programming language
Sequencing in ChucK?
Post new topic   Reply to topic Moderators: Kassen
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
Fojaneghe



Joined: Jan 17, 2007
Posts: 11
Location: Trento

PostPosted: Wed Jan 24, 2007 1:52 am    Post subject: Reply with quote  Mark this post and the followings unread

Hi all! I want to join in Sjef's ovation and would like to thank all for their patience & interest. However, I would like to put a rather philosophical but technical question.

In my opinion, Chuck is a very fundamental - however, not a very easy - way to program sequences. I started with fruity loops, rebirth, etc. to create the usual techno stuff on the fly. Actually, there was no big deal about how to start. Now my question: is there some reason for which it's worth while to do the hard work and to learn Chuck instead of using the above software? Are there features that render Chuck stronger compared to commercial stuff?

I'm sorry if the question doesn't really belong to this thread.

Greetings to everybody, Fojaneghe
Back to top
View user's profile Send private message
Kassen
Janitor
Janitor


Joined: Jul 06, 2004
Posts: 7678
Location: The Hague, NL
G2 patch files: 3

PostPosted: Wed Jan 24, 2007 2:35 am    Post subject: Reply with quote  Mark this post and the followings unread

Editorial note;

I took the liberty of splitting this post off from the Deb-pack thread because it's interesting and seperate enough to stand on it's own and I feared it might get overlooked by those that don't use Debian.

The new title is mine but I'll hapily change it if Fojaneghe has a better title.

_________________
Kassen
Back to top
View user's profile Send private message Send e-mail Visit poster's website
Kassen
Janitor
Janitor


Joined: Jul 06, 2004
Posts: 7678
Location: The Hague, NL
G2 patch files: 3

PostPosted: Wed Jan 24, 2007 3:03 am    Post subject: Reply with quote  Mark this post and the followings unread

I can only speak for myself but I don't realy use ChucK to sequence as such; I use ChucK to build little sequencers that take live input.

For me it has some big advantages over Fruity and Reason and Live. Personally I never experienced those as real musical instruments, they -to me- are more like ways of notating compositions combined with automated instruments. That's great but I found I'd like to *play* my loops.

At a certain point ChucK (which I'd been tinkering with while writing in Live) got HID input and I thought "why not?" and got a USB joypad. Two hours later I was playing breakbeats live and doing stuff that would've taken days in a wave editor (I used to cut breaks that way) while laying on my back. So; that was basically when I got serious about ChucKing.

I'm now slowly finishing my second (atempt at a) sequencer and this will be my live instrument for the forseeable future. My own little sequencer has exactly zero advantages over Fruity, feature wise, but on the interface front it's exactly what I want, like and need. There's no feature in it that I don't use, understand or get confused or distracted by and there's no need for a mouse or the schreen. So; it's stripped, lean and because of that it works very quickly and it's quite powerfull within it's admittedly limited scope. I have no doubt that anybody else would get stuck halfway into the manual (if there were one) and find it unusable and confusing but that doesn't realy matter because it's for me and a personal sort of instrument.

It's true that compared to simply buying Fruity or Reason it was hard work but then; tailor made clothes are more expensive then even branded fashionable ones. I also found that the whole process of defining this whole thing confronted me with a lot of questions about what I like and need; questions I never realised were there back when I was using commercial software where the set of options at any one moment are multiple-choice. Admittedly a route like that only makes sense if you actively enjoy programing.....

_________________
Kassen
Back to top
View user's profile Send private message Send e-mail Visit poster's website
majutsu



Joined: Jun 18, 2006
Posts: 151
Location: New York
Audio files: 1

PostPosted: Wed Jan 24, 2007 9:18 pm    Post subject: Reply with quote  Mark this post and the followings unread

top ten reasons to like chuck over fruity loops:

10. Saying your hanging with Chuck is a lot more publicly acceptable and less gay than saying you're a fruity looper.

9. Chuck will teach you C++ on the sly. Fruity loops will prepare you for the Lite Brite toy.

8. Chuck is free. -- i.e. More beer money.

7. Gol and the Fruity team laugh at you spending two hundred dollars on recycled MDA freeware while they fly their jet and drink Duvel beer. (so they say Smile i've seen the plane - gol's a pimp-daddy)

6. No one you hate in the music industry uses Chuck. No one uses Chuck.

5. Chuck is a fetus of potential. Fruity loops is an old rave whore.

4. Chuck sounds like whatever you program, whatever you imagine. Fruity sounds like mid-90s euro trance.

3. Chuck can tie into MIDI, HIDs and even skin perspiration levels as read from your whozmigigger while you breakdance. Fruity ties into your cousin's casio that you learned to play van Halen's "Jump" on.

2. If people see you writing Chuck code they think you're a smart nerd. If people see you log into the dark, steamy front-end of My FlStudio, they think you're into gay chat.

1. Of course . . . Chuckers get more sex.

Apologies to David Letterman and the reader for my lame top ten Smile

But Kassen summarized things very well, and I thought I'd have some fun. Of course, Chuck is programming; it is a language. Fruity loops is a program and you are an enduser. Roughly, Chuck:Fruity as Mechanics:Automobile driving. Very different tools really. You can use them both. Chuck a new sound. Burn it to wave. Bring it in the FL sampler and put on FL effects with your other VSTs. yada yada yada

An even more interesting question is Chuck versus Supercollider or PD etc. I think Chuck has advantages here too for me, but that's another topic.

_________________
All phenomena are atoms in association and dissociation.
Back to top
View user's profile Send private message
Fojaneghe



Joined: Jan 17, 2007
Posts: 11
Location: Trento

PostPosted: Sun Jan 28, 2007 11:33 am    Post subject: Reply with quote  Mark this post and the followings unread

Hi all! Indeed, as Majutsu just said, Chuck seems to be more level to the core of the machine one uses than just the steer and the whole frontend. I began to read the manual these days and to do some programming. It was interesting and amazing to produce weird sounds and sequences I would have only dreamt of when using fruity ( e.g.: using the logistic equation to create frequence bifurcations ending up in total chaos). I didn't read yet all the posts of the others around using Chuck, but I can imaging that they already use chuck in such an inventorer's way I'm having in mind.

Of course, when you just want to put up a silly sequence as a drum line in Fruity you don't have to think twice. It's like Majutsu says: you use Fruity to drive not to understand why you drive. So you are forced to bring your brain along when you work with chuck. It's like doing science, and this is why it's fascinating to me.

By the examples I've found since the very beginning Chuck can import/use wav-files just as Fruity and all the other sequencers. But all files are used as black-boxes and effects are put on it. When I want to do some really weird modifications on a given audio file I use CoolEdit or something similar and do some surgery on it. I wonder if this under Chuck can be handled in a more sophisticated way. Think at a modify-sequencer rather than at a usual output sequencer. There are things I have in mind, but it's hard to explain them in suitable words...

Kassen, I would like to know a bit more about that HID feature. Do you have any references or did you built it up all by yourself?

Greetings to all, Fojaneghe
Back to top
View user's profile Send private message
Kassen
Janitor
Janitor


Joined: Jul 06, 2004
Posts: 7678
Location: The Hague, NL
G2 patch files: 3

PostPosted: Sun Jan 28, 2007 3:35 pm    Post subject: Reply with quote  Mark this post and the followings unread

Well, there is sample code in chuck /examples/hid/, tghat stuff should get you started. There should also be examples about the keyboard specifically and I think mouse as well. HID means Human Interface Device and refers to stuff like keyboards, mice and joysticks, it's mainly the joysticks that interest me but I use the kwyboard as well because it has loads of buttons and it's there anyway Smile.

I didn't realy have any real examples; I just started out simple and build from there but I borowed ideas that looked good in grooveboxes and video games and so on.

_________________
Kassen
Back to top
View user's profile Send private message Send e-mail Visit poster's website
dewdrop_world



Joined: Aug 28, 2006
Posts: 858
Location: Guangzhou, China
Audio files: 4

PostPosted: Sun Feb 04, 2007 9:38 pm    Post subject: Reply with quote  Mark this post and the followings unread

Very interesting thread -- I'm not a chucker but Kassen posted a link to this thread in the supercollider forum, thought I would take a look.

Kinda late here so I can really only give an outline of what I do in sc -- I'll be glad to fill in details later. The main thing is that writing music in code gave me the chance to get away from conventional note-list style sequencing into process-oriented composition. sc's object-oriented focus lets you build objects that perform specific processes, so that if you do a kind of "sequencing" very often, you can make an object to simplify the compositional code.

Yes, it's harder than using FL or a DAW, but you can do some things more easily this way than you could do in less flexible software. Since leaving Digital Performer behind, I now avoid loops like the plague in my music... because it is now technically practical to do so.

For instance, I have an object for percussion sequencing. The programming interface is based loosely on a drum machine -- you specify your patterns in terms of a set of arrays for the amplitude at each beat subdivision in the bar, which sample to use, other parameters. For a simple 4x4 kick drum I only have to write:

Code:
PR(\bufPerc).chuck(BP(\kik), parms: (
   bufPaths: ["sounds/kick1.wav"],
   amps: [1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 1, 0, 0, 0]
));

BP(\kik).play;


(Yes, you saw "chuck" in there... I adopted the => operator as a generic mechanism for double-dispatch.)

I could easily write a GUI that lets me set the array values. As the arrays change, the sequencing pattern updates automatically once per bar. This is handled automatically in the bufPerc process, no need to write it again. So this is kind of a bridge between a conventional drum machine interface and the sc pattern way of thinking.

I've also done things like have a breakbeat where specific notes (kick, snare) are placed at specific points in the bar as a foundation, then ornamental notes get added in randomly. Really groovy, code is nice and modular, and I don't have to write the whole code block from scratch every time.

I'll be happy to explain more... ask away Smile

James

_________________
ddw online: http://www.dewdrop-world.net
sc3 online: http://supercollider.sourceforge.net
Back to top
View user's profile Send private message Visit poster's website AIM Address
sir honey



Joined: Aug 04, 2006
Posts: 36
Location: NY

PostPosted: Thu Feb 08, 2007 2:53 pm    Post subject:   Reply with quote  Mark this post and the followings unread

I'd gotten pretty darn good at sequencing electronic music in Logic over a period of a few years, but never could I create music of such mind bending complexity as I've done in the last 2 weeks since I've been on the ChucK. For example:

Code:
// funky algorythm.by Jack Ryon (sirhoney)

SndBuf s => Envelope e => Gain g => HPF her => NRev r => Pan2 p => dac;

30 => her.freq;

SinOsc z => blackhole;

SinOsc w => blackhole;

"drop_in_drumloop_here" => s.read;

.7 => g.gain;

4::ms => e.duration;

while(true)
{

Std.rand2f(.5, 5) => w.freq;

1 => z.freq;

//on or off STEP.

1 => int oo1;

// pan position.

Std.rand2f(-1,1) => float p1;

// sample playback rate.

Std.rand2f(-1,1) => float pb1;

//number of loops

Std.rand2(1,64) => int l1;

//sample start.

Std.rand2(0, s.samples()) => int st1;


         
      for (0 => int x; x < l1; x++)
      {
         Std.fabs(w.last() * 66 + 1) => z.freq;
         oo1 => s.gain;
         z.last() / 2 => p.pan;
         w.last() * z.last() => s.rate;
         (Std.fabs(w.last() - z.last())) /4 => r.mix;
         st1 => s.pos;
         e.keyOn();
         Std.fabs(w.last() * Std.rand2(1, 200) + 4)::ms => now;
         e.keyOff();
         10::ms => now;
      }
   
   
}


throw the amen break in there and listen away. Now this is the sound I was always after, but didn't really have the tools to create. Until Chuck!
I'll still use the trad DAW for editing and mixing, but this elevates electronic music creation to a whole new dimension.

jack
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic Moderators: Kassen
Page 1 of 1 [8 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
 Forum index » DIY Hardware and Software » ChucK programming language
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Forum with support of Syndicator RSS
Powered by phpBB © 2001, 2005 phpBB Group
Copyright © 2003 through 2009 by electro-music.com - Conditions Of Use