]> git.sesse.net Git - ffmpeg/blobdiff - libavfilter/vf_w3fdif.c
lavfi/vf_lut3d: convert to framesync2.
[ffmpeg] / libavfilter / vf_w3fdif.c
index b7872db341929ca2bfee512553337bb9969b30eb..c6a65507784c6fd13e4f44877e424ad22c57d9ab 100644 (file)
@@ -366,7 +366,7 @@ static int deinterlace_slice(AVFilterContext *ctx, void *arg, int jobnr, int nb_
     int j, y_in, y_out;
 
     /* copy unchanged the lines of the field */
-    y_out = start + (s->field == cur->top_field_first) - (start & 1);
+    y_out = start + ((s->field == cur->top_field_first) ^ (start & 1));
 
     in_line  = cur_data + (y_out * cur_line_stride);
     out_line = dst_data + (y_out * dst_line_stride);
@@ -379,7 +379,7 @@ static int deinterlace_slice(AVFilterContext *ctx, void *arg, int jobnr, int nb_
     }
 
     /* interpolate other lines of the field */
-    y_out = start + (s->field != cur->top_field_first) - (start & 1);
+    y_out = start + ((s->field != cur->top_field_first) ^ (start & 1));
 
     out_line = dst_data + (y_out * dst_line_stride);