Opened 11 days ago

#10978 new defect

gdigrab + hwnd doesn't seem to work

Reported by: Zhuo Zhang Owned by:
Priority: normal Component: avdevice
Version: unspecified Keywords:
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no

Description

Summary of the bug:
How to reproduce:

% ffmpeg -f gdigrab -framerate 30 -i hwnd=984566 test_hwnd.mp4
ffmpeg -version
ffmpeg version 7.0-full_build-www.gyan.dev Copyright (c) 2000-2024 the FFmpeg developers
built with gcc 13.2.0 (Rev5, Built by MSYS2 project)

Patches should be submitted to the ffmpeg-devel mailing list and not this bug tracker.

984566 is a valid window handle I got from win32gui.EnumWindows function. The specific error log was,
[gdigrab @ 0000029ed0543580] Invalid window handle '984566', must be a valid integer.
[in#0 @ 0000029ed0527600] Error opening input: Invalid argument

I believe https://github.com/FFmpeg/FFmpeg/blame/master/libavdevice/gdigrab.c#L287 always ends with this error. Let me know if this is a bug. Thanks!

Change History (0)

Note: See TracTickets for help on using tickets.