You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-08-10 06:10:52 +02:00
Revert "lavc/utils: Do not require dimensions for PNG."
mplayer-specifc hacks should not be in our codebase. mplayer should fix
its own code. It is not our responsibility to work around their broken
code.
This reverts commit e8e575633f
.
Signed-off-by: Derek Buitenhuis <derek.buitenhuis@gmail.com>
This commit is contained in:
@@ -1531,9 +1531,7 @@ int attribute_align_arg avcodec_open2(AVCodecContext *avctx, const AVCodec *code
|
|||||||
} else if (avctx->channel_layout) {
|
} else if (avctx->channel_layout) {
|
||||||
avctx->channels = av_get_channel_layout_nb_channels(avctx->channel_layout);
|
avctx->channels = av_get_channel_layout_nb_channels(avctx->channel_layout);
|
||||||
}
|
}
|
||||||
if(avctx->codec_type == AVMEDIA_TYPE_VIDEO &&
|
if(avctx->codec_type == AVMEDIA_TYPE_VIDEO) {
|
||||||
avctx->codec_id != AV_CODEC_ID_PNG // For mplayer
|
|
||||||
) {
|
|
||||||
if (avctx->width <= 0 || avctx->height <= 0) {
|
if (avctx->width <= 0 || avctx->height <= 0) {
|
||||||
av_log(avctx, AV_LOG_ERROR, "dimensions not set\n");
|
av_log(avctx, AV_LOG_ERROR, "dimensions not set\n");
|
||||||
ret = AVERROR(EINVAL);
|
ret = AVERROR(EINVAL);
|
||||||
|
Reference in New Issue
Block a user