akgunter/crt-royale-reshade

vertical red line

ovitus opened this issue · 10 comments

I see a thin vertical red line running down the center of the screen with this filter. Is that part of the CRT emulation?

No, it's probably another rounding error in the phosphor mask tiling. I can't for the life of me get all of them ironed out.

What size is your window/game/screen, and what did you set the triad size to? Also is it DX9, DX10-12, OpenGL, or Vulcan?

Actually, there's another possible explanation. It could also be misconfigured "content box" settings. If you look at the Preprocessor Definitions section at the bottom of the config list, there should be a series of settings with the prefix "CONTENT_". One of them is CONTENT_BOX_VISIBLE. Is that set to 1?

If so, that's probably the culprit. In that case, I recommend right-clicking each of the "CONTENT_" definitions and resetting them to default. CONTENT_BOX_VISIBLE toggles a debug-mode of sorts that you can use to tell crt-royale-reshade which part of your screen has the game and which part is letterboxing. When it's visible and set correctly, it draws a red box around your game's video. Theoretically, if you configured it wrong, then you could end up with a big red line down the middle of the screen and no other effects active.

Resetting those to default will make the shader affect the entire screen, and will disable the debug mode.

I have the default settings, CONTENT_BOX_VISIBLE is already set to 0.

My monitor is 3840x2160. I've tested it with OpenGL in ScummVM and m64p.

Triad size:
image

Here's the line in the center of Wave Race 64, it's showing blue for some reason when I take the screenshot.
image

Uggghhh, yeah that’s probably a rounding error in the mask tiling. I’ll see if I can figure it out.

As a temporary workaround, try setting CONTENT_WIDTH to something like BUFFER_WIDTH - 1 or +1 or similar. Fudging the dimensions by a few pixels might hide the problem, and the screen border effect will make the misalignment imperceptible.

Haha.. sorry, somewhat of a perfectionist here myself. That hides it a bit, so thanks for that.

No need to apologize, these are exactly the kind of bugs I need help finding. I don’t play on a 4k, so I generally can’t test at that resolution.

@ovitus I can test on a 3840x2160 monitor now, but I can't seem to replicate your artifact in Vulkan, OpenGL, or DirectX 10+.

I don't think I refactored anything that would have fixed this by accident, so I assume you still have this artifact on the latest crt-royale-reshade version? If so, what GPU are/were you using? Maybe it's some weird difference between NVidia and AMD.

@ovitus this should be fixed now in the feature/computed-phosphors branch. I've rewritten the phosphor mask logic from scratch to generate the mask with trig functions rather than by downsampling and tiling a texture. Now the mask should look smoother, can't have tiling artifacts, and runs a smidget faster.

Released in v2.0.0