diff flvdec.c @ 5945:0abde6943674 libavformat

Set audio bit rate. Patch by Howard Chu, hyc highlandsun com
author cehoyos
date Sun, 11 Apr 2010 12:21:30 +0000
parents 1fec9e2cd5c5
children 12bdd63f5259
line wrap: on
line diff
--- a/flvdec.c	Sun Apr 11 00:43:36 2010 +0000
+++ b/flvdec.c	Sun Apr 11 12:21:30 2010 +0000
@@ -195,6 +195,8 @@
             if(!strcmp(key, "duration")) s->duration = num_val * AV_TIME_BASE;
             else if(!strcmp(key, "videodatarate") && vcodec && 0 <= (int)(num_val * 1024.0))
                 vcodec->bit_rate = num_val * 1024.0;
+            else if(!strcmp(key, "audiodatarate") && acodec && 0 <= (int)(num_val * 1024.0))
+                acodec->bit_rate = num_val * 1024.0;
         } else if (amf_type == AMF_DATA_TYPE_STRING)
           av_metadata_set(&s->metadata, key, str_val);
     }