- w->is_live ? (stream->codec->codec_type == AVMEDIA_TYPE_AUDIO ? "128000" : "1000000") : bandwidth->value);
- if (stream->codec->codec_type == AVMEDIA_TYPE_VIDEO && output_width)
- avio_printf(s->pb, " width=\"%d\"", stream->codec->width);
- if (stream->codec->codec_type == AVMEDIA_TYPE_VIDEO && output_height)
- avio_printf(s->pb, " height=\"%d\"", stream->codec->height);
- if (stream->codec->codec_type == AVMEDIA_TYPE_AUDIO && output_sample_rate)
- avio_printf(s->pb, " audioSamplingRate=\"%d\"", stream->codec->sample_rate);
+ w->is_live ? (stream->codecpar->codec_type == AVMEDIA_TYPE_AUDIO ? "128000" : "1000000") : bandwidth->value);
+ if (stream->codecpar->codec_type == AVMEDIA_TYPE_VIDEO && output_width)
+ avio_printf(s->pb, " width=\"%d\"", stream->codecpar->width);
+ if (stream->codecpar->codec_type == AVMEDIA_TYPE_VIDEO && output_height)
+ avio_printf(s->pb, " height=\"%d\"", stream->codecpar->height);
+ if (stream->codecpar->codec_type == AVMEDIA_TYPE_AUDIO && output_sample_rate)
+ avio_printf(s->pb, " audioSamplingRate=\"%d\"", stream->codecpar->sample_rate);