Jump to content

  • Log In with Google      Sign In   
  • Create Account

FREE SOFTWARE GIVEAWAY

We have 4 x Pro Licences (valued at $59 each) for 2d modular animation software Spriter to give away in this Thursday's GDNet Direct email newsletter.


Read more in this forum topic or make sure you're signed up (from the right-hand sidebar on the homepage) and read Thursday's newsletter to get in the running!


need help with old code and today software


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
2 replies to this topic

#1 romul_0001   Members   -  Reputation: 102

Like
0Likes
Like

Posted 15 January 2013 - 09:51 AM


hi there!
im total newbe and have a problem.iv got Andre Lamothe book "tricks of windows game programming gurus" and when im compiling first example in this book ive got errors:

Warning 1 warning C4101: 'ps' : unreferenced local variable
Warning 2 warning C4101: 'hdc' : unreferenced local variable
Error 4 error LNK2019: unresolved external symbol _DirectDrawCreateEx@16 referenced in function "int __cdecl DD_Init(int,int,int)" (?DD_Init@@YAHHHH@Z)
Error 5 error LNK1120: 1 unresolved externals

and some more.but if go to project properties and change character set from Unicode to multibyte I end with errors 4 and 5 only.

now the book is from 2002 so the .cpp files and Im using visual studio 2012 express with windows 8 with directx sdk that comes with it.
I don't see ddraw.lib in sdk folder and don't know what to do and how to resolve the errors above
any help please will be appreciated
thank you

 

source files:

Attached Files


Edited by romul_0001, 15 January 2013 - 09:51 AM.


Sponsor:

#2 HAM   Members   -  Reputation: 176

Like
0Likes
Like

Posted 15 January 2013 - 12:29 PM

The warnings don't really matter.

The errors are link errors. If you look at the documents page for DirectDrawCreatEx you'll find what lib you need: http://msdn.microsoft.com/en-us/library/windows/desktop/gg426116(v=vs.85).aspx

Then in the project settings, linker section, make sure you are linking to that lib.

However, I honestly don't even know if DirectDraw functions are still part of directX sdk. That is pretty old stuff. But I suppose it would still be in the libs for directX 9.c

#3 Burnt_Fyr   Members   -  Reputation: 1249

Like
0Likes
Like

Posted 15 January 2013 - 02:22 PM

AFAIK Direct Draw was depreciated in dx8, and removed altogether from dx9(someone with better knowledge can correct my timeframes). You will either need to procure an older SDK, or attempt to port the code to a different api, such as the more modern dx11






Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS