Mercurial > mm7
annotate Render.h @ 1413:3881d2f94eb1
UseNPCSkill
DIALOGUE_USE_NPC_ABILITY
author | Nomad |
---|---|
date | Sat, 27 Jul 2013 16:09:00 +0200 |
parents | cc9a3a24d61d |
children | 1987f2cca08f |
rev | line source |
---|---|
0 | 1 #pragma once |
2 #include <stdio.h> | |
3 | |
4 #include "lib\legacy_dx\d3d.h" | |
5 #include "OSAPI.h" | |
6 | |
7 #include "VectorTypes.h" | |
8 | |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
9 struct Polygon; |
0 | 10 struct Texture; |
11 struct RGBTexture; | |
12 struct RenderBillboardTransform_local0; | |
13 struct ODMFace; | |
14 | |
15 | |
16 /* 119 */ | |
17 #pragma pack(push, 1) | |
18 struct RenderVertexSoft | |
19 { | |
20 inline RenderVertexSoft(): | |
21 flt_2C(0.0f) | |
22 {} | |
23 | |
24 Vec3_float_ vWorldPosition; | |
25 Vec3_float_ vWorldViewPosition; | |
26 float vWorldViewProjX; | |
27 float vWorldViewProjY; | |
168 | 28 float _rhw; |
0 | 29 float u; |
30 float v; | |
31 float flt_2C; | |
32 }; | |
33 #pragma pack(pop) | |
34 | |
35 | |
36 | |
37 /* 112 */ | |
38 #pragma pack(push, 1) | |
39 struct RenderVertexD3D3 | |
40 { | |
41 Vec3_float_ pos; | |
42 float rhw; | |
43 unsigned int diffuse; | |
44 unsigned int specular; | |
45 Vec2_float_ texcoord; | |
46 }; | |
1269 | 47 #pragma pack(pop) |
0 | 48 |
1016 | 49 class Sprite; |
50 class SpriteFrame; | |
0 | 51 |
52 /* 161 */ | |
53 #pragma pack(push, 1) | |
54 struct RenderBillboard | |
55 { | |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
56 int _screenspace_x_scaler_packedfloat; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
57 int _screenspace_y_scaler_packedfloat; |
0 | 58 float fov_x; |
59 float fov_y; | |
194 | 60 union |
61 { | |
62 int sZValue; | |
63 struct | |
64 { | |
65 unsigned __int16 object_pid; | |
66 signed __int16 actual_z; | |
67 }; | |
68 }; | |
142 | 69 int field_14_actor_id; |
0 | 70 unsigned __int16 uHwSpriteID; |
71 __int16 uPalette; | |
72 __int16 uIndoorSectorID; | |
73 __int16 field_1E; | |
430 | 74 __int16 world_x; |
75 __int16 world_y; | |
76 __int16 world_z; | |
0 | 77 __int16 uScreenSpaceX; |
78 __int16 uScreenSpaceY; | |
657 | 79 unsigned __int16 dimming_level; |
0 | 80 unsigned int uTintColor; |
81 SpriteFrame *pSpriteFrame; | |
159 | 82 |
83 inline float GetFloatZ() const | |
84 { | |
194 | 85 return (float)object_pid / 65535.0f + (float)actual_z; |
159 | 86 } |
0 | 87 }; |
88 #pragma pack(pop) | |
89 | |
90 | |
91 #pragma pack(push, 1) | |
92 struct RenderD3D__DevInfo | |
93 { | |
94 unsigned int bIsDeviceCompatible; | |
95 char *pName; | |
96 char *pDescription; | |
97 GUID *pGUID; | |
98 unsigned int uCaps; | |
99 char *pDriverName; | |
100 char *pDeviceDesc; | |
101 char *pDDraw4DevDesc; | |
102 GUID *pDirectDrawGUID; | |
103 int uVideoMem; | |
104 }; | |
105 #pragma pack(pop) | |
106 | |
107 | |
108 | |
109 #pragma pack(push, 1) | |
110 struct RenderD3D_D3DDevDesc | |
111 { | |
112 int field_0; | |
113 int field_4; | |
114 int field_8; | |
115 int field_C; | |
116 int field_10; | |
117 char *pDriverName; | |
118 char *pDeviceDesc; | |
119 char *pDDraw4DevDesc; | |
120 GUID *pGUID; | |
121 unsigned int uVideoMem; | |
122 }; | |
123 #pragma pack(pop) | |
124 | |
125 | |
126 | |
127 | |
128 | |
129 | |
130 | |
131 | |
132 | |
133 /* 280 */ | |
134 #pragma pack(push, 1) | |
135 struct HWLTexture | |
136 { | |
137 inline HWLTexture(): | |
138 field_0(0), field_4(0), field_8(0), | |
139 field_C(0), field_10(0), field_14(0) | |
140 {} | |
141 | |
142 int field_0; | |
143 int field_4; | |
144 int field_8; | |
145 int field_C; | |
146 int field_10; | |
147 int field_14; | |
670 | 148 int uBufferWidth; |
149 int uBufferHeight; | |
150 int uAreaWidth; | |
151 int uAreaHeigth; | |
0 | 152 unsigned int uWidth; |
153 unsigned int uHeight; | |
670 | 154 int uAreaX; |
155 int uAreaY; | |
0 | 156 unsigned __int16 *pPixels; |
157 }; | |
158 #pragma pack(pop) | |
159 | |
160 | |
161 /* 185 */ | |
162 #pragma pack(push, 1) | |
163 struct RenderHWLContainer | |
164 { | |
165 RenderHWLContainer(); | |
166 bool Load(const wchar_t *pFilename); | |
167 bool Release(); | |
168 | |
169 HWLTexture *LoadTexture(const char *pName, int bMipMaps); | |
170 | |
171 FILE *pFile; | |
172 uint uSignature; | |
173 unsigned int uDataOffset; | |
174 unsigned int uNumItems; | |
175 char *pSpriteNames[50000]; | |
176 int pSpriteOffsets[50000]; | |
177 int bDumpDebug; | |
178 int field_61A94_scale_hwls_to_half; | |
179 }; | |
180 #pragma pack(pop) | |
181 | |
182 | |
183 | |
184 /* 242 */ | |
185 #pragma pack(push, 1) | |
186 struct RenderBillboardD3D | |
187 { | |
188 enum OpacityType: unsigned __int32 | |
189 { | |
190 Transparent = 0, | |
191 Opaque_1 = 1, | |
192 Opaque_2 = 2, | |
193 Opaque_3 = 3, | |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
194 NoBlend = 0xFFFFFFFF |
0 | 195 }; |
196 | |
197 IDirect3DTexture2 *pTexture; | |
198 unsigned int uNumVertices; | |
1390 | 199 RenderVertexD3D3 pQuads[4]; |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
200 float z_order; |
0 | 201 OpacityType uOpacity; |
202 int field_90; | |
203 int sZValue; | |
204 unsigned int uParentBillboardID; | |
205 }; | |
206 #pragma pack(pop) | |
207 | |
208 | |
209 | |
210 | |
211 #pragma pack(push, 1) | |
212 struct RenderD3D_aux | |
213 { | |
214 RenderD3D__DevInfo *pInfo; | |
215 RenderD3D_D3DDevDesc *ptr_4; | |
216 }; | |
217 #pragma pack(pop) | |
218 | |
219 | |
220 | |
221 /* 183 */ | |
222 #pragma pack(push, 1) | |
223 struct RenderD3D | |
224 { | |
225 RenderD3D(); | |
226 | |
227 void GetAvailableDevices(RenderD3D__DevInfo **pOutDevices); | |
228 void Release(); | |
229 bool CreateDevice(unsigned int uDeviceID, int bWindowed, HWND hWnd); | |
230 unsigned int GetDeviceCaps(); | |
231 void ClearTarget(unsigned int bClearColor, unsigned int uClearColor, unsigned int bClearDepth, float z_clear); | |
232 void Present(bool bForceBlit); | |
233 bool CreateTexture(unsigned int uTextureWidth, unsigned int uTextureHeight, IDirectDrawSurface4 **pOutSurface, IDirect3DTexture2 **pOutTexture, bool bAlphaChannel, bool bMipmaps, unsigned int uMinDeviceTexDim); | |
234 void HandleLostResources(); | |
235 | |
236 | |
237 unsigned int bWindowed; | |
238 int field_4; | |
239 int field_8; | |
240 HWND hWindow; | |
241 int field_10; | |
242 int field_14; | |
243 int field_18; | |
244 RenderD3D__DevInfo *pAvailableDevices; | |
245 IDirectDraw4 *pHost; | |
246 IDirect3D3 *pDirect3D; | |
247 IUnknown *pUnk; | |
248 IDirectDrawSurface4 *pBackBuffer; | |
249 IDirectDrawSurface4 *pFrontBuffer; | |
250 IDirectDrawSurface4 *pZBuffer; | |
251 IDirect3DDevice3 *pDevice; | |
252 IDirect3DViewport3 *pViewport; | |
253 int field_40; | |
254 int field_44; | |
255 char pErrorMessage[48]; | |
256 char field_78[208]; | |
257 }; | |
258 #pragma pack(pop) | |
1207
96a81634669e
arrays to std::arrays phase 3 - finishing global arrays
Grumpy7
parents:
1206
diff
changeset
|
259 extern struct RenderVertexD3D3 pVertices[50]; |
0 | 260 |
261 /* 182 */ | |
262 #pragma pack(push, 1) | |
263 struct Render | |
264 { | |
265 Render(); | |
266 ~Render(); | |
267 | |
268 static Render *Create() {return new Render;} | |
269 | |
270 bool Initialize(bool bWindowed, uint uDefaultDevice, | |
271 bool bColoredLights, uint uDetailLevel, uint bTinting); | |
272 | |
273 | |
274 bool IsColorKeySupported(IDirectDraw4 *); | |
275 void _49EBF1(); | |
276 void ClearBlack(); | |
277 void PresentBlackScreen(); | |
278 void SavePCXScreenshot(); | |
279 void _49F1BC(const char *a1); | |
810 | 280 void PackPCXpicture(unsigned short* picture_data, int wight, int heidth, void *data_buff, int max_buff_size,unsigned int* packed_size); |
0 | 281 FILE *SavePCXImage(const char *Filename, char *a3, int a4, int a5); |
282 void ClearTarget(unsigned int uColor); | |
283 void Release2(); | |
284 void Present(); | |
285 void _49FD3A(); | |
286 void CreateZBuffer(); | |
287 void Release(); | |
288 void CreateSomeTexture(); | |
289 bool InitializeFullscreen(HWND hWnd); | |
290 bool SwitchToWindow(HWND hWnd); | |
709 | 291 char RasterLine2D(unsigned int uX, unsigned int uY, unsigned int uZ, unsigned int uW, unsigned __int16 uColor); |
0 | 292 void ClearZBuffer(int a2, int a3); |
709 | 293 void SetRasterClipRect(unsigned int uX, unsigned int uY, unsigned int uZ, unsigned int uW); |
0 | 294 void ParseTargetPixelFormat(); |
295 bool LockSurface_DDraw4(IDirectDrawSurface4 *pSurface, DDSURFACEDESC2 *pDesc, unsigned int uLockFlags); | |
296 bool LockSurface_DDraw2(IDirectDrawSurface2 *pSurface, DDSURFACEDESC *pDesc, unsigned int uLockFlags); | |
297 void CreateDirectDraw(); | |
298 void SetDirectDrawCooperationMode(HWND hWnd, bool bFullscreen); | |
299 void SetDirectDrawDisplayMode(unsigned int uWidth, unsigned int uHeight, unsigned int uBPP); | |
300 void CreateFrontBuffer(); | |
301 void CreateBackBuffer(); | |
302 void CreateDirectDrawPrimarySurface(); | |
303 void CreateClipper(HWND a2); | |
304 void GetTargetPixelFormat(DDPIXELFORMAT *pOut); | |
305 void LockRenderSurface(void **pOutSurfacePtr, unsigned int *pOutPixelsPerRow); | |
306 bool UsingDirect3D(); | |
307 void UnlockBackBuffer(); | |
308 void LockFrontBuffer(void **pOutSurface, unsigned int *pOutPixelsPerRow); | |
309 void UnlockFrontBuffer(); | |
310 void RestoreFrontBuffer(); | |
311 HRESULT _4A184C(); | |
312 void PresentRect(RECT *a2, RECT *a3); | |
313 void BltToFront(RECT *pDstRect, IDirectDrawSurface *pSrcSurface, RECT *pSrcRect, unsigned int uBltFlags); | |
314 void BltBackToFontFast(int a2, int a3, RECT *a4); | |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
315 unsigned int Billboard_ProbablyAddToListAndSortByZOrder(float z); |
0 | 316 unsigned int GetBillboardDrawListSize(); |
317 unsigned int GetParentBillboardID(unsigned int uBillboardID); | |
318 void BeginSceneD3D(); | |
319 void DrawBillboards_And_MaybeRenderSpecialEffects_And_EndScene(); | |
349 | 320 unsigned int GetActorTintColor(float a2, int tint, int a4, int a5, RenderBillboard *a6); |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
321 void DrawPolygon(unsigned int uNumVertices, struct Polygon *a3, ODMFace *a4, IDirect3DTexture2 *pTexture); |
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
322 void DrawTerrainPolygon(unsigned int uNumVertices, struct Polygon *a4, IDirect3DTexture2 *a5, bool transparent, bool clampAtTextureBorders); |
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
323 void DrawSkyPolygon(unsigned int uNumVertices, struct Polygon *a3, IDirect3DTexture2 *pTexture); |
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
324 void _4A2ED5(signed int a2, struct Polygon *a3, IDirect3DTexture2 *pHwTex); |
1262 | 325 void DrawIndoorPolygon(unsigned int uNumVertices, struct BLVFace *a3, IDirect3DTexture2 *pHwTex, struct Texture *pTex, int uPackedID, unsigned int uColor, int a8); |
1390 | 326 void DrawIndoorPolygonNoLight(unsigned int uNumVertices, unsigned int uFaceID); |
0 | 327 void MakeParticleBillboardAndPush_BLV(RenderBillboardTransform_local0 *a2, IDirect3DTexture2 *a3, unsigned int uDiffuse, int angle); |
328 void MakeParticleBillboardAndPush_ODM(RenderBillboardTransform_local0 *a2, IDirect3DTexture2 *a3, unsigned int uDiffuse, int angle); | |
657 | 329 void TransformBillboard(RenderBillboardTransform_local0 *a2, Sprite *pSprite, int dimming_level, RenderBillboard *pBillboard); |
717 | 330 void DrawBillboard_Indoor(RenderBillboardTransform_local0 *pSoftBillboard, Sprite *pSprite, int dimming_level); |
0 | 331 int MakeParticleBillboardAndPush_BLV_Software(int screenSpaceX, int screenSpaceY, int z, int lightColor, int a6); |
332 void DrawProjectile(float srcX, float srcY, float a3, float a4, float dstX, float dstY, float a7, float a8, IDirect3DTexture2 *a9); | |
1390 | 333 void _4A4CC9_AddSomeBillboard(struct stru6_stru1_indoor_sw_billboard *a1, int diffuse); |
0 | 334 bool LoadTexture(const char *pName, unsigned int bMipMaps, IDirectDrawSurface4 **pOutSurface, IDirect3DTexture2 **pOutTexture); |
670 | 335 bool MoveSpriteToDevice(Sprite *pSprite); |
0 | 336 void BeginScene(); |
337 void EndScene(); | |
338 unsigned int _4A52F1(unsigned int this_, float a3); | |
727 | 339 void SetTextureClipRect(unsigned int uX, unsigned int uY, unsigned int uZ, unsigned int uW); |
340 void ResetTextureClipRect(); | |
0 | 341 void DrawTextureRGB(unsigned int uOutX, unsigned int uOutY, RGBTexture *a4); |
342 void _4A5D33(unsigned int a2, unsigned int a3, int a4, int a5, RGBTexture *pTexture); | |
1262 | 343 void DrawTextureIndexed(unsigned int uX, unsigned int uY, struct Texture *a4); |
344 void ZBuffer_Fill_2(signed int a2, signed int a3, struct Texture *pTexture, int a5); | |
345 void DrawMaskToZBuffer(signed int uOutX, unsigned int uOutY, struct Texture *pTexture, int zVal); | |
346 void DrawTextureTransparent(unsigned int uX, unsigned int uY, struct Texture *pTexture); | |
347 void _4A63E6(unsigned int a2, unsigned int a3, struct Texture *a4, struct Texture *a5, int a6, int a7, int a8); | |
348 void _4A65CC(unsigned int x, unsigned int y, struct Texture *a4, struct Texture *a5, int a6, int a7, int a8); | |
349 void DrawTransparentRedShade(unsigned int a2, unsigned int a3, struct Texture *a4); | |
350 void DrawTransparentGreenShade(signed int a2, signed int a3, struct Texture *pTexture); | |
351 void _4A6A68(unsigned int a2, unsigned int a3, struct Texture *a4, __int16 height); | |
1268 | 352 void DrawTextPalette(int x, int y, unsigned char* font_pixels, int a5, unsigned int uFontHeight, unsigned __int16 *pPalette, int a8); |
0 | 353 void DrawText(signed int uOutX, signed int uOutY, unsigned __int8 *pFontPixels, unsigned int uCharWidth, unsigned int uCharHeight, unsigned __int16 *pFontPalette, unsigned __int16 uFaceColor, unsigned __int16 uShadowColor); |
354 void FillRectFast(unsigned int uX, unsigned int uY, unsigned int uWidth, unsigned int uHeight, unsigned int uColor16); | |
355 int _4A6DF5(unsigned __int16 *pBitmap, unsigned int uBitmapPitch, struct Vec2_int_ *pBitmapXY, unsigned __int16 *pTarget, unsigned int uTargetPitch, Vec4_int_ *a7); | |
1262 | 356 void _4A6E7E(unsigned int a2, unsigned int a3, struct Texture *a4); |
0 | 357 char DrawBuildingsD3D(); |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
358 //struct BSPModel *DrawBuildingsSW(); |
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
359 //int OnOutdoorRedrawSW(); |
0 | 360 void DrawSkyD3D(); |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
361 //int DrawSkySW(struct Span *a1, Polygon *a2, int a3); |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
362 void PrepareDecorationsRenderList_ODM(); |
515
cb0ad52d6a26
LayingItem -> SpriteObject (long-waited rename, old name was inaccurate and confused people)
Nomad
parents:
430
diff
changeset
|
363 void DrawSpriteObjects_ODM(); |
0 | 364 void TransformBillboardsAndSetPalettesODM(); |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
365 //float DrawBezierTerrain(); |
86 | 366 void RenderTerrainD3D(); |
985 | 367 void DrawTerrainD3D(int a1, int edx0, int a3, int unk4); |
1391
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
368 //void DrawTerrainSW(int a1, int a2, int a3, int a4); |
cc9a3a24d61d
Moved stru11, stru12 and some SW Rendering stuff to the archives.
Nomad
parents:
1390
diff
changeset
|
369 //void ExecOutdoorDrawSW(); |
0 | 370 void ChangeBetweenWinFullscreenModes(); |
371 void DrawBillboardList_BLV(); | |
372 | |
373 | |
374 unsigned int bUserDirect3D; | |
375 unsigned int bStartInWindow; | |
376 unsigned int uDesiredDirect3DDevice; | |
377 unsigned int uAcquiredDirect3DDevice; | |
378 int field_10; | |
379 int field_14; | |
380 int field_18_locked_pitch; | |
709 | 381 int raster_clip_x; |
382 int raster_clip_y; // clipping rect for raster ops | |
383 int raster_clip_z; // like RasterLine2D for (mini)map | |
384 int raster_clip_w; | |
0 | 385 __int16 field_2C[65536]; |
386 __int16 field_2002C[65536]; | |
387 int field_4002C; | |
388 int field_40030; | |
389 int *pActiveZBuffer; | |
390 int *pDefaultZBuffer; | |
391 int field_4003C; | |
392 int field_40040; | |
393 int field_40044; | |
394 int field_40048; | |
395 int field_4004C; | |
396 HWND hWnd; | |
397 int field_40054; | |
398 unsigned int bWindowMode; | |
399 int field_4005C[11]; | |
400 RenderD3D *pRenderD3D; | |
401 IDirectDraw4 *pDirectDraw4; | |
402 IDirectDrawSurface4 *pFrontBuffer4; | |
403 IDirectDrawSurface4 *pBackBuffer4; | |
404 IDirectDrawSurface4 *pColorKeySurface4; | |
405 IDirectDraw2 *pDirectDraw2; | |
406 IDirectDrawSurface2 *pFrontBuffer2; | |
407 IDirectDrawSurface2 *pBackBuffer2; | |
408 IDirectDrawSurface2 *pSomeSurface2; | |
409 DDPIXELFORMAT ddpfPrimareSuface; | |
410 unsigned int uTargetRBits; | |
411 unsigned int uTargetGBits; | |
412 unsigned int uTargetBBits; | |
413 unsigned int uTargetRMask; | |
414 unsigned int uTargetGMask; | |
415 unsigned int uTargetBMask; | |
416 unsigned int uNumSceneBegins; | |
417 int *ptr_400E8; | |
418 unsigned __int16 *pTargetSurface; | |
419 unsigned int uTargetSurfacePitch; | |
420 unsigned int uClipY; | |
421 unsigned int uClipX; | |
422 unsigned int uClipW; | |
423 unsigned int uClipZ; | |
424 unsigned int bClip; | |
425 unsigned int bColorKeySupported; | |
426 unsigned int uNumD3DSceneBegins; | |
427 int field_40110; | |
428 RenderHWLContainer pD3DBitmaps; | |
429 RenderHWLContainer pD3DSprites; | |
430 unsigned int bUseColoredLights; | |
431 unsigned int bRequiredTextureStagesAvailable; | |
432 unsigned int bTinting; | |
433 unsigned int uLevelOfDetail; | |
434 unsigned int uMaxDeviceTextureDim; | |
435 unsigned int uMinDeviceTextureDim; | |
436 int field_10365C; | |
437 unsigned int bUsingSpecular; | |
438 uint uFogColor; | |
439 int field_103668; | |
440 unsigned int pHDWaterBitmapIDs[7]; | |
441 char field_103688[32]; | |
265 | 442 int hd_water_current_frame; |
443 int hd_water_tile_id; | |
0 | 444 IDirectDrawSurface4 *pSurface; |
445 IDirect3DTexture2 *pTexture; | |
446 int field_1036B8; | |
447 int _gpu_memory_used; | |
448 void (__cdecl *pBeforePresentFunction)(); | |
449 int field_1036C4; | |
450 uint bFogEnabled; | |
451 int field_1036CC; | |
452 RenderBillboardD3D pBillboardRenderListD3D[1000]; | |
453 unsigned int uNumBillboardsToDraw; | |
454 int field_129834; | |
455 unsigned int uCurrentlyLockedSurfacePitch; | |
456 unsigned __int16 *pCurrentlyLockedSurfaceDataPtr; | |
457 unsigned __int16 *pCurrentlyLockedSoftSurface; | |
458 }; | |
459 #pragma pack(pop) | |
460 | |
461 extern struct IDirectDrawClipper *pDDrawClipper; | |
462 extern struct Render *pRenderer; // idb | |
67 | 463 extern struct pUnkTerrain *Unks; |
0 | 464 |
465 | |
466 | |
467 /* 248 */ | |
468 #pragma pack(push, 1) | |
469 struct RenderBillboardTransform_local0 | |
470 { | |
471 unsigned __int16 *pTarget; | |
472 int *pTargetZ; | |
473 int uScreenSpaceX; | |
474 int uScreenSpaceY; | |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
475 int _screenspace_x_scaler_packedfloat; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
476 int _screenspace_y_scaler_packedfloat; |
0 | 477 char field_18[8]; |
478 unsigned __int16 *pPalette; | |
479 unsigned __int16 *pPalette2; | |
144
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
480 union |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
481 { |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
482 int sZValue; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
483 struct |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
484 { |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
485 unsigned short object_pid; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
486 short zbuffer_depth; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
487 }; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
488 }; |
8ab4484c22e0
Billboard drawing's up (actors, decorations, misc sprites)
Nomad
parents:
142
diff
changeset
|
489 unsigned int uFlags; // & 4 - mirror horizontally |
0 | 490 unsigned int uTargetPitch; |
491 unsigned int uViewportX; | |
492 unsigned int uViewportY; | |
493 unsigned int uViewportZ; | |
494 unsigned int uViewportW; | |
495 int field_44; | |
496 int uParentBillboardID; | |
497 int uTintColor; | |
498 }; | |
499 #pragma pack(pop) | |
500 | |
501 | |
502 | |
503 | |
504 extern int uNumDecorationsDrawnThisFrame; // weak | |
1207
96a81634669e
arrays to std::arrays phase 3 - finishing global arrays
Grumpy7
parents:
1206
diff
changeset
|
505 extern RenderBillboard pBillboardRenderList[500]; |
0 | 506 extern unsigned int uNumBillboardsToDraw; |
507 extern int uNumSpritesDrawnThisFrame; // weak | |
508 | |
509 | |
510 | |
511 | |
1207
96a81634669e
arrays to std::arrays phase 3 - finishing global arrays
Grumpy7
parents:
1206
diff
changeset
|
512 extern RenderVertexSoft array_507D30[50]; |
96a81634669e
arrays to std::arrays phase 3 - finishing global arrays
Grumpy7
parents:
1206
diff
changeset
|
513 extern RenderVertexSoft array_50AC10[50]; |
96a81634669e
arrays to std::arrays phase 3 - finishing global arrays
Grumpy7
parents:
1206
diff
changeset
|
514 extern RenderVertexSoft array_73D150[20]; |
0 | 515 |
1413 | 516 extern RenderVertexD3D3 d3d_vertex_buffer[50]; |