Skip to main content
GameDev.net gamedev.net
🔒 Locked

RGBA_MAKE

Started by amt35 Jan 20, 2005 at 12:30 PM 2 replies 3.3k views
Original Post
amt35
amt35
In my project I use the macro RGBA_MAKE and from what I know I have to include d3dtypes.h to use it. However, when I compile my project I get the following warning: "Should not include d3dtypes.h when compiling for DX8 or newer interfaces" I am using DX9.0 .... So what do I need to include instead of d3dtypes.h to use RGBA_MAKE and get rid of the warning. -Andrew
Mezz
Mezz
Because "d3dtypes.h" is superceded by either "d3d8types.h" or "d3d9types.h", but if you can, it's probably better to just include "d3d9.h" and be done with it unless there is some reason you don't want the other parts of D3D.

Edit:
Looking at the d3dtypes.h header file, it has this in it:

#ifndef DIRECT3D_VERSION#define DIRECT3D_VERSION         0x0700#endif#if (DIRECT3D_VERSION >= 0x0800)#pragma message("should not include d3dtypes.h when compiling for DX8 or newer interfaces")#endif


Which implies that you've already included a D3D8 or D3D9 header somewhere before it. Also, RGBA_MAKE is superceded (and doesn't exist) in the new versions of D3D, the macros you probably want to use now are D3DCOLOR_RGBA, D3DCOLOR_ARGB or D3DCOLOR_XRGB, which provide similar functionality.


-Mezz
Agony
Agony
I didn't even know there was such a thing as RGBA_MAKE(). It isn't actually in the docs, even though it is of course still in the header. What is in the docs is D3DCOLOR_RGBA(), which should be usable just by including .
"We should have a great fewer disputes in the world if words were taken for what they are, the signs of our ideas nly, and not for things themselves." - John Locke o
amt35
amt35
Thanks Mezz,

I already have d3d9.h included.

This is what I have included now:

#include
#include
#include
#include


Any more ideas??

-Andrew

OOOPs... Thanks for the update. I got it.


Thanks again!!!!!!

Topic Locked

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

Sign in to reply to this topic.