electro-music.com   Dedicated to experimental electro-acoustic
and electronic music
 
    Front Page  |  Articles  |  Radio
 |  Media  |  Forum  |  Wiki  |  Links  |  Store
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 
go to the radio page Live at electro-music.com radio 1 Please visit the chat
poster
 Forum index » DIY Hardware and Software » ChucK programming language
Sound morphing via amplitude / phase decomposition
Post new topic   Reply to topic Moderators: Kassen
Page 1 of 1 [7 Posts]
View unread posts
View new posts in the last week
Mark the topic unread :: View previous topic :: View next topic
Author Message
Frostburn



Joined: Dec 12, 2007
Posts: 255
Location: Finland
Audio files: 9

PostPosted: Mon Jun 02, 2008 6:41 am    Post subject: Sound morphing via amplitude / phase decomposition
Subject description: whistling with an edge
Reply with quote  Mark this post and the followings unread

I made a little Python script with numpy to do the Hilbert Transform on a signal and decompose it to an amplitude and a phase signal. (Works best with a sinusoid input)
(I didn't use ChucK's FFT for that because it I couldn't get the manual .transform() to work)
Then it was just a simple matter of recomposing the phase and amplitude back together but with a TriOsc twist. :)
Code:
SndBuf a => Gain AM => dac;// => WvOut w => blackhole; "triangle_whistle.wav" => w.wavFilename;
SndBuf p => TriOsc t => AM;
"amplitude.wav" => a.read;
"phase.wav" => p.read;
3 => AM.op;
0.5 => p.gain; //"phase.wav" uses the full range. Scale \
Step shift => t; //and shift it to work as a ChucKian phase.
0.5 => shift.next;
1 => t.sync;
a.samples()::samp => now;


Posting this because I thought it sounded cool. I think the technique has potential.

Sorry for not posting the Python script part but it's just too hacky because I'm still learning the language.


whistle.mp3
 Description:
Me whistling a tune to the microphone. Highpassed to get rid of the DC.

Download
 Filename:  whistle.mp3
 Filesize:  153.42 KB
 Downloaded:  533 Time(s)


triangle_whistle.mp3
 Description:
The same tune after morphing in to a triangle wave.

Download
 Filename:  triangle_whistle.mp3
 Filesize:  153.42 KB
 Downloaded:  596 Time(s)


_________________
To boldly go where no man has bothered to go before.
Back to top
View user's profile Send private message
ultrasine



Joined: Aug 31, 2006
Posts: 16
Location: Europe

PostPosted: Thu Jun 12, 2008 1:02 am    Post subject: Reply with quote  Mark this post and the followings unread

Dude, I have no idea what youre talking about but the audio clips you posted are cool.
Back to top
View user's profile Send private message Visit poster's website
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Thu Jun 12, 2008 2:22 am    Post subject: Reply with quote  Mark this post and the followings unread

Yeah, the triangle wave whistle sounds like a good effect. By the way, there's an effects collaboration going on, you might like to participate. They are going to send out audio samples and then we send back processed audio files. I'm on the mailing list for that one, but there's very little activity. Seems like an academic crowd. Just thought you might be interested.
_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Frostburn



Joined: Dec 12, 2007
Posts: 255
Location: Finland
Audio files: 9

PostPosted: Thu Jun 12, 2008 3:00 am    Post subject: Reply with quote  Mark this post and the followings unread

Inventor wrote:
By the way, there's an effects collaboration going on, you might like to participate. They are going to send out audio samples and then we send back processed audio files. I'm on the mailing list for that one, but there's very little activity. Seems like an academic crowd. Just thought you might be interested.

I sure would!
Link please.

_________________
To boldly go where no man has bothered to go before.
Back to top
View user's profile Send private message
ultrasine



Joined: Aug 31, 2006
Posts: 16
Location: Europe

PostPosted: Thu Jun 12, 2008 3:03 am    Post subject: Reply with quote  Mark this post and the followings unread

Inventor wrote:
Yeah, the triangle wave whistle sounds like a good effect. By the way, there's an effects collaboration going on, you might like to participate. They are going to send out audio samples and then we send back processed audio files. I'm on the mailing list for that one, but there's very little activity. Seems like an academic crowd. Just thought you might be interested.


You have a URL for that? I have loads of work but am easily tempted.
Back to top
View user's profile Send private message Visit poster's website
Frostburn



Joined: Dec 12, 2007
Posts: 255
Location: Finland
Audio files: 9

PostPosted: Thu Jun 12, 2008 3:28 am    Post subject: Reply with quote  Mark this post and the followings unread

ultrasine wrote:
Dude, I have no idea what youre talking about but the audio clips you posted are cool.

Thanks.
I plan to work on this, and other cool stuff that can't easily be done with ChucK, more in the future but that'll probable be in Python/C++.

_________________
To boldly go where no man has bothered to go before.
Back to top
View user's profile Send private message
Inventor
Stream Operator


Joined: Oct 13, 2007
Posts: 6221
Location: near Austin, Tx, USA
Audio files: 267

PostPosted: Thu Jun 12, 2008 4:17 am    Post subject: Reply with quote  Mark this post and the followings unread

Frostburn wrote:
Inventor wrote:
By the way, there's an effects collaboration going on, you might like to participate. They are going to send out audio samples and then we send back processed audio files. I'm on the mailing list for that one, but there's very little activity. Seems like an academic crowd. Just thought you might be interested.

I sure would!
Link please.


Frostburn and ultrasine, here is the link to get on the mailing list:

http://iua-mail.upf.es/mailman/listinfo/dafx-eval

There is a link there to read all the prior mailings. I can't seem to locate the original message that notified me of the whole thing. I plan to submit my tube amp model if they have a category for it. Enjoy!

_________________
"Let's make noise for peace." - Kijjaz
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic Moderators: Kassen
Page 1 of 1 [7 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