Добрый вечер. Сделал получение всех возможных разрешений экрана, но штука в том, что я получаю одинаковые. Вот:
640x480 65536 Colors
640x480 65536 Colors
640x480 65536 Colors
640x480 65536 Colors
...
Почему? Код такой:
Код:
procedure TFormY.FormCreate(Sender: TObject);
var
cnt : Integer;
DevMode : TDevMode;
begin
{Получаем список разрешений...}
cnt := 0;
while EnumDisplaySettings(nil,cnt,DevMode) do
begin with Devmode do begin
if (Int64(1) shl dmBitsperPel) >65536 then //Отсеиваем дурацкие и дублированные разрешения.
Memo1.Lines.Add(Format('%dx%d %d Colors', [dmPelsWidth,dmPelsHeight,Int64(1) shl dmBitsperPel]));
Inc(cnt);
sprev:=(Format('%dx%d %d Colors', [dmPelsWidth,dmPelsHeight,Int64(1) shl dmBitsperPel])); end; end;
end;