[FFmpeg-devel] [PATCH v4] gdigrab: Allow capturing a window by its handle

2023-12-17 Thread Lena via ffmpeg-devel
Added more context in the error message and did a final test that it all works. Thanks for the smooth patch submission process! x11grab can capture windows by their ID, but gdigrab can only capture windows by their names, internally calling FindWindowW to lookup its handle. This patch simply a

[FFmpeg-devel] [PATCH v3] gdigrab: Allow capturing a window by its handle

2023-12-14 Thread Lena via ffmpeg-devel
Updated the wording of the documentation, and added error checking for strtol. I looked at how other parts of the codebase check for errors on strtol and implemented it that way (iec61883, filter_units_bsf, etc). As for checking if the string value is larger/smaller than a long, i don't think t

[FFmpeg-devel] [PATCH v2] gdigrab: Allow capturing a window by its handle

2023-12-12 Thread Lena via ffmpeg-devel
Added the change to the documentation and added error checking on `strtol`, according to the stdlib documentation. The documentation for `strtol` says that on error, 0 is returned. This makes it impossible to specify a window handle of 0 (the whole desktop), but that case is already covered by

Re: [FFmpeg-devel] [PATCH] gdigrab: Allow capturing a window by its handle

2023-12-10 Thread Lena via ffmpeg-devel
x11grab can capture windows by their ID, but gdigrab can only capture windows by their names, internally calling FindWindowW to lookup its handle. This patch simply allows the user to specify a window handle directly. Signed-off-by: Lena --- libavdevice/gdigrab.c | 6 +- 1 file changed, 5 i

Re: [FFmpeg-devel] [PATCH] gdigrab: Allow capturing a window by its handle

2023-12-10 Thread Lena via ffmpeg-devel
I'm so sorry, will resend immediately. Andreas Rheinhardt via ffmpeg-devel: Lena via ffmpeg-devel: x11grab can capture windows by their ID, but gdigrab can only capture windows by their names, internally calling FindWindowW to lookup its handle. This patch simply allows the user to sp

[FFmpeg-devel] [PATCH] gdigrab: Allow capturing a window by its handle

2023-12-10 Thread Lena via ffmpeg-devel
x11grab can capture windows by their ID, but gdigrab can only capture windows by their names, internally calling FindWindowW to lookup its handle. This patch simply allows the user to specify a window handle directly. Signed-off-by: Lena --- libavdevice/gdigrab.c | 6 +- 1 file changed, 5