Is there an application or online service that is able to find a position (either as a frame number or time from film beginning) in a film by a frame from that film, represented as standalone picture (even if that picture was converted, resized, cropped, etc.)?

  • 1
    If you leave out the cropped scenario, then ffmpeg could do this using a combination of the blend and blackdetect filters
    – Gyan
    Commented Oct 15, 2016 at 8:58
  • What do you mean by 'leave out the cropped scenario'?
    – green
    Commented Oct 15, 2016 at 11:51
  • Looks possible for uncropped images
    – Gyan
    Commented Oct 15, 2016 at 18:14
  • But if I know position (X,Y) of the cropped image in the frame, then I can crop entire film, like the frame was cropped) and make the procedure?
    – green
    Commented Oct 15, 2016 at 19:31
  • What maximum divergence between the image and actual frame in the film, with which the input data can be processed successfully?
    – green
    Commented Oct 15, 2016 at 19:39

1 Answer 1


Try the command:

ffmpeg -i in.mp4 -loop 1 -i croppedframe.jpg -an -filter_complex "[0]crop=w:h:x:y[a];[1][a]blend=difference,blackframe=90:32" -f null - 

This will match a movie frame if at least 90% of the pixels have a difference in value of less than 32 with the image. Any such matching frames will have their timestamps shown

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.