This version is selected after a lot of testing by @thomasjohansen and seams to be the only version that works with both images and videos.