[FFmpeg-devel] [PATCH] ffprobe: report audio bit rate in stream description

Michael Niedermayer michaelni at gmx.at
Sat Feb 18 04:34:30 CET 2012


On Sat, Feb 18, 2012 at 01:04:48AM +0100, Stefano Sabatini wrote:
> On date Wednesday 2012-02-15 05:05:50 +0100, Michael Niedermayer encoded:
> > On Thu, Feb 09, 2012 at 07:06:42PM +0100, Stefano Sabatini wrote:
> [...]
> > >  #if FF_API_AVCODEC_OPEN
> > >  int attribute_align_arg avcodec_open(AVCodecContext *avctx, AVCodec *codec)
> > >  {
> > > @@ -865,6 +888,8 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, AVCodec *codec, AVD
> > >              avctx->channels = av_get_channel_layout_nb_channels(avctx->channel_layout);
> > >          }
> > >      }
> > > +    if (!avctx->bit_rate)
> > > +        avctx->bit_rate = get_bit_rate(avctx);
> > >  
> > >      avctx->pts_correction_num_faulty_pts =
> > >      avctx->pts_correction_num_faulty_dts = 0;
> > 
> 
> > iam not sure if this is safe or may interfere with an encoder because
> > i think this is run also for encoders
> 
> Right, added constraint on the codec type, also moved the check
> *after* the init stage since it seems more correct that way (even if
> it should make no difference).
> 
> > otherwise i think its ok if it passes fate
> 
> FATE seems to work here.

LGTM

thx

[..]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The real ebay dictionary, page 2
"100% positive feedback" - "All either got their money back or didnt complain"
"Best seller ever, very honest" - "Seller refunded buyer after failed scam"
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 198 bytes
Desc: Digital signature
URL: <http://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20120218/c9b485b7/attachment.asc>


More information about the ffmpeg-devel mailing list