xrandx responds with too many modes.

Peter Dons Tychsen donpedro at tdcadsl.dk
Thu Jan 3 18:49:25 CST 2008

The xrandx X11 extension is very handy.
Using it for wine makes great sense.

But... the extension also enumerates a whopping amount of modes.
Each resolution has a multitude of frequencies and bit-depth variants.

Some applications are simply not prepared for that magnitude of
information when they call EnumDisplaySettings() (user32) or
EnumDisplayModes (ddraw).

When using "normal" windows, only a few modes are returned.

I know its not a bug, as it could happen on Windows if someone published
a driver which implemented tons of silly and crooked modes.

Would it be acceptable to insert a filter in xrandx.c (X11-drv),
which only allowed "normal" windows resolutions to be enumerated?
Does anyone need those awkward ones? 

The filter would look allot like the one in desktop.c (X11-drv) which is
currently used by the desktop mode.

I already fixed a portion of the bugs caused by this, as there was a 
natural limitation which should be set by EnumDisplayModes() which was
not honored. I sent in patch for this already. So at least now we can
play the classic "Grand Theft Auto"....



More information about the wine-devel mailing list