I’ve been poking around the FMOD APIs and examples for a few days, and I still have questions when it comes to working with CDA. My over-all end-result goal is to run CD Tracks through FMOD’s spectrum analysis. Is this an easy task that I’m over complicating, perhaps?
If anyone could lay down some low-level guidelines to follow, or provide a simple code example, it’d be invaluable to me.
- Luth asked 15 years ago
Hey, thats great news! 😀
I’ll definately poke around with Streams for CDA, see what I can turn up. Of course, if you want to post / upload /email me a small chunk of code that does the basic setting-up and/or extracting a track, that would be all the better. I learn best by mimicking others’ code, especially when I’m still only slightly acquainted with FMOD’s APIs.
Well, the “basic setting-up and/or extracting a track” is about 2500 lines of code and I can’t really post it seeing as how it’s part of FMOD. I suggest you check out the source of an open-source ripper like CDEX, download a copy of the SCSI and MMC specs and put on a fresh pot of coffee. You’ve got a lot of reading to do. 😉
[quote="andrew":3phthdxa]We’ve already got CD digital audio extraction working here and we’ll probably do a 3.71 release soon so you guys can check it out. Basically, you’ll use FSOUND_Stream_Open and specify a CD drive and you’ll use FSOUND_Stream_SetSubStream to choose the different CD tracks. Then it’ll look and feel just like a normal FMOD stream – you’ll be able to use endcallbacks, synchpoints, attach DSP units to it, do spectrum analysis, even use FSOUND_SetFrequency to play it faster/slower if you like. :lol:[/quote:3phthdxa]
Sounds great 😀
Luth>you can also have a look to the [url=http://akrip.sourceforge.net/:3phthdxa]Akrip[/url:3phthdxa] library or simply use it to do cd audio extraction 😆
2,500 lines? 😮
I hope you just misunderstood me. Is that 2,500 lines W/O using FMOD APIs, or is that 2,500 lines WITH using all FMOD APIs?
I dont need to learn how FMOD works. I certainly dont have that much time on my hands! But if I can use FMOD as a tool to get a handle on these CD tracks, then I’m golden.
So, to clarify my question, w/o going into the internals of FMOD, is the setup and/or extraction (using FMOD APIs) a relatively simple task, or is it still 2,500 lines of code? I assume (and its dangerous to assume) that if you’re just using FMOD APIs, and no internal code, then that would be safe to distribute?
Also, to KarLKoX: I’m hoping to keep this project within the scope of FMOD (hey, I’m a fan, what can I say?), but in the case that its a Huge Huge task, like Andrew suggested, I’ll gladly look into Akript, and thanks for the help.
It’s all FMOD code, written from scratch, so I can’t distribute it. It wasn’t a typo, there’s about 2500 lines of code for the basic ripping stuff. 3000 if you count the integration with the FMOD streamer. It’s kinda not trivial to pull off, that’s why I suggested you get the source of something like CDex (and AKRip rocks too!) and also the SCSI and MMC specs and start learning. Or you could just use AKRip and be done with it, but I don’t want to discourage you from digging a bit deeper and getting your hands dirty with low-level SCSI stuff. It’s… character building. 😀
Yeah, Brett’s got the right idea. If I had time to care about internals, I’d go dig through CDex, but this is just a side project… I’m not a sound guy, I make games over at Nintendo.
I’m gonna spend some time today going over the samples and tutorials and stuff, see if I can get a firm handle on all this, what with DSP objects and all…
So how hard would it be to, using only FMOD APIs of course, give me a quick “Hello World” on how to manipulate CDs? Like I said, my end-result goal is just to analyze the data, but I’m not sure (due to my short experience with FMOD) if I have to convert these into some FSOUND_SAMPLE or what not.
Hopefully after I read up a bit on these magic DSP thingy-ma-jigs, I’ll have a better understanding, and wont be such a thorn in your side.
Sorry, misread your post. FMOD CDDA support is not public yet (will be soon) but, in the meantime, check out the FMOD stream and dsp examples. FMOD CDDA will use the stream api (FSOUND_Stream_Open, FSOUND_Stream_Play etc.) so any knowledge you pick up on streams, DSP units etc. will be directly transferrable to the CDDA stuff when it’s ready.
We’ve already got CD digital audio extraction working here and we’ll probably do a 3.71 release soon so you guys can check it out. Basically, you’ll use FSOUND_Stream_Open and specify a CD drive and you’ll use FSOUND_Stream_SetSubStream to choose the different CD tracks. Then it’ll look and feel just like a normal FMOD stream – you’ll be able to use endcallbacks, synchpoints, attach DSP units to it, do spectrum analysis, even use FSOUND_SetFrequency to play it faster/slower if you like. 😆
Please login first to submit.