Batch #10277 by ragnarok-clanker: forced by an admin (17 lower score(s), 63 changed function(s)); checked with 414 compiled unit(s), including every includer of Source/Contents/Effects/RagEffect.h, Source/Contents/Models/ModelActor.h, Source/Contents/Models/ModelNode.h, Source/Contents/Models/ModelRendering.h, Source/Contents/World/WorldModelView.h, Source/Contents/World/WorldOcclusion.h, Source/Contents/World/WorldTerrainPicking.h, Source/Render/Projection/RendererViewport.h, Source/Render/Projection/RenderProjection.h. Deletes: Source/Render/Projection/RenderProjection.h
35 lines
1.1 KiB
C
35 lines
1.1 KiB
C
#ifndef RAGNAROK_SOURCE_RENDER_PROJECTION_RENDERERVIEWPORT_H
|
|
#define RAGNAROK_SOURCE_RENDER_PROJECTION_RENDERERVIEWPORT_H
|
|
|
|
#include <cstddef>
|
|
|
|
struct RendererViewport {
|
|
/* 0004 */ float scaleX;
|
|
/* 0008 */ float scaleY;
|
|
/* 000C */ float horizontal;
|
|
/* 0010 */ float vertical;
|
|
/* 0014 */ float aspect;
|
|
/* 0018 */ float uiScaleX;
|
|
/* 001C */ float uiScaleY;
|
|
/* 0020 */ int clipCenterX;
|
|
/* 0024 */ int clipCenterY;
|
|
/* 0028 */ int width;
|
|
/* 002C */ int height;
|
|
/* 0030 */ int centerX;
|
|
/* 0034 */ int centerY;
|
|
|
|
void SetSize(int width, int height);
|
|
void Project(const float* position, const float* matrix, struct RenderVertex& output) const;
|
|
void Project(const float* position, const float* matrix, struct LightmappedVertex& output) const;
|
|
void Ray(int x, int y, const float* origin, const float* matrix, float* output) const;
|
|
};
|
|
|
|
extern float g_cotangent;
|
|
|
|
static_assert(sizeof(RendererViewport) == 52);
|
|
#if defined(_WIN32) && !defined(_WIN64)
|
|
static_assert(offsetof(RendererViewport, width) == 0x24);
|
|
static_assert(offsetof(RendererViewport, centerY) == 0x30);
|
|
#endif
|
|
|
|
#endif
|