00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022 #ifndef RENDER_H
00023 #define RENDER_H
00024
00025 #include <Windows.h>
00026
00027 #include "BaseType.h"
00028 #include "Glide.h"
00029 #include "DCommon.h"
00030 #include "GCAche.h"
00031
00032 #ifdef __cplusplus
00033 extern "C" {
00034 #endif
00035
00036 enum
00037 {
00038 RENDER_UNKNOWN_MODE,
00039 RENDER_MISC_TEX_POLY_MODE,
00040 RENDER_MISC_GOURAD_POLY_MODE,
00041 RENDER_LINES_POLY_MODE,
00042 RENDER_WORLD_TRANSPARENT_POLY_MODE,
00043 RENDER_WORLD_POLY_MODE_NO_LIGHTMAP,
00044 RENDER_WORLD_POLY_MODE,
00045 RENDER_LIGHTMAP_POLY_MODE,
00046 RENDER_LIGHTMAP_FOG_POLY_MODE,
00047 RENDER_DECAL_MODE,
00048 };
00049
00050 extern uint32 PolyMode;
00051 extern DRV_CacheInfo CacheInfo;
00052
00053 void TextureSource(GrChipID_t Tmu, FxU32 startAddress, FxU32 evenOdd, GrTexInfo *info );
00054 void Render_SetHardwareMode(int32 NewMode, uint32 NewFlags);
00055 geBoolean DRIVERCC Render_GouraudPoly(DRV_TLVertex *Pnts, int32 NumPoints, uint32 Flags);
00056 geBoolean DRIVERCC Render_LinesPoly(DRV_TLVertex *Pnts, int32 NumPoints);
00057 geBoolean DRIVERCC Render_WorldPoly(DRV_TLVertex *Pnts, int32 NumPoints, geRDriver_THandle *THandle, DRV_TexInfo *TexInfo, DRV_LInfo *LInfo, uint32 Flags);
00058 void RenderLightmapPoly(GrVertex *vrtx, int32 NumPoints, DRV_LInfo *LInfo, geBoolean Dynamic, uint32 Flags);
00059 void DownloadLightmap(DRV_LInfo *LInfo, int32 Wh, GCache_Slot *Slot, int32 LMapNum);
00060 geBoolean DRIVERCC Render_MiscTexturePoly(DRV_TLVertex *Pnts, int32 NumPoints, geRDriver_THandle *THandle, uint32 Flags);
00061 void SetupTexture(geRDriver_THandle *THandle);
00062 GCache_Slot *SetupLMapTexture(geRDriver_THandle *THandle, DRV_LInfo *LInfo, geBoolean Dynamic, int32 LMapNum);
00063 geBoolean DRIVERCC Render_DrawDecal(geRDriver_THandle *THandle, RECT *SRect, int32 x, int32 y);
00064 geBoolean DRIVERCC BeginScene(geBoolean Clear, geBoolean ClearZ, RECT *WorldRect);
00065 geBoolean DRIVERCC EndScene(void);
00066 geBoolean DRIVERCC BeginWorld(void);
00067 geBoolean DRIVERCC EndWorld(void);
00068 geBoolean DRIVERCC BeginMeshes(void);
00069 geBoolean DRIVERCC EndMeshes(void);
00070 geBoolean DRIVERCC BeginModels(void);
00071 geBoolean DRIVERCC EndModels(void);
00072
00073
00074
00075
00076 #ifdef __cplusplus
00077 }
00078 #endif
00079
00080 #endif