|Reported by:||Michael Koch||Owned by:|
|Blocking:||Reproduced by developer:||no|
|Analyzed by developer:||no|
I suggest to add the following to the documentation of the find_rect video filter:
-- If the input video contains multiple instances of the object, find_rect will find only one of them.
-- threshold = 0.01 means only exact matches, threshold = 0.99 means almost everything matches
-- find_rect writes the result to these internal variables:
lavfi.rect.w width of object
lavfi.rect.h height of object
lavfi.rect.x x position of object
lavfi.rect.y y position of object
-- If the threshold value isn't met, then these variables aren't written to.
-- It is possible to write these variables to a file with ffprobe and -show_entries
Find the position of an object in each frame and write it to a log file:
ffprobe -f lavfi movie=test.mp4,find_rect=object=object.pgm:threshold=0.3 -show_entries
frame=pkt_pts_time:frame_tags=lavfi.rect.x,lavfi.rect.y -of csv 1> log.csv
Suggestion for improvement:
Please make also the internal variable "best_score" available, so that it can be written to the log file as well.