This website works better with JavaScript.
Home
Help
Sign In
falkTX
/
FFmpeg
mirror of
https://github.com/falkTX/FFmpeg.git
Watch
1
Star
0
Fork
0
Code
Issues
0
Releases
338
Wiki
Activity
Browse Source
pgmyuvenc: abort encoding if width is not even
Signed-off-by: Paul B Mahol <onemda@gmail.com> Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
tags/n0.11
Paul B Mahol
Michael Niedermayer
14 years ago
parent
eb74e9ea10
commit
a41340f8e8
1 changed files
with
4 additions
and
0 deletions
Split View
Diff Options
Show Stats
Download Patch File
Download Diff File
+4
-0
libavcodec/pnmenc.c
+ 4
- 0
libavcodec/pnmenc.c
View File
@@ -71,6 +71,10 @@ static int pnm_encode_frame(AVCodecContext *avctx, AVPacket *pkt,
n = avctx->width * 6;
break;
case PIX_FMT_YUV420P:
if (avctx->width & 1) {
av_log(avctx, AV_LOG_ERROR, "pgmyuv needs even width\n");
return AVERROR(EINVAL);
}
c = '5';
n = avctx->width;
h1 = (h * 3) / 2;
Write
Preview
Loading…
Cancel
Save