search for: vorbis_synthesis_read

Displaying 10 results from an estimated 10 matches for "vorbis_synthesis_read".

2005 Jun 23
2
Sample accuracy in reading
Hey guys, I've finished my work on reading vorbis files (straight reading at either PCM sample lengths, or time lengths). However, I've run across a question. When you call vorbis_synthesis_read, I assume that increments the internal ptrs so you don't get the same data twice. The question is, what happens if you call vorbis_synthesis and vorbis_synthesis_blockin? Does the next call have what SHOULD be the next PCM data, or has it incidentally been invalidated? A little simpler, is it s...
2009 May 12
2
compile error of libtheora example
...r' player_example.c:(.text+0x147a): undefined reference to `vorbis_comment_clear' player_example.c:(.text+0x14cf): undefined reference to `vorbis_synthesis_pcmout' player_example.c:(.text+0x157d): undefined reference to `rint' player_example.c:(.text+0x1646): undefined reference to `vorbis_synthesis_read' player_example.c:(.text+0x1700): undefined reference to `ogg_stream_packetout' player_example.c:(.text+0x171e): undefined reference to `vorbis_synthesis' player_example.c:(.text+0x1736): undefined reference to `vorbis_synthesis_blockin' player_example.c:(.text+0x176b): undefined re...
2006 Aug 31
0
OpenAl and Vorbis
...orbisInfo.channels/2;// /2 int i; for(i=0; i<size && i<maxsamples; i++){ for(int j=0;j<vorbisInfo.channels;j++){ int val=(int) (pcm[j][i]*32767.f); if(val>32767) val=32767; if(val<-32768) val=-32768; audiobuf[count++]=val; } } vorbis_synthesis_read(&vorbisDspState,i); audiobufFill += i*vorbisInfo.channels*2; if (audiobufFill == fragsize) audiobufReady = true; } else { // no pending audio; is there a pending packet to decode? if(ogg_stream_packetout(&oggStreamState,&oggPacket)>0){ if(vorbis_synthe...
1999 Oct 11
2
XMMS plugin patch
...for(c = 0; c < od.vi.channels; c++) - pcmout[(s * od.vi.channels + c) * sizeof(gshort)] = pcm[c][s] * 32767; + *(outptr++) = pcm[c][s] * 32767; vorbis_audio_out(pcmout, samples * od.vi.channels * sizeof(gshort), od.vi.channels); vorbis_synthesis_read(&od.vd, samples); --- >8 ---- List archives: http://www.xiph.org/archives/ Ogg project homepage: http://www.xiph.org/ogg/
2006 Jan 19
0
re: want to know, how much data will be extracted from every single packet; solved but some issues
...packets[i])==0) ? vorbis_synthesis_blockin(&vorb_dsp_state,&vorb_block); ?int bout = vorbis_synthesis_pcmout(&vorb_dsp_state,NULL); ?if (i == m_packets_number - 1) ?{ ? m_packets_real_lengths[i] ?= 2 * m_vorb_info.channels * bout; ? m_data_size += m_packets_real_lengths[i]; ?} ?vorbis_synthesis_read(&vorb_dsp_state,bout); } exactly m_packets_number - 6 and no more :) i 'm lost in conjectures, why is this so... but it works. hah, strange thing, but in code that unpack later fragments of stream into pcm buffer i consider that for packet X i must have only X-1 and code works too... P...
2001 Apr 05
1
decoder_example -- event driven?
...clipflag=1; } *ptr=val; ptr+=2; } } if(clipflag) fprintf(stderr,"Clipping in frame %ld\n",(long)(vd.sequence)); write (mywav, convbuffer, 2*vi.channels*bout); vorbis_synthesis_read(&vd,bout); /* tell libvorbis how many samples we actually consumed */ } --- So, the first packets come in fine because I can retrieve the title, etc properly. All of the packets come in correc...
2002 Jan 22
2
Peak value
Hi, While testing ReplayGain (so it could be related to a bug), I noticed the following gain comments for a file: RG_PEAK=1.71580 RG_RADIO=-7.91 dB RG_AUDIOPHILE=-6.72 dB I've never seen such a large peak. Not that I've looked much, nor have I analyzed the file further. I just thought I should mention it. :) The file is the track Board Burner by Mixmaster Mike, available at:
1999 Oct 04
3
Detailed decoder pseudocode (was: Re: ETA?)
...o, for example, pcm[0][...] is left, and pcm[1][...] is right. samples is the size of each channel. Convert the float values (-1.<=range<=1.) to whatever PCM format and write it out */ /* [ intentionally blank ] */ vorbis_synthesis_read(&vd,samples); /* tell libvorbis how many samples we actually consumed */ } } } if(ogg_page_eos(&og))eos=1; } if(!eos){ buffer=ogg_sync_buffer(&oy,4096); by...
2002 Aug 06
0
Getting a GUI to work with Vorbis code
...} if(clipflag) fprintf(outputFile,"Clipping in frame %ld\n",(long)(vd.sequence)); /* commented out next line - GK */ // fwrite(convbuffer,2*vi.channels,bout,stdout); vorbis_synthesis_read(&vd,bout); /* tell libvorbis how many samples we actually consumed */ } } } if(ogg_page_eos(&og))eos=1; } } if(!eos){...
2006 Oct 09
1
Vorbis primitive API examples (LONG)
...ogg_int32_t *srcChannelArray = pcm[jj]; ogg_int32_t srcValue = srcChannelArray[ii]; short dstValue = CLIP_TO_15(srcValue>>9); long bytesWritten = fwrite(&dstValue, 2, 1, stdout); } } /* Let the decoder know how many samples we actually consumed */ vorbis_synthesis_read(vd, pcmSamples); } } } } } /* Packet valid */ } /* Iterates over packets */ } /* Page system has been initialized and is valid */ /* // Don't pull another page at EOS. Let that occur after reset on another // trip through so that we match the nor...