[theora] ignoring audio in player_example
Maik Merten
maikmerten at gmx.net
Thu Sep 27 10:10:26 PDT 2007
Hi Jim,
in general for Theora-only playback I'd advise looking at dump_video.c -
that one does take care to only process Theora streams.
I haven't looked closely but I guess just disabling the Vorbis header
check may result in Vorbis data later on getting stuffed into the Theora
decoder - albeit in your case I guess the decoder may have some PowerPC
related problems.
Maik
Mayer, Jim schrieb:
> I’m interested in ignoring the audio stream in a theora encoded file.
> My first attempt was to remove the test for vorbis:
>
>
>
> /* identify the codec: try theora */
>
> if(!theora_p && theora_decode_header(&ti,&tc,&op)>=0){
>
> /* it is theora */
>
> memcpy(&to,&test,sizeof(test));
>
> theora_p=1;
>
> }else if(!vorbis_p && vorbis_synthesis_headerin(&vi,&vc,&op)>=0){
>
> /* it is vorbis */
>
> memcpy(&vo,&test,sizeof(test));
>
> vorbis_p=1;
>
> }else{
>
> /* whatever it is, we don't care about it */
>
> ogg_stream_clear(&test);
>
> }
>
>
>
> I simply commented out the “else if (! vorbis_p &&” line.
>
>
>
> Unfortunately, the resulting executable displayed a green rectangle and,
> when interrupted, crashes. Clearly I am doing something very wrong!
>
>
>
> Any thoughts? I’m quite new to Theora.
>
>
>
> Thanks.
>
>
>
> -- Jim
>
>
>
>
> ------------------------------------------------------------------------
>
> _______________________________________________
> theora mailing list
> theora at xiph.org
> http://lists.xiph.org/mailman/listinfo/theora
More information about the theora
mailing list