So, Easymode, could you explain conceptually what you’re doing to keep the scanlines from getting funky at non-integer scales? It’s a thing I’d like to achieve with a number of scanline-related shaders but I haven’t seen anyone talking about the problem in the usual places.
Before I started writing the shader, I compared each of the shaders in the repo to find out which ones handled non-integer scanlines best. I narrowed it down to crt-geom (with USEGAUSSIAN defined) and scanline.cg. The former method flew over my head, so I settled on the latter’s sine wave method as a basis, but simplifying it further for my sake.
I switched to cosine because I wanted to darken the top and bottom of each scanline. Multiplying the wave by 0.5 and adding 0.5 keeps it in the 0.0-1.0 range, ensuring that it influences every pixel. Wrapping all of this in pow() to a power greater than 1.0 widens the peak of the wave (well it becomes the peak after I invert it). Graphing f(x) = 1.0-pow(cos(xPI2.0)*0.5+0.5,1.5) shows the basic shape of the wave, which just seems to work well for non-integer scanlines. At least that’s the case for scaling factors >= 4.0. You need enough resolution to draw the subtle transitions. Clipping too hard will lose these transitions. If you raise the Brightness Boost parameter too high you’ll see how clipping messes up non-integer scanlines.
Oh yeah, doing the same thing here. The error is:
(128) : error C5043: profile requires index expression to be compile-time constant.
I’m guessing you have an Nvidia GPU, easymode? What about you BlockABoots? I’m on an AMD GPU, and I believe Cg gets compiled down to a lower profile on AMD GPUs.
The 15/35 settings you posted above seems to fit that no?
Actually I think 25/50 is closer to the image:
You could also try setting both Min/Max to 0 while scanline strength is at 1.0, and then raising them slowly until they reach the point you want.[/quote]
Yup F-Zero, well im using a 1440p display so i guess i might get difference results to you if your on a 1080p screen?.
These are settings ive found please @ 1440p (only listed settings ive changed from default)…