Skip to content

Commit

Permalink
Fixed a sprite rendering issue introduced by the previous release.
Browse files Browse the repository at this point in the history
  • Loading branch information
luciusDXL committed Sep 26, 2023
1 parent 3622998 commit a40f046
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 2 deletions.
12 changes: 11 additions & 1 deletion TheForceEngine/Shaders/gpu_render_sprite.frag
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,17 @@ void main()
// if (discardPixel(baseColor, LightData.w)) { discard; }
// Either discard very close to the iso-value or
// do a two-pass filter - close cut with depth-write + alpha blend without depth-write.
if (baseColor.a < 0.48 && LightData.w < 1.0) { discard; }
#ifdef OPT_TRUE_COLOR
if (baseColor.a < 0.48 && LightData.w < 1.0)
{
discard;
}
#else
if (baseColor < 0.5 && LightData.w < 1.0)
{
discard;
}
#endif

// Get the emissive factor (0 = normal, 1 = 100% fullbright).
#ifdef OPT_TRUE_COLOR
Expand Down
2 changes: 1 addition & 1 deletion TheForceEngine/gitVersion.h
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
const char c_gitVersion[] = R"(
v1.09.512
v1.09.520
)";

0 comments on commit a40f046

Please sign in to comment.