AVStream.codec is deprecated
Signed-off-by: Reynaldo H. Verdejo Pinochet <reynaldo@osg.samsung.com>
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
... | ... |
@@ -1990,11 +1990,11 @@ static void compute_status(HTTPContext *c) |
1990 | 1990 |
|
1991 | 1991 |
for(i=0;i<stream->nb_streams;i++) { |
1992 | 1992 |
AVStream *st = stream->streams[i]; |
1993 |
- AVCodec *codec = avcodec_find_encoder(st->codec->codec_id); |
|
1993 |
+ AVCodec *codec = avcodec_find_encoder(st->codecpar->codec_id); |
|
1994 | 1994 |
|
1995 |
- switch(st->codec->codec_type) { |
|
1995 |
+ switch(st->codecpar->codec_type) { |
|
1996 | 1996 |
case AVMEDIA_TYPE_AUDIO: |
1997 |
- audio_bit_rate += st->codec->bit_rate; |
|
1997 |
+ audio_bit_rate += st->codecpar->bit_rate; |
|
1998 | 1998 |
if (codec) { |
1999 | 1999 |
if (*audio_codec_name) |
2000 | 2000 |
audio_codec_name_extra = "..."; |
... | ... |
@@ -2002,7 +2002,7 @@ static void compute_status(HTTPContext *c) |
2002 | 2002 |
} |
2003 | 2003 |
break; |
2004 | 2004 |
case AVMEDIA_TYPE_VIDEO: |
2005 |
- video_bit_rate += st->codec->bit_rate; |
|
2005 |
+ video_bit_rate += st->codecpar->bit_rate; |
|
2006 | 2006 |
if (codec) { |
2007 | 2007 |
if (*video_codec_name) |
2008 | 2008 |
video_codec_name_extra = "..."; |
... | ... |
@@ -2010,7 +2010,7 @@ static void compute_status(HTTPContext *c) |
2010 | 2010 |
} |
2011 | 2011 |
break; |
2012 | 2012 |
case AVMEDIA_TYPE_DATA: |
2013 |
- video_bit_rate += st->codec->bit_rate; |
|
2013 |
+ video_bit_rate += st->codecpar->bit_rate; |
|
2014 | 2014 |
break; |
2015 | 2015 |
default: |
2016 | 2016 |
abort(); |
... | ... |
@@ -2107,9 +2107,9 @@ static void compute_status(HTTPContext *c) |
2107 | 2107 |
if (c1->stream) { |
2108 | 2108 |
for (j = 0; j < c1->stream->nb_streams; j++) { |
2109 | 2109 |
if (!c1->stream->feed) |
2110 |
- bitrate += c1->stream->streams[j]->codec->bit_rate; |
|
2110 |
+ bitrate += c1->stream->streams[j]->codecpar->bit_rate; |
|
2111 | 2111 |
else if (c1->feed_streams[j] >= 0) |
2112 |
- bitrate += c1->stream->feed->streams[c1->feed_streams[j]]->codec->bit_rate; |
|
2112 |
+ bitrate += c1->stream->feed->streams[c1->feed_streams[j]]->codecpar->bit_rate; |
|
2113 | 2113 |
} |
2114 | 2114 |
} |
2115 | 2115 |
|