83 int h, plane, src_line_step, dst_line_step, line_size,
line;
92 "frame with same field order" :
"progressive frame");
108 "picture will move %s one line\n",
111 for (plane = 0; plane < 4 && frame->
data[plane] && frame->
linesize[plane]; plane++) {
112 dst_line_step = out->
linesize[plane];
113 src_line_step = frame->
linesize[plane];
115 dst = out->
data[plane];
116 src = frame->
data[plane];
123 for (line = 0; line < h; line++) {
125 memcpy(dst, src + src_line_step, line_size);
127 memcpy(dst, src - 2 * src_line_step, line_size);
129 dst += dst_line_step;
130 src += src_line_step;
138 dst += (h - 1) * dst_line_step;
139 src += (h - 1) * src_line_step;
140 for (line = h - 1; line >= 0 ; line--) {
142 memcpy(dst, src - src_line_step, line_size);
144 memcpy(dst, src + 2 * src_line_step, line_size);
146 dst -= dst_line_step;
147 src -= src_line_step;
158 #define OFFSET(x) offsetof(FieldOrderContext, x)
159 #define FLAGS AV_OPT_FLAG_FILTERING_PARAM|AV_OPT_FLAG_VIDEO_PARAM
189 .
name =
"fieldorder",
192 .priv_class = &fieldorder_class,
194 .
inputs = avfilter_vf_fieldorder_inputs,
195 .
outputs = avfilter_vf_fieldorder_outputs,