Thank you for the answer but i've already read manual and examples and i'm doing same thing of your code, so, maybe you can give me a hint about the problem i have, that it is for sure in my code. A question: is it possible that i hear a "tick" because between two frame i call speex_bits_reset? (for this reason if i encode more than one frame together there is no "tick"). Maybe the solution is to call not speex_bits_reset and using another way (but in your examples it functions)? Thank you> > Same answer as for everyone else: start from the sampleenc/sampledec > programs in the manual and/or speexenc/speexdec. You're simply doing > something wrong with the Speex API. > > Jean-Marc-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20060110/a450843a/attachment.html
How are you hearing "ticks"? Are you saving to a .wav file, or are you writing directly to the sound card? If you're writing directly to the sound card, you'll need to double or triple buffer to avoid ticking. _____ From: speex-dev-bounces@xiph.org [mailto:speex-dev-bounces@xiph.org] On Behalf Of Carlo Cappelletti Sent: Tuesday, January 10, 2006 1:11 AM To: Speex-dev@xiph.org Subject: [Speex-dev] Using speex (newbie) Thank you for the answer but i've already read manual and examples and i'm doing same thing of your code, so, maybe you can give me a hint about the problem i have, that it is for sure in my code. A question: is it possible that i hear a "tick" because between two frame i call speex_bits_reset? (for this reason if i encode more than one frame together there is no "tick"). Maybe the solution is to call not speex_bits_reset and using another way (but in your examples it functions)? Thank you>> Same answer as for everyone else: start from the sampleenc/sampledec > programs in the manual and/or speexenc/speexdec. You're simply doing > something wrong with the Speex API. > > Jean-Marc-------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20060110/ec73546c/attachment.html
Hi Carlo You are bound to hear ticks if you are calling reset function after encoding each frame. If all the frames come continously from the same source you can do without calling the reset function so frequently. Only when you have two totally different source files to be encoded back to back, you need to call the reset in between. As far as I know the tick appears in the first frame encoded ( after calling reset function ) because, the speex ecnoder starts off (after reset) with some pre-defined initial states. And in continous encoding without calling reset function the encoder makes of the states of the previous frame for encoding teh current frame, and it logically and practically makes sense to do it this way. Hope this helps -Anup -----Original Message----- From: speex-dev-bounces@xiph.org [mailto:speex-dev-bounces@xiph.org]On Behalf Of Carlo Cappelletti Sent: Tuesday, January 10, 2006 2:41 PM To: Speex-dev@xiph.org Subject: [Speex-dev] Using speex (newbie) -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.org/pipermail/speex-dev/attachments/20060112/55e9a55a/attachment.html
>From what I understand, he wasn't reseting the encoder, just usingspeex_bits_reset() which is fine. Jean-Marc On Thu, 2006-01-12 at 10:03 +0530, Anup KC wrote:> Hi Carlo > > You are bound to hear ticks if you are calling reset function after > encoding each frame. If all the frames come continously from the same > source you can do without calling the reset function so frequently. > Only when you have two totally different source files to be encoded > back to back, you need to call the reset in between. As far as I know > the tick appears in the first frame encoded ( after calling reset > function ) because, the speex ecnoder starts off (after reset) with > some pre-defined initial states. And in continous encoding without > calling reset function the encoder makes of the states of the previous > frame for encoding teh current frame, and it logically and practically > makes sense to do it this way. > > Hope this helps > -Anup > -----Original Message----- > From: speex-dev-bounces@xiph.org > [mailto:speex-dev-bounces@xiph.org]On Behalf Of Carlo > Cappelletti > Sent: Tuesday, January 10, 2006 2:41 PM > To: Speex-dev@xiph.org > Subject: [Speex-dev] Using speex (newbie) > > _______________________________________________ > Speex-dev mailing list > Speex-dev@xiph.org > http://lists.xiph.org/mailman/listinfo/speex-dev