Problem with DrawText (DirectX9)

This is a discussion on Problem with DrawText (DirectX9) within the C++ Programming forums, part of the General Programming Boards category; Im trying to compile http://www.codeproject.com/directx/d...&select=146195 with Microsoft Visual C++ 6 But its giving me --------------------Configuration: project - Win32 Debug-------------------- Compiling... ...

  1. #1
    Registered User
    Join Date
    Feb 2006
    Posts
    17

    Problem with DrawText (DirectX9)

    Im trying to compile http://www.codeproject.com/directx/d...&select=146195 with Microsoft Visual C++ 6

    But its giving me

    --------------------Configuration: project - Win32 Debug--------------------
    Compiling...
    dx9_fonts.cpp
    C:\Sander\dx9_fonts\dx9_fonts.cpp(201) : error C2660: 'D3DXCreateFont' : function does not take 12 parameters
    C:\Sander\dx9_fonts\dx9_fonts.cpp(248) : error C2660: 'DrawTextA' : function does not take 6 parameters
    C:\Sander\dx9_fonts\dx9_fonts.cpp(251) : error C2660: 'DrawTextA' : function does not take 6 parameters
    C:\Sander\dx9_fonts\dx9_fonts.cpp(254) : error C2660: 'DrawTextA' : function does not take 6 parameters
    Error executing cl.exe.

    project.exe - 4 error(s), 0 warning(s)
    Why? In MSDN D3DXCreateFont does have 12 params...

    Is there an easy way to do something like DrawText but then in OpenGL?

  2. #2
    Peace
    Join Date
    Aug 2001
    Posts
    1,510
    Your most likely cause for these errors is that your version of the SDK is either more updated than the code (or vice versa) and the updates contain altered function parameters. Check your local help files (not the online help which may differ), and if in doubt, locate the actual functions in question in the SDK and inspect the calling parameters.
    "There's always another way"
    -lightatdawn (lightatdawn.cprogramming.com)

  3. #3
    Registered User
    Join Date
    Feb 2006
    Posts
    17
    Thanks u ill try that
    Another q, since i find opengl a little bit easier, is there a similar function like drawtext in OpenGL?

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. Need help understanding a problem
    By dnguyen1022 in forum C++ Programming
    Replies: 2
    Last Post: 04-29-2009, 05:21 PM
  2. Memory problem with Borland C 3.1
    By AZ1699 in forum C Programming
    Replies: 16
    Last Post: 11-16-2007, 11:22 AM
  3. Someone having same problem with Code Block?
    By ofayto in forum C++ Programming
    Replies: 1
    Last Post: 07-12-2007, 09:38 AM
  4. A question related to strcmp
    By meili100 in forum C++ Programming
    Replies: 6
    Last Post: 07-07-2007, 03:51 PM
  5. WS_POPUP, continuation of old problem
    By blurrymadness in forum Windows Programming
    Replies: 1
    Last Post: 04-20-2007, 07:54 PM

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21