mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2024-12-23 12:43:46 +02:00
Avoid mixed declaration and code, fix C89 compatibility.
Patch by François Revol revol free fr. Originally committed as revision 23143 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
parent
9121b8ca6c
commit
65929418f5
4
ffplay.c
4
ffplay.c
@ -1565,7 +1565,7 @@ static int input_get_buffer(AVCodecContext *codec, AVFrame *pic)
|
|||||||
AVFilterContext *ctx = codec->opaque;
|
AVFilterContext *ctx = codec->opaque;
|
||||||
AVFilterPicRef *ref;
|
AVFilterPicRef *ref;
|
||||||
int perms = AV_PERM_WRITE;
|
int perms = AV_PERM_WRITE;
|
||||||
int w, h, stride[4];
|
int i, w, h, stride[4];
|
||||||
unsigned edge;
|
unsigned edge;
|
||||||
|
|
||||||
if(pic->buffer_hints & FF_BUFFER_HINTS_VALID) {
|
if(pic->buffer_hints & FF_BUFFER_HINTS_VALID) {
|
||||||
@ -1587,7 +1587,7 @@ static int input_get_buffer(AVCodecContext *codec, AVFrame *pic)
|
|||||||
|
|
||||||
ref->w = codec->width;
|
ref->w = codec->width;
|
||||||
ref->h = codec->height;
|
ref->h = codec->height;
|
||||||
for(int i = 0; i < 3; i ++) {
|
for(i = 0; i < 3; i ++) {
|
||||||
unsigned hshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_w;
|
unsigned hshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_w;
|
||||||
unsigned vshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_h;
|
unsigned vshift = i == 0 ? 0 : av_pix_fmt_descriptors[ref->pic->format].log2_chroma_h;
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user