Click here to Skip to main content
15,886,037 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
I'm trying to make a DLL in c++ for GameMaker, it needs to change the display resolution. I'm clueless on how to do it the only way I know of is that it involves ChangeDisplaySettings() and EnumDisplaySettings() functions and the use of a structure known as DevMode. May someone please provide a working, errorless, code snippet as an example on how to do what I'm looking for? In case you are wondering I mainly work with window manipulation, so this is a big task for me to figure out via trial and error, as it is something I've never worked with.

An exported function like this would be nice:

C++
#include "stdafx.h"
#include "mainheaderfile.h"
//any needed includes or imports here please and thank you. :)
#define DLL extern "C" _declspec(dllexport)

DLL double ChangeDisplayResolution(int width, int height)
{
//your code snippet here please and thank you. :)
return 0;
}


Thanks!
TKG
Posted
Comments
[no name] 31-Aug-12 14:17pm    
Okay so.... if I were to take this job, and I am not saying that I will, how much are you paying someone to write this code for you? When does the project need to be delivered? What OS(s) need to be supported? How are you going to be making payments? Any other project requirements?

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900