Skip to main content
gamedev.net
🔒 Locked

EnumDisplaySettings returns junk

Started by Decept Nov 5, 2004 at 5:06 AM 0 replies 700+ views
Original Post
Decept
Decept
Hi, I'm programming a game in VC++6 using Win32 and GDI. Everything works fine on several computers, but on one old Pentium 120MHz the function EnumDisplaySettings() returns junk. I'm using the function like this: DEVMODE devMode; memset( &devMode, 0, sizeof(DEVMODE) ); devMode.dmSize = sizeof(DEVMODE); devMode.dmDriverExtra = 0; EnumDisplaySettings( NULL, ENUM_CURRENT_SETTINGS, &devMode ); The function never returns an error, I've checked that. But the variables in the DEVMODE struct are filled with random junk. here's an example result: devMode.dmBitsPerPel: 16752 devMode.dmPelsWidth: 0 devMode.dmPelsHeight: 16229 the devMode.dmFields says that these variables have been filled. specs: Pentium 120MHz 32 MB ram 2 MB Video memory (shared with the RAM) 400 MB Harddrive Win95B

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.