But it's not originally made from FFmpeg but libav. One day later after pushed to libav, my two patches got merged into FFmpeg.

Never heard of libav? Neither did I before until I read this thread FFmpeg-devel, then I decided to submit on libav-devel.

I got immediate response and many pointers about my code. I did wrote silly code, you can read my threads followmouse-1, followmouse-2, and showregion.

Basically, you can use
-f x11grab [-follow_mouse centered|PIXELS] [-show_region 1] ...
to enable these two options. You can see a video about them, but I changed they style, it's now dashed line box, not the solid lines as you see in that video.

Go grab FFmpeg or libav, if you can't wait.

(I did get a reply on FFmpeg-devel after the merge)