Panel użytkownika
Nazwa użytkownika:
Hasło:
Nie masz jeszcze konta?

d3dx9 błąd

Ostatnio zmodyfikowano 2010-12-18 14:42
Autor Wiadomość
skovv
Temat założony przez niniejszego użytkownika
d3dx9 błąd
» 2010-12-18 13:35:40
Witam. Jak poradził mi kumpel zamiast Visual C++ do d3d zacząłem używać Code::Blocks. Mam jednak taki problem że jeśli linkuje :

#include <d3d9.h>
 nie ma żadnych błędów, ale jeśli zamiast tego dam
#include <d3dx9.h>
to wyskakuje mi błędy:

D:\d3d\include\d3d9types.h|25|warning: ignoring #pragma warning |
D:\d3d\include\d3d9types.h|1789|warning: ignoring #pragma warning |
D:\d3d\include\d3dx9math.h|19|warning: ignoring #pragma warning |
D:\d3d\include\d3dx9math.h|1385|warning: ignoring #pragma warning |
D:\d3d\include\d3dx9core.h|485|warning: multi-line comment|
D:\d3d\include\dxfile.h|240|error: stray '\26' in program|
D:\d3d\include\dxfile.h|240|warning: no newline at end of file|
||=== Build finished: 1 errors, 6 warnings ===|

Co do tego błędu:
D:\d3d\include\dxfile.h|240|error: stray '\26' in program|
 to wyświetla mi tą linijkę:

#ifdef __cplusplus
};
#endif

#endif /* _DXFILE_H_ */
<---- W KOMPILATORZE PISZE TU "SUB"

nie rozumiem o co chodzi :/
P-25279
DejaVu
» 2010-12-18 14:36:30
http://www.directxtutorial.com/tutorial9/B-Direct3DBasics/dx9B1.aspx
Fragment programu:
C/C++
// include the basic windows header files and the Direct3D header file
#include <windows.h>
#include <windowsx.h>
#include <d3d9.h>

// include the Direct3D Library file
#pragma comment (lib, "d3d9.lib")

// global declarations
LPDIRECT3D9 d3d; // the pointer to our Direct3D interface
LPDIRECT3DDEVICE9 d3ddev; // the pointer to the device class

// function prototypes
void initD3D( HWND hWnd ); // sets up and initializes Direct3D
void render_frame( void ); // renders a single frame
void cleanD3D( void ); // closes Direct3D and releases memory

// the WindowProc function prototype
LRESULT CALLBACK WindowProc( HWND hWnd, UINT message, WPARAM wParam, LPARAM lParam );
Czemu chcesz dołączać plik inny niż d3d9.h?
P-25282
skovv
Temat założony przez niniejszego użytkownika
» 2010-12-18 14:42:11
Już zauważyłem :D Dzięki za pomoc :)
P-25283
« 1 »
  Strona 1 z 1