提交 96320336 编写于 作者: B Benoit Fouet

Merge declaration and assignment.

Originally committed as revision 15494 to svn://svn.ffmpeg.org/ffmpeg/trunk
上级 9d2b5cf2
......@@ -98,19 +98,15 @@ static av_cold int build_modpred(Indeo3DecodeContext *s)
static av_cold int iv_alloc_frames(Indeo3DecodeContext *s)
{
int luma_width, luma_height, luma_pixels, chroma_width, chroma_height,
chroma_pixels, i;
unsigned int bufsize;
luma_width = (s->width + 3) & (~3);
luma_height = (s->height + 3) & (~3);
chroma_width = ((luma_width >> 2) + 3) & (~3);
chroma_height = ((luma_height>> 2) + 3) & (~3);
luma_pixels = luma_width * luma_height;
chroma_pixels = chroma_width * chroma_height;
bufsize = luma_pixels * 2 + luma_width * 3 +
(chroma_pixels + chroma_width) * 4;
int luma_width = (s->width + 3) & ~3,
luma_height = (s->height + 3) & ~3,
chroma_width = ((luma_width >> 2) + 3) & ~3,
chroma_height = ((luma_height >> 2) + 3) & ~3,
luma_pixels = luma_width * luma_height,
chroma_pixels = chroma_width * chroma_height,
i;
unsigned int bufsize = luma_pixels * 2 + luma_width * 3 +
(chroma_pixels + chroma_width) * 4;
if(!(s->buf = av_malloc(bufsize)))
return AVERROR(ENOMEM);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册