Skip to main content
gamedev.net
🔒 Locked

DirectX 8 Tutorial

Started by Dez 6 replies 1.5k views
Original Post
Dez
Dez
Hey all, I''ve been trying to get the DX8 "Meshes" tutorial to run, but I keep getting errors: --------------------Configuration: Meshes - Win32 Debug-------------------- Compiling... Meshes.cpp C:\MSDEV\INCLUDE\d3dx8math.inl(1107) : error C2065: ''sqrtf'' : undeclared identifier C:\MSDEV\INCLUDE\d3dx8math.inl(1107) : error C2064: term does not evaluate to a function C:\MSDEV\INCLUDE\d3dx8math.inl(1239) : error C2064: term does not evaluate to a function C:\MSDEV\INCLUDE\d3dx8math.inl(1384) : error C2064: term does not evaluate to a function C:\MSDEV\INCLUDE\d3dx8math.inl(1554) : error C2064: term does not evaluate to a function Error executing cl.exe. Meshes.obj - 5 error(s), 0 warning(s) What is wrong with this? Is it the version of C++ (MS Visual C++ 4) or is it something wrong with DirectX? I''d really like to know why this is happening to me, and (from what I can tell) only me...
Julio
Julio
your either not including d3dx8math.h, or your not linking the appriate libraries.

JoeMont001@aol.com www.polarisoft.n3.net
My HomepageSome shoot to kill, others shoot to mame. I say clear the chamber and let the lord decide. - Reno 911
DmGoober
DmGoober
Hit project, setting, link tab.

Make sure you have the following libraries in the object/library models box:
d3dx8dt.lib d3d8.lib d3dxof.lib

Also, make sure "include " is at the top of the file or is in the header file for the file that is creating the error.

You may want to think about upgrading to studio 6. . . it really has no bearing on this particular issue, but it will allow you to load .dsw files that come with the SDK, which will include all of the correct libraries for you.

Hope this helps.

DmGoober
Alexander "DmGoober" Jhinalexjh@online.microsoft.com[Warning! This email account is not attended. All comments are the opinions of an individual employee and are not representative of Microsoft Corporation.]
Grugnorr
Grugnorr
I´m not 100% sure, but I´read in the DX8.0 docs that you need at least VC++5.0 "Upgrade 3 " to work with it.There´s an internet direction where to get the "Upgrade 3" where it says that.I´ll serach for it in the COMPILER "stuff" of the docs.I´m afraid you won´t be able to work with VC++ 4.0 Sorry =(

What the hells!
What the hells!
Dez
Dez
Thanks everyone, I couldn''t get it to work though.

I''m going to put DirectX "on the shelf" for a while, and practice some other stuff for a while... Until I get a newer version of VC++... Anyway, thanks again.
michiwalter
michiwalter
Hi you,

I don''t know if I miss the point, but I think you''ve got only to add a

#define sqrtf sqrt

in your math.h or somewhere else BEFORE INCLUDING the d3d.h.

What do you think???

Bye,
Michael
ZomeonE
ZomeonE
quote:
Original post by michiwalter

Hi you,

I don''t know if I miss the point, but I think you''ve got only to add a

#define sqrtf sqrt

in your math.h or somewhere else BEFORE INCLUDING the d3d.h.

What do you think???

Bye,
Michael


sqrtf uses floats, sqrt does not

Topic Locked

This topic has been locked by a moderator. New replies are not allowed.

Sign in to reply to this topic.