Skip to content
This repository has been archived by the owner on Oct 4, 2024. It is now read-only.

Commit

Permalink
output: fix regression in Output_InsertPoly_Gouraud
Browse files Browse the repository at this point in the history
Resolves #64
  • Loading branch information
rr- committed Apr 27, 2024
1 parent 03f0367 commit 02ce33d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
## [Unreleased](https://github.com/LostArtefacts/TR2X/compare/stable...develop) - ××××-××-××
- fixed Lara's shadow with z-buffer option on (#64, regression from 0.1)

## [0.1](https://github.com/rr-/TR2X/compare/...0.1) - 2024-04-26
- added version string to the inventory
Expand Down
6 changes: 3 additions & 3 deletions src/game/output.c
Original file line number Diff line number Diff line change
Expand Up @@ -3399,7 +3399,7 @@ const int16_t *__cdecl Output_InsertObjectG4_Sorted(
}

int32_t num_points = 4;
PHD_VBUF *const vtx[4] = {
const PHD_VBUF *const vtx[4] = {
&g_PhdVBuf[*obj_ptr++],
&g_PhdVBuf[*obj_ptr++],
&g_PhdVBuf[*obj_ptr++],
Expand Down Expand Up @@ -4147,9 +4147,9 @@ void __cdecl Output_InsertPoly_Gouraud(
g_HWR_VertexPtr[i].sy = g_VBuffer[i].y;
if (g_SavedAppSettings.zbuffer) {
g_HWR_VertexPtr[i].sz =
g_FltResZBuf - g_FltResZORhw * g_VBuffer[0].rhw;
g_FltResZBuf - g_FltResZORhw * g_VBuffer[i].rhw;
}
g_HWR_VertexPtr[i].rhw = g_VBuffer[0].rhw;
g_HWR_VertexPtr[i].rhw = g_VBuffer[i].rhw;
g_HWR_VertexPtr[i].color = Output_ShadeLightColor(
g_VBuffer[i].g, red, green, blue,
poly_type == POLY_HWR_TRANS ? 0x80 : 0xFF);
Expand Down

0 comments on commit 02ce33d

Please # to comment.