I've been trying to get the screen size with <Windows.h>'s GetDeviceCaps(GetDC(NULL), HORZRES) function, but whenever I run the code, it always returns exactly half of my screen resolution.
Does anyone know why this may happen to my computer? It works fine on most other monitors.
My screen resolution is (2736x1824) (surface pro).
#include <Windows.h>
#include <iostream>
int main()
{
HDC display = GetDC(NULL);
const int x = GetDeviceCaps(display, HORZRES), y = GetDeviceCaps(display, VERTRES); //returns (1368, 912)
std::cout << x << ", " << y << "\n";
system("pause");
return 0;
}