search for: nb_read

Displaying 5 results from an estimated 5 matches for "nb_read".

Did you mean: xb_read
2008 Feb 08
2
Quick bug in speexenc
...ation after the "data" fourcc. I created a very quick hack by adding: int tentative_read = bits/8*channels* frame_size; if (*size < 0) { tentative_read = tentative_read + *size; /* Size is negative, don't forget ;) */ } nb_read = fread(in,1,tentative_read, fin); instead of the original fread. This is a very dirty hack, but it works well using my strange .wavs. Cleanup more than required ;) Thanks Michel -------------- next part -------------- An HTML attachment was scrubbed... URL: http://lists.xiph.or...
2009 May 16
1
Speex seek with high precision
...000; ogg_int64_t granulepos; do { // Skip pages until the page we want to seek granulepos = ogg_page_granulepos(&og); // previous granulepos while (ogg_sync_pageout(&oy, &og) != 1) { data = ogg_sync_buffer(&oy, 512); nb_read = fread(data, 1, 512, fin); ogg_sync_wrote(&oy, nb_read); } nPages++; } while (ogg_page_granulepos(&og) < position); printf("ogg_page_packets: %d\n", ogg_page_packets(&og)); // Add page to the bitstream ogg_stream_pagein(&a...
2009 May 16
2
Speex seek with high precision
Hello Conrad, I'm trying to seek the way you told but I'm facing a problem. ogg_page_packets returns 164 and following code returns 189. Shouldn't it be the same, what does that means ? int res; while (true) { res = ogg_stream_packetout(&os, &op); if (res == 1) nPackets++; if (res == -1)
2008 Apr 04
0
speexdec 1.2.3
...en(inFile, "rb"); if (!fin) { perror(inFile); exit(1); } close_in=1; } /*Init Ogg data struct*/ ogg_sync_init(&oy); speex_bits_init(&bits); /*Main decoding loop*/ while (1) { char *data; int i, j, nb_read; /*Get the ogg buffer for writing*/ data = ogg_sync_buffer(&oy, 200); /*Read bitstream from input file*/ nb_read = fread(data, sizeof(char), 200, fin); ogg_sync_wrote(&oy, nb_read); /*Loop for all complete pages we got (most likely only one)*/...
2008 Apr 04
2
speexdec 1.2.3
On Fri, Apr 4, 2008 at 12:19 AM, Jean-Marc Valin <jean-marc.valin at usherbrooke.ca> wrote: > Jahn, Ray (R.) a ?crit : > > > Dear Speex codec community: > > > > I am working on conversion of voice files. I could not figure out how to use speexdec.exe 1.2.3 in piped mode in order to avoid the creation of the potentially large intermediate *.wav or *.pcm files. Any