Opened 9 years ago

Closed 9 years ago

#4505 closed defect (duplicate)

gdigrab is not dpi-aware

Reported by: Christoph Rackwitz Owned by:
Priority: normal Component: avdevice
Version: unspecified Keywords: gdigrab, windows
Cc: Blocked By:
Blocking: Reproduced by developer: no
Analyzed by developer: no


gdigrab on win8.1 and a dpi-scaled screen will capture a cropped desktop, exactly as much as implied by the dpi scaling factor. on win7, the whole screen is captured.

How to reproduce:

  • use windows 8.1+ (something that does transparent dpi scaling to unaware programs and fakes system parameters)
  • ffmpeg -f gdigrab -framerate 15 -i desktop -c:v qtrle

I'm using an ffmpeg zeranoe build from december 2014.

someone on the internet suggested calling SetProcessDPIAware() (before any win32 graphics code).

a manifest file might be better (see 'race condition' in the previous link).

there's also SetProcessDpiAwareness() as found on

GetDeviceCaps(source_hdc, HORZRES) (or other indices) might alternatively report correct values, or they might not.

Change History (1)

comment:1 by Roger Pack, 9 years ago

Resolution: duplicate
Status: newclosed

Seems to be a dupe of #4232

Note: See TracTickets for help on using tickets.