![]() |
| [[ Home | Forums | 3D Engines Database | Wiki | Articles/Tutorials | Game Dev Jobs | IRC Chat Network | Contact Us ]] |
|
|
#1 |
|
New Member
Join Date: Jun 2006
Location: New Jersey
Posts: 4
|
I have a sound that I want to convolute with the transfer function of the area without having to put the whole sound in memory. Is there a way to do this, or will I just have to make a Fourier Transform of the sound, and the room, multiply, and compute an inverse fourier transform, then play the sound?
|
|
|
|
|
|
#2 |
|
Senior Member
Join Date: Oct 2005
Location: Pensacola, FL
Posts: 1,028
|
I like the term convolve much better. To convolute implies obfuscation. Now on to your question!
Here is the convolution integral: ![]() However, you are working a discrete environment, so you get this: ![]() So, for each n step you calculate for y, you need to sum the right term over the range of your whole signal. With that said, you could read each mth value from the transform and signal functions one at a time without placing the whole signal in memory, but you will need to do this for all of n. Code:
Of course, I haven't done this before and I could be way off! ![]() |
|
|
|
|
|
#3 |
|
Senior Member
Join Date: Jan 2003
Location: East Coast, USA
Posts: 370
|
having the entire sound data in memory gives you absolute fidelity. alternatively, let's say you have n sound data for every second. you could skip every m sound data such that now you're only loading (n-m) sound data per second. that leaves your entire sound data smaller. optionally, you could then interpolate the "points" between the smaller data set to "regain" the sacrificed data.
all of this, of course, would cost you processing time. pick your trade-off. just my 2cents. :regards:
___________________________________________
Imagine. |
|
|
|
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
|