Hi,
I'm not sure if this is a compiler problem. I have the following in one file:
And this in another:Code:#include <windows.h> #include <windowsx.h> #include <d3d9.h> #include <d3dx9.h> #include "MeshFiles.h"
And I get a redeclaration error. A new file opens up and in it is nothing but a blank screen amd a cursor. It's a directX9 file too. Now I understand it is likely being caused by the same header included in two files, but how on earth can I give each file independent access to the same code when they both need it without causing this error?Code:#include <d3d9.h> #include <d3dx9.h> #include "MeshFiles.h"
Is this a compiler issue? I'm using Code::Blocks has the GNC compiler I think. Anyways, I'm stumped!! Any ideas - can I just lay my code out in a different way to get round this? Thanks
***Edit***
here's the specific error:
Code:obj\Debug\Initialise.o:C:\Program Files\Microsoft DirectX SDK (February 2010)\Include\d3d9types.h|51| multiple definition of `MeshSoldier::load_soldier(IDirect3DDevice9*)'|



LinkBack URL
About LinkBacks



