mirror of
https://github.com/isledecomp/isle-portable.git
synced 2026-02-03 12:31:15 +00:00
Update miniwin/sdl3gpu/src/miniwin_d3drmviewport.cpp
Co-authored-by: Anonymous Maarten <madebr@users.noreply.github.com>
This commit is contained in:
parent
afe93a33a9
commit
68cb4386bb
@ -64,13 +64,13 @@ static void D3DRMMatrixInvertOrthogonal(D3DRMMATRIX4D out, const D3DRMMATRIX4D m
|
||||
static void CalculateProjectionMatrix(D3DRMMATRIX4D Result, float field, float aspect, float near, float far)
|
||||
{
|
||||
float f = near / field;
|
||||
float debth = far - near;
|
||||
float depth = far - near;
|
||||
|
||||
D3DRMMATRIX4D perspective = {
|
||||
{f, 0, 0, 0},
|
||||
{0, f * aspect, 0, 0},
|
||||
{0, 0, far / debth, 1},
|
||||
{0, 0, (-near * far) / debth, 0},
|
||||
{0, 0, far / depth, 1},
|
||||
{0, 0, (-near * far) / depth, 0},
|
||||
};
|
||||
|
||||
memcpy(Result, &perspective, sizeof(D3DRMMATRIX4D));
|
||||
|
||||
Loading…
Reference in New Issue
Block a user