|
View:
New views
5 Messages
—
Rating Filter:
Alert me
|
|
|
streaming reception, audio reminders and holesHello all,
i am looking for some suggestions to solve the last issues i have in a streaming application. As you probably remeber, i asked some help on this some time ago, then i left the task for a period an now i am back on it. I am receiving a stream 8Khz PCM 16bit from a list of embedded devices. So basically i have a listview and 2 buttons, RX and OFF. My PC sw side is basically as in the oal playstream sample, just reading from the network instead of file. My first problem is that after listening from a device, pressing OFF, and start RX on another device, for about half of a second, or a little less, i hear a piece of the previous stream (previous device). I tought my problem was in a bad "Stop", actually i try this way to stop the audio: if (source) { // stop audio and clear the buffers alSourceStop (source); alSourcei (source, AL_BUFFER, 0); // error cleaning alGetError (); } But old audio still remain in the buffers at the next play. Should i delete the buffers and recreate them ? Is there a way to get the buffer pointer and memset to 0 ? If i close completely the audio device handle and reopen it, could it avoid definitely the problem ? My second problem is that, just after i start to play, i hear some little "bouncing". I checked with wireshark, packets arrive with regular intervals (32msec, 512bytes per packet). I do a 8 packet preload and then start to play, so this is quite strange, but maybe it is a side effect of problem 1. Thanks in advice, Greetings, Angelo _______________________________________________ Openal mailing list Openal@... http://opensource.creative.com/mailman/listinfo/openal |
|
|
Re: streaming reception, audio reminders and holes> if (source) > { > // stop audio and clear the buffers > alSourceStop (source); > alSourcei (source, AL_BUFFER, 0); > > // error cleaning > alGetError (); > } > > But old audio still remain in the buffers at the next play. Should i > delete the buffers and recreate them ? Is there a way to get the buffer > pointer and memset to 0 ? If i close completely the audio device handle > and reopen it, could it avoid definitely the problem ? Does this happen with the "Generic Software" and "Generic Hardware" devices? I seem to recall you have problems with the "Generic Hardware" device on your PC. Assuming it happens with both devices ... when you re-start playback are you re-filling *all* the buffers you use for streaming? Are you flushing any audio data you may have in your own temporary buffers of data? It should be possible to fix this without resorting to closing OpenAL down. You could, for example, delete all the buffers and re-generate them to be sure nothing is left - but I would imagine that when you re-start you would need to re-fill all the buffers. Dan Creative Labs, UK _______________________________________________ Openal mailing list Openal@... http://opensource.creative.com/mailman/listinfo/openal |
|
|
Re: streaming reception, audio reminders and holesHi Daniel,
about holes, yes, i was NOT filling all the buffers, now it is really better. Yes i am usign Generic Software now, since i still haven't found the reason of my GH problems. So, remain the problem of this about 100 ms of audio remider. These are the test conditionsm so you can reproduce it is you want: Generic Software, last OpenAL 1.1 dev kit. I am testing receiving "8khz/16bit mono" audio from a device, like "AAAAA". Trough a listview, i switch immediatly from this device to another that transmit silence. A little piece of audio (<=100msecs) of the old stream is heard, before the silence. - added a device id in the packets, so i discard udp audio packets still in the network queue that are not from the selected device. - unqueing the buffers doesn't solve the problem. - deleting and recreating buffers doesen't solve. - deleting and recreating source doesen't solve. I am going to try to close and recreate context or device. Regards, Angelo Daniel PEACOCK ha scritto: > > > if (source) > > { > > // stop audio and clear the buffers > > alSourceStop (source); > > alSourcei (source, AL_BUFFER, 0); > > > > // error cleaning > > alGetError (); > > } > > > > But old audio still remain in the buffers at the next play. Should i > > delete the buffers and recreate them ? Is there a way to get the buffer > > pointer and memset to 0 ? If i close completely the audio device handle > > and reopen it, could it avoid definitely the problem ? > > Does this happen with the "Generic Software" and "Generic Hardware" > devices? I seem to recall you have problems with the "Generic > Hardware" device on your PC. > > Assuming it happens with both devices ... when you re-start playback > are you re-filling *all* the buffers you use for streaming? Are you > flushing any audio data you may have in your own temporary buffers of > data? > > It should be possible to fix this without resorting to closing OpenAL > down. You could, for example, delete all the buffers and re-generate > them to be sure nothing is left - but I would imagine that when you > re-start you would need to re-fill all the buffers. > > Dan > Creative Labs, UK > _______________________________________________ Openal mailing list Openal@... http://opensource.creative.com/mailman/listinfo/openal |
|
|
Re: streaming reception, audio reminders and holesHi Angelo, I'm really not sure where the 100ms of audio is coming from when you re-start playback, if you have deleted and regenerated all the sources and buffers. I don't think it can be coming from OpenAL. Dan Creative Labs (UK) Ltd. Notice The information in this message is confidential and may be legally privileged. It is intended solely for the addressee. Access to this message by anyone else is unauthorized. If you are not the intended recipient, any disclosure, copying or distribution of the message, or any action taken by you in reliance on it, is prohibited and may be unlawful. If you have received this message in error, please delete it and contact the sender immediately. Thank you. Creative Labs UK Ltd company number 2658256 registered in England and Wales at Belmont Road, Belmont Place, Maidenhead, Berkshire, SL6 6TB gmail <angelo70@... om> To Daniel PEACOCK 08/04/2009 10:51 <dpeacock@...> AM cc OpenAL <openal@...> Subject Re: [Openal] streaming reception, audio reminders and holes Hi Daniel, about holes, yes, i was NOT filling all the buffers, now it is really better. Yes i am usign Generic Software now, since i still haven't found the reason of my GH problems. So, remain the problem of this about 100 ms of audio remider. These are the test conditionsm so you can reproduce it is you want: Generic Software, last OpenAL 1.1 dev kit. I am testing receiving "8khz/16bit mono" audio from a device, like "AAAAA". Trough a listview, i switch immediatly from this device to another that transmit silence. A little piece of audio (<=100msecs) of the old stream is heard, before the silence. - added a device id in the packets, so i discard udp audio packets still in the network queue that are not from the selected device. - unqueing the buffers doesn't solve the problem. - deleting and recreating buffers doesen't solve. - deleting and recreating source doesen't solve. I am going to try to close and recreate context or device. Regards, Angelo Daniel PEACOCK ha scritto: > > > if (source) > > { > > // stop audio and clear the buffers > > alSourceStop (source); > > alSourcei (source, AL_BUFFER, 0); > > > > // error cleaning > > alGetError (); > > } > > > > But old audio still remain in the buffers at the next play. Should i > > delete the buffers and recreate them ? Is there a way to get the buffer > > pointer and memset to 0 ? If i close completely the audio device handle > > and reopen it, could it avoid definitely the problem ? > > Does this happen with the "Generic Software" and "Generic Hardware" > devices? I seem to recall you have problems with the "Generic > Hardware" device on your PC. > > Assuming it happens with both devices ... when you re-start playback > are you re-filling *all* the buffers you use for streaming? Are you > flushing any audio data you may have in your own temporary buffers of > data? > > It should be possible to fix this without resorting to closing OpenAL > down. You could, for example, delete all the buffers and re-generate > them to be sure nothing is left - but I would imagine that when you > re-start you would need to re-fill all the buffers. > > Dan > Creative Labs, UK > ForwardSourceID:NT0006E416 _______________________________________________ Openal mailing list Openal@... http://opensource.creative.com/mailman/listinfo/openal |
|
|
Re: streaming reception, audio reminders and holesHello Daniel and all,
i finally found the problem, OpenaAL have nothing to do with this, remainder was in a "spare" fifo i forget to clear(). many thanks, Angelo Daniel PEACOCK ha scritto: > > Hi Angelo, > > I'm really not sure where the 100ms of audio is coming from when you > re-start playback, if you have deleted and regenerated all the sources > and buffers. I don't think it can be coming from OpenAL. > > Dan > Creative Labs (UK) Ltd. > > ------------------------------------------------------------------------ > *Notice* > The information in this message is confidential and may be legally > privileged. It is intended solely for the addressee. Access to this > message by anyone else is unauthorized. If you are not the intended > recipient, any disclosure, copying or distribution of the message, or > any action taken by you in reliance on it, is prohibited and may be > unlawful. If you have received this message in error, please delete it > and contact the sender immediately. Thank you. > > Creative Labs UK Ltd company number 2658256 registered in England and > Wales at Belmont Road, Belmont Place, Maidenhead, Berkshire, SL6 6TB > > Inactive hide details for gmail <angelo70@...>gmail > <angelo70@...> > > > *gmail <angelo70@...>* > > 08/04/2009 10:51 AM > > > > To > > Daniel PEACOCK <dpeacock@...> > > cc > > OpenAL <openal@...> > > Subject > > Re: [Openal] streaming reception, audio reminders and holes > > > > > Hi Daniel, > > about holes, yes, i was NOT filling all the buffers, now it is really > better. > Yes i am usign Generic Software now, since i still haven't found the > reason of my GH problems. > > So, remain the problem of this about 100 ms of audio remider. > > These are the test conditionsm so you can reproduce it is you want: > Generic Software, last OpenAL 1.1 dev kit. > I am testing receiving "8khz/16bit mono" audio from a device, like > "AAAAA". > Trough a listview, i switch immediatly from this device to another that > transmit silence. A little piece of audio (<=100msecs) of the old stream > is heard, before the silence. > > - added a device id in the packets, so i discard udp audio packets still > in the network queue that are not from the selected device. > - unqueing the buffers doesn't solve the problem. > - deleting and recreating buffers doesen't solve. > - deleting and recreating source doesen't solve. > > I am going to try to close and recreate context or device. > > Regards, > Angelo > > > > > > > Daniel PEACOCK ha scritto: > > > > > if (source) > > > { > > > // stop audio and clear the buffers > > > alSourceStop (source); > > > alSourcei (source, AL_BUFFER, 0); > > > > > > // error cleaning > > > alGetError (); > > > } > > > > > > But old audio still remain in the buffers at the next play. Should i > > > delete the buffers and recreate them ? Is there a way to get the > buffer > > > pointer and memset to 0 ? If i close completely the audio device > handle > > > and reopen it, could it avoid definitely the problem ? > > > > Does this happen with the "Generic Software" and "Generic Hardware" > > devices? I seem to recall you have problems with the "Generic > > Hardware" device on your PC. > > > > Assuming it happens with both devices ... when you re-start playback > > are you re-filling *all* the buffers you use for streaming? Are you > > flushing any audio data you may have in your own temporary buffers of > > data? > > > > It should be possible to fix this without resorting to closing OpenAL > > down. You could, for example, delete all the buffers and re-generate > > them to be sure nothing is left - but I would imagine that when you > > re-start you would need to re-fill all the buffers. > > > > Dan > > Creative Labs, UK > > > > > ForwardSourceID:NT0006E416 _______________________________________________ Openal mailing list Openal@... http://opensource.creative.com/mailman/listinfo/openal |
| Free embeddable forum powered by Nabble | Forum Help |