#ifndef		__O3DFILE_H_
#define		__O3DFILE_H_

#include	<stdio.h>
#include	"gemmath.h"
#include	<d3d.h>

typedef struct _OBJECT3D
{
	LPD3DVERTEX		vert;
	LPWORD			ind;
	DWORD			vertNbr;
	WORD			indNbr;
} OBJECT3D, *LPOBJECT3D;

HRESULT LoadObject3D( TCHAR*, LPOBJECT3D );
VOID TransformObject3D( LPOBJECT3D, gem_Matrix& );
VOID TransformObject3D( LPOBJECT3D, LPOBJECT3D, gem_Matrix& );
VOID DeleteObject3D( LPOBJECT3D );
HRESULT CreateLineList( LPOBJECT3D, DWORD&, LPWORD& );
HRESULT RenderObject3D( LPOBJECT3D, LPDIRECT3DDEVICE7 );
HRESULT RenderFace( LPOBJECT3D, WORD, LPDIRECT3DDEVICE7 );
HRESULT RenderFaceEdgeWithAlpha( LPOBJECT3D, WORD, DWORD, LPDIRECT3DDEVICE7 );
VOID MorphObject( LPOBJECT3D, LPOBJECT3D, FLOAT, LPOBJECT3D );
VOID FlipNormals( LPOBJECT3D );
gem_Vector CalculateCenter( LPOBJECT3D obj );

#endif
