Skip to content

Fix CRT shader for Pixel/Other devices - #212

Open
siameseneko-dev wants to merge 5 commits into
blake502:mainfrom
siameseneko-dev:siameseneko-pr-ver
Open

Fix CRT shader for Pixel/Other devices#212
siameseneko-dev wants to merge 5 commits into
blake502:mainfrom
siameseneko-dev:siameseneko-pr-ver

Conversation

@siameseneko-dev

Copy link
Copy Markdown

Removes the noise part of the shader.
I isolated it as the cause of the black void, also fixes the game looking desaturated.

@Neulus

Neulus commented Mar 23, 2026

Copy link
Copy Markdown

i've tested it and, the core cause looks like pixel's gpu mod behaves strangely on the small precision. using num * fract(x / num) behaves correctly. patching:

MY_HIGHP_OR_MEDIUMP number x = (tc.x - mod(tc.x, 0.002)) * (tc.y - mod(tc.y, 0.0013)) * time * 1000.0;

to

MY_HIGHP_OR_MEDIUMP number x = (tc.x - 0.002 * fract(tc.x / 0.002)) * (tc.y - 0.0013 * fract(tc.y / 0.0013)) * time * 1000.0;

works fine on my pixel 9.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants