Hi there. I have been hearing to ogg vorbis for maybe 2 years and I can only say: it is fantastic! Right now, I'm working in a project that uses ogg vorbis as the format for recording. I have now a working recording engine (I have recorded up to 8 channels at the same time and my computer uses only about 30% of the processor, wich is great in this project), and I'm starting with the playing engine. I have seen the examples, but they are somewhat "simplistic" (no mean to offense anybody!). I need to solve the following scheme: - The files I'm playing represent up to 24 hours of continuous recording. - I need to decode the stream to a PCM memory buffer, that will be used later by existing components to do the actual playing (this allows me to display fancy graphics and so on). - I need to be able to seek to any position (seconds) in the file, and it needs to be quick, and, most of all, needs to use low resources (I mean, I can't decode the entire day into memory, for obvious reasons) - The files are recorded using the same parameters for all the file. I mean, each file can have it's own sample rate, number of channels, and so on, but it will be constant for any given file. - I just need to play one file at the time. BTW: I'm using Borland C++Builder 6 to do this job, under Windows. I had some trouble using the libs provided with the SDK, and I had to do an implib from the DLLs. This is fine. The problem is: The libs are generated using a calling convention that I don't use (and I can't use, because I have another DLLs using different calling convention). Any idea of how to solve it? Is it possible to recompile the SDK using Borland's tools? I'm sorry if this is a "stupid" question, as I'm remembering now that I didn't checked the implib help to see if it is something that can be changed here. If someone can point me on the right direction to do this job it will be terrific. I just need some real-world examples to see. A pseudocode will do. Thanks, in advance. And Thanks, for this great format. Rodrigo Gómez <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
This is my 1st posting to "our" group. Hope it works. Hi Rodrigo: There are seek functions under the api and they held reasonable performance. You should also create your project under your tool and build lib there. The example file is simple and you should spnd time to learn api from them. After that, you should be able to code your own. Just relax and try. You should be able to do it. Then you learn. You can ask detailed questions on part you don't understand. john -----Original Message----- From: Rodrigo Gómez [mailto:rgomez@msa.com.mx] Sent: Wednesday, July 23, 2003 7:31 AM To: vorbis-dev@xiph.org Subject: [vorbis-dev] Seeking ogg-vorbis Hi there. I have been hearing to ogg vorbis for maybe 2 years and I can only say: it is fantastic! Right now, I'm working in a project that uses ogg vorbis as the format for recording. I have now a working recording engine (I have recorded up to 8 channels at the same time and my computer uses only about 30% of the processor, wich is great in this project), and I'm starting with the playing engine. I have seen the examples, but they are somewhat "simplistic" (no mean to offense anybody!). I need to solve the following scheme: - The files I'm playing represent up to 24 hours of continuous recording. - I need to decode the stream to a PCM memory buffer, that will be used later by existing components to do the actual playing (this allows me to display fancy graphics and so on). - I need to be able to seek to any position (seconds) in the file, and it needs to be quick, and, most of all, needs to use low resources (I mean, I can't decode the entire day into memory, for obvious reasons) - The files are recorded using the same parameters for all the file. I mean, each file can have it's own sample rate, number of channels, and so on, but it will be constant for any given file. - I just need to play one file at the time. BTW: I'm using Borland C++Builder 6 to do this job, under Windows. I had some trouble using the libs provided with the SDK, and I had to do an implib from the DLLs. This is fine. The problem is: The libs are generated using a calling convention that I don't use (and I can't use, because I have another DLLs using different calling convention). Any idea of how to solve it? Is it possible to recompile the SDK using Borland's tools? I'm sorry if this is a "stupid" question, as I'm remembering now that I didn't checked the implib help to see if it is something that can be changed here. If someone can point me on the right direction to do this job it will be terrific. I just need some real-world examples to see. A pseudocode will do. Thanks, in advance. And Thanks, for this great format. Rodrigo Gómez <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered. <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
> I have seen the examples, but they are somewhat "simplistic" (no mean to > offense anybody!). I need to solve the following scheme: > - The files I'm playing represent up to 24 hours of continuous > recording. > - I need to decode the stream to a PCM memory buffer, that will be used > later by existing components to do the actual playing (this allows me to > display fancy graphics and so on). > - I need to be able to seek to any position (seconds) in the file, and > it needs to be quick, and, most of all, needs to use low resources (I mean, > I can't decode the entire day into memory, for obvious reasons) > - The files are recorded using the same parameters for all the file. I > mean, each file can have it's own sample rate, number of channels, and so > on, but it will be constant for any given file. > - I just need to play one file at the time.That's all very easy to do using libvorbisfile. The documentation is pretty easy to follow for this sort of thing. The only potential problem is that you say that seeking needs to be 'quick'. Vorbis seeking isn't particularly fast, generally. However, this depends very much on what you consider 'quick', and what sort of hardware you're doing this on. You may have problems if you need seek latency under 10 ms (but experiment, it's obviously highly dependent on your cpu, etc.) So, this basically consists of ov_open() (or ov_open_callbacks() if you have a non-file source for your data) to open the file, ov_clear() to close it once you're done, and calls to ov_read() to decode into a PCM memory buffer, and to one of the ov_seek_*() calls for seeking (probably ov_seek_time()). If you have more specific questions, feel free to ask - but vorbisfile is very easy to use, you shouldn't have too much trouble.> > BTW: I'm using Borland C++Builder 6 to do this job, under Windows. I had > some trouble using the libs provided with the SDK, and I had to do an > implib from the DLLs. This is fine. The problem is: The libs are generated > using a calling convention that I don't use (and I can't use, because I > have another DLLs using different calling convention). Any idea of how to > solve it? Is it possible to recompile the SDK using Borland's tools? I'm > sorry if this is a "stupid" question, as I'm remembering now that I didn't > checked the implib help to see if it is something that can be changed here. >You can recompile the SDK if you want. You should also be able to tell your compiler than you want to use the normal calling convention for the vorbis libraries (while still using your non-standard calling convention for everything else) - all of the win32 compilers I've seen have a mechanism for doing this, but I don't know much about BCB, so I can't give specifics. <p>Mike --- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
Hi Rodrigo, There are functions supported in the vorbis lib which do the required file seek operations with reasonable amount of performance.. The lib consists of a structure called the ov_callbacks which contains a series of function pointers which are made to point to the required file operation function during the initialization process which is done through a call to the ov_open function... Yuo can try building the Ogg Vorbis SDK libraries on Microsoft VC++ as an alternative and the libs do compile on this platform successfully.. Hope this answers your question..Do get back if you have any queries on this mail.. Regards, Karthik Murthy.. -----Original Message----- From: owner-vorbis-dev@xiph.org [mailto:owner-vorbis-dev@xiph.org]On Behalf Of Rodrigo Gómez Sent: Wednesday, July 23, 2003 5:01 AM To: vorbis-dev@xiph.org Subject: [vorbis-dev] Seeking ogg-vorbis <p>Hi there. I have been hearing to ogg vorbis for maybe 2 years and I can only say: it is fantastic! Right now, I'm working in a project that uses ogg vorbis as the format for recording. I have now a working recording engine (I have recorded up to 8 channels at the same time and my computer uses only about 30% of the processor, wich is great in this project), and I'm starting with the playing engine. I have seen the examples, but they are somewhat "simplistic" (no mean to offense anybody!). I need to solve the following scheme: - The files I'm playing represent up to 24 hours of continuous recording. - I need to decode the stream to a PCM memory buffer, that will be used later by existing components to do the actual playing (this allows me to display fancy graphics and so on). - I need to be able to seek to any position (seconds) in the file, and it needs to be quick, and, most of all, needs to use low resources (I mean, I can't decode the entire day into memory, for obvious reasons) - The files are recorded using the same parameters for all the file. I mean, each file can have it's own sample rate, number of channels, and so on, but it will be constant for any given file. - I just need to play one file at the time. BTW: I'm using Borland C++Builder 6 to do this job, under Windows. I had some trouble using the libs provided with the SDK, and I had to do an implib from the DLLs. This is fine. The problem is: The libs are generated using a calling convention that I don't use (and I can't use, because I have another DLLs using different calling convention). Any idea of how to solve it? Is it possible to recompile the SDK using Borland's tools? I'm sorry if this is a "stupid" question, as I'm remembering now that I didn't checked the implib help to see if it is something that can be changed here. If someone can point me on the right direction to do this job it will be terrific. I just need some real-world examples to see. A pseudocode will do. Thanks, in advance. And Thanks, for this great format. Rodrigo Gómez <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered. --- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
On 22 Jul 2003 at 17:30, Rodrigo Gómez wrote:> BTW: I'm using Borland C++Builder 6 to do this job, under Windows.I'm not certain that you can use them in BCB6, but I have BCB4 project files for the libraries, and most of the utilities, here: http://dave.gasaway.org/vorbis/vorbis_bcc.zip -- -:-:- David K. Gasaway -:-:- XNS : =David K Gasaway -:-:- Email: dave@gasaway.org -:-:- Web : dave.gasaway.org <p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
Hi there. Thank you very much for your answers. I have a start point right now. I didn't mean that the seek will need to be quick... I don't know why I say that. This seek will happen at the start of the playing, and, at least right now, the user won't be able to seek when the stream is playing. If he wants to seek, he will have to stop the playing, and start again. Is actually: "I want to start hearing from this time". What actually I need is that the seek won't use a lot of resources, but, if I understand correct, this won't happen. I'll come back with more questions... more "real" questions. Rodrigo Gómez <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.
Hi there. It's been surprising the painless that has been to work with ogg vorbis. I made the decoding engine without any problem, and really quick: maybe 1 hour or something like that (and most of it was to mix this with the existing components...). But I do have a question: I usually enable CodeGuard (somekind of mem check library that Borland provides) and it insists that the file handle to the file (opened by fopen, and later by ov_open, and closed, as the docs says, only by ov_clear) is not freed. I know that CodeGuard is somewhat dumb in a lot of aspects, and this may be one, but I just want to confirm: I don't need to call fclose if I opened and closed fine the file with the ogg vorbis functions? Thanks for all of your help. Rodrigo Gómez <p><p>--- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/ To unsubscribe from this list, send a message to 'vorbis-dev-request@xiph.org' containing only the word 'unsubscribe' in the body. No subject is needed. Unsubscribe messages sent to the list will be ignored/filtered.