Thread: Cant Compile GDI+

  1. #1
    Registered User
    Join Date
    Aug 2004
    Posts
    193

    Cant Compile GDI+

    I have downloaded the GDI+ .h, .lib, and .dll files and when I put them in their proper directories (.h in include, .lib in lib, and .dll in application folder), I recieve numerous compiler errors:

    Code:
    534 C:\Dev-Cpp\include\SDK\GdiplusEnums.h use of enum `EmfPlusRecordType' without previous declaration 
    548 C:\Dev-Cpp\include\SDK\GdiplusEnums.h invalid use of undefined type `enum Gdiplus::EmfPlusRecordType' 
    543 C:\Dev-Cpp\include\SDK\GdiplusEnums.h forward declaration of `enum Gdiplus::EmfPlusRecordType' 
    548 C:\Dev-Cpp\include\SDK\GdiplusEnums.h enumerator value for `WmfRecordTypeSetBkColor' not integer constant
    Then there are like 500 or so just like that and it would take me like hours to copy and paste them all, since Dev C++ only allows you to copy one at a time. I'm including <windows.h>, then <GdiPlus.h> and I'm linking GdiPlus.lib. Is there something I'm doing wrong? There could be a slight possibility that I have an improper version of GDI+ because I couldnt find a download anywhere. I had to install SDK to get the files like I read on a tutorial.

    Thanks in advance for any help!!!

  2. #2
    Registered User Dante Shamest's Avatar
    Join Date
    Apr 2003
    Posts
    970
    Dev-C++ uses .a files, so I don't think .lib files will work for it.

  3. #3
    Registered User
    Join Date
    Aug 2004
    Posts
    193
    Well, when I add go to add a .lib file, the "Files of Type:" says "Library (*.a,*.lib)". But if this is the case, where could I download the .a file?

    Thanks.

  4. #4
    erstwhile
    Join Date
    Jan 2002
    Posts
    2,227
    You build it from the redistributable gdiplus.dll with reimp, which is part of mingw-utils.
    CProgramming FAQ
    Caution: this person may be a carrier of the misinformation virus.

  5. #5
    Registered User
    Join Date
    Aug 2004
    Posts
    193
    Thanks for the information. I was able to build the .a file from the .lib file. I couldnt find out how to build it from the .dll file. However, that didnt help me any. Where could I download the most recent/proper header files (because I think thats my problem)?

    Thanks.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. C and C++ compile speed
    By swgh in forum A Brief History of Cprogramming.com
    Replies: 3
    Last Post: 01-02-2007, 02:37 PM
  2. Compile as you type
    By Rocketmagnet in forum A Brief History of Cprogramming.com
    Replies: 33
    Last Post: 12-07-2006, 01:36 PM
  3. How to compile mfc libs from platform sdk
    By tjcbs in forum Windows Programming
    Replies: 6
    Last Post: 11-19-2006, 08:20 AM
  4. Compile crashes certain windows
    By Loduwijk in forum C++ Programming
    Replies: 5
    Last Post: 03-26-2006, 09:05 PM
  5. How can I compile C or C++ with Visual Studio .NET?
    By Dakkon in forum C Programming
    Replies: 8
    Last Post: 02-11-2003, 02:58 PM