One pixel horizontal and vertical #000000 lines are added to the bottom and right side of an exported video when Position and Size filter is applied

One pixel horizontal and vertical #000000 lines are added over to the last horizontal line of a video at the bottom and the last vertical line at the right side when I apply Position and Size filter to the video.
E.g. 1080th line at the bottom and 1920th line at the right are replaced by #000000 lines in 1080p resolution.


Steps to reproduce:

  1. Launch Shotcut.
  2. Open a video or image file.
  3. Apply Position and Size filter to the Source or Timeline. In the case of applying it to the Timeline, drag the video or image in the Source to the Timeline pane.
  4. Configure the Position and Size filter settings however you like.
  5. Export the Source or Timeline to a video, using whichever codec and parameters you like.
  6. Watch the exported video on a media player of your choice.

Some notes on the variables I changed to isolate the possible causes in the codes:
a) Only tested in Windows 7 SP1 64bit

b) This happens in both Shotcut Windonws 64bit and 32bit versions.
c) This happens on two PCs of mine with different CPUs.

d) This happens in Shotcut version 18.08.14, 18.07.02, and 18.06.02 but not in 18.05.08 or 18.03.06
e) This happens only when Position and Size filter, Blur filter, or Rotate and Scale filter is applied. It doesn’t happen when no filter, Opacity filter, Brightness filter, Contrast filter, Sharpen filter, or any other keyframable filter is applied.

f) This happens regardless of what configurations I put into the Position and Size filter. Choosing Fit, Fill, Distort, Left, Center, Right, Top, Middle, or Bottom doesn’t change the outcome.
g) This happens regardless of video codecs or container format. Choosing x264, x265, or vp9 for the codec and mp4 or webm for the container fomat doesn’t change the outcome.
h) This happens regardless of the export parameters I set. Choosing 1080p or 480p and 60fps or 30fps doesn’t change the outcome.
i) This happens regardless of the media players I use to play back. Tested on MPC-HC, VLC, and ffmpeg player.

This is not a case of the video or image shifted one pixel upward and leftward. The top and leftmost line are not affected.


These lines are observable in the recent video Dan put out on YouTube “Moto Bay Classic 2018”: https://www.youtube.com/watch?v=MeAQnvJAoOQ

On YouTube:
The lines appear between 0:18 and 0:19 and disappear between 0:34 and 0:35.
The lines appear between 0:49 and 0:50 and disappear between 0:53 and 0:54.
The lines appear between 1:06 and 1:07 and disappear between 1:07 and 1:08.

In Shotcut:
The lines appear between 00:00:18:48 and 00:00:18:49 and disappear between 00:00:34:16 and 00:00:34:17.
The lines appear between 00:00:49:44 and 00:00:49:45 and disappear between 00:00:53:04 and 00:00:53:05.
The lines appear between 00:01:06:24 and 00:01:06:25 and disappear between 00:01:07:32 and 00:01:07:33.

This is due to interpolation. If you choose Nearest Neighbor for Interpolation in Export the issue goes away. I will see if I can exclude non-existing pixels beyond the extents of the image. If you want to work on the problem yourself, a patch is welcome.

This is fixed for the next release v18.09!

1 Like

That’s great! It’s going to be so much fun testing out 18.09.**.