This is a problem compiling a windows program with DevCPP. I have included <wingdi.h> which declares GetStockObject, and it says nothing about the file beeing missing... Is it something with @4?
This is a problem compiling a windows program with DevCPP. I have included <wingdi.h> which declares GetStockObject, and it says nothing about the file beeing missing... Is it something with @4?
Did you create a Windows Project, instead of a Console one?
Your error has to do with linking, it can find the prototype in your header files (.h), but it can't find the definition in your library files (.a).
So re-create your project as a Windows one, or add this to your linker options. (I suggest the former).
Code:-lgdi32
Unless you have very specific requirements, I would include windows.h rather then the individual lower level headers.
Wave upon wave of demented avengers march cheerfully out of obscurity unto the dream.
The windows.h that comes with devcpp doesn't define GetStockObject but wingdi.h does. I thought the headers would also tell were the actual functions were located ie, gdi32.dll... But i'll do as you said..Thanks
Now it's the DirectX func Direct3DCreate9 that won't work, obviously because calls are made to some DX dlls that my app don't mention, but were should I mention them?
Good luck getting DirectX to work with Dev-C++. I have heard of legendary heroes managing this feat, but only after hours of tweaking and configuring Dev-C++.Now it's the DirectX func Direct3DCreate9 that won't work, obviously because calls are made to some DX dlls that my app don't mention, but were should I mention them?
Getting DirectX 8.1 to Work with Dev-C++
Edit:
Could be useful. Or maybe not: DirectX 9.0 devpak
Last edited by Dante Shamest; 03-29-2005 at 02:34 PM.
Hrm.. I just thought it was a matter of specifiyng what libs and functions in those libs which would all follow the ANSI C and windows standards.. but I guess microsoft don't want directx to work with rival compilers, allthough they do provide that free compiler ripped out from previous visual studio release that's posted Sticky here...