On 23/04/14 00:58, Ben Ockmore wrote: > But isn't that the point of the following line? > > int stream_no = av_find_best_stream(format_context,AVMEDIA_TYPE_AUDIO,-1,-1, > NULL,0);
It tells you which is the best audio stream, nothing else. > Shouldn't this already be giving me the correct stream, even if there are > others? I also tried setting the stream number of the packet based on the > result of that function, and it didn't fix the problem. Yes but if you do not set the discard correctly the demuxer would return you all the packets nonetheless. > If this isn't the way to do things, how can I exclude non-audio frames from > being decoded? Setting all the other streams to AVDISCARD_ALL or rejecting manually the packets from the other streams. > Also, any thoughts on the "low score" frame header issue? You are passing a jpeg image to the flac decoder and the decoder is doing its best to figure out what to do with it ^^; lu _______________________________________________ libav-api mailing list [email protected] https://lists.libav.org/mailman/listinfo/libav-api
