Not sure you what you mean. outscale_y attribute is a way to tell e.g. RetroArch that you want this shader pass to be rendered to an FBO with height outscale_y * viewport height. You have no direct control of doing that in GLSL directly. GL controls where you are rendering to.
Hmmm, so it’s impossible, then. Damn. I got a shader to do something neat in RetroArch by setting outscale_y to 2, but it seems then that it won’t work on other emulators.
Not quite sure if this is the right thread, but: I’ve become fed up with VBA-M constantly crashing, soo I’ve converted Hyllians recently released new version of xBR-hybrid to the XML format, converted my savegames from VBA-M .sav to Retroarch/VBA Next .srm and I’m ready to continue playing GBA on Retroarch.
However, one thing irks me, the colors are much too neon-ish with Retroarch/VBA Next. In VBA-M, there’s an option to change the palette to “Gameboy Colors” instead of “Real Colors”, which fixes this annoyance. Is there some way to get the same effect either A) via shaders or B) via some option that’s not GUI exposed. or C) some CPU filter? B or C would probably be preferred since it would give much more freedom in regards to picking shaders.
I’ve found a shader called Phosphorx21. It has a similar effect as a CRT shader, but the bonus is that my system can play games at full speed with it at fullscreen.
Am looking for ways to reduce the scanlines. Have already increased bloom in it.
@Tripulent Have you tried messing with the SPOT_WIDTH and/or X_SIZE_ADJUST parameters?
@A for Anonymous A shader could probably do it.
Does anyone know why Phosphor21x runs so fast as opposed to CRT-Geom. What does Phosphor21x use for upscaling? Is it simply bilinear? I know CRT-Geom uses lanczos, which seems to be what really lags my system.
With some tweaks, you could probably market this as a CRT shader for extremely low end cards. I tried the CRT-Simple but even that lagged my system.
Not yet, but I will. I mostly want to reduce the brick-pattern effect.
Also, what specifically is the reason for the image improvement in this shader? Is it simply using a nice upscaling option, or is it the scanlines, or the combination of both?
I think it mostly just looks nice because of the scanlines/phosphors. There’s not a lot of other stuff going on, as far as I can tell.
cgwg’s CRT shader does a lot of subtle things that all contribute to the high resource requirements, while phosphor21x and caligari’s scanlines (which are closely related; phosphor21x was an earlier, in-progress version of the shader, IIRC, with the main changes pertaining to gamma correction and removal of some experimental stuff he was trying) just do the minimum work required to get something that looks nice.
I agree that it’s a good high-speed alternative to cgwg’s, and I think Hyllian uses some of its functions to generate the scanlines in his xBR+CRT variants.
Themaister’s scanline shader is also very lightweight and easy to customize, making it a good option for lower-performance systems.
MAME recently added a customizable CRT shader which is generic and very close to Blargg’s NTSC filters… (also available in MESS)
There was also a sort of a port (see the “NTSC” shader here), can this be edited to work with Retroarch?
@eadmaster The one from the second link works with RetroArch right now (I use it pretty regularly). If you just get a gray image with weird color banding, that’s an older version that has since been updated to work with later versions of RA.
That shader doesn’t do the aspect correction or gamma correction of blargg’s CPU filter, and the default version only outputs the ‘RF’ version, but it looks pretty close, IMO. If you take just the third pass of that shader, which handles the chroma smearing, you can tack it onto the end of other shaders that do include the other stuff.
I’ve tried porting MAME’s customizable HLSL shader (in non-custom form) but I’m not very good with HLSL/Cg, so I never really got anywhere.
I’ve tried both links (mediafire and pastebin), but i always get a gray image… does it require any particular setting in RA?
it shouldn’t require any special settings but I don’t think it works exactly right on every core (I just tried it with the TyrQuake core and it was weird and gray), but it should be fine on most/all 2D cores.
Ok, it works with the bsnes core, while it is showing a rainbow-like pattern with the nestopia and mednafen-pce cores. I’ve read on another forum that this could be due to different internal resolutions… any solution?
@eadmaster shit, you’re right. It works fine on SNES/NES cores but nowhere else (that I checked)… I would have thought that changing the instances of 256 and 512 to match the horizontal resolution of the system would help, but it didn’t seem to in the very limited amount of testing I did.
I saw the shader you posted over at byuu’s forum, and it looks damn nice. Or so I can gather from the screenshots, anyway, because I can’t get it to work right. I tried all the LUTs you provided at 4x scale, but only the vertical ones seem to work well, and well, they don’t look very good at 4x scale. The others, well…
This is with the default settings using the 240phoriz.png LUT. I have no clue what I’m doing wrong.
Which core(s) are you using? Snes9x-Next (and maybe regular Snes9x? I haven’t tried it yet) produce the purple look, presumably because of resolution…? bsnes and Genesis Plus GX should be okay.
I’ll test some other cores with it today.
Forget it, it turns out it was my FBO settings causing the issue. Setting it to 4x on both X and Y fixes the issue on BSNES, and it turns out they were also slightly off on my Genesis config as well, so that is fixed as well. NES is still a bit off, however. I assume it has to do with the 240 line resolution.
Ah, great, I’m glad you figured it out. I was just coming here to mention that the FBO scale options actually do something even if the box for it isn’t checked
Indeed, it appear to be working now. Only gripe I have, however, is that the colors get kinda fudged. Everything looks like it has a bluish tint to it or something.
If it wasn’t for the Falcon, you’d think this shot was taken in the World of Balance!
For comparison, here’s CRT-Geom with gamma correction disabled, combined with NTSC-RGB:
hmm. Yeah, I get some color weirdness on my end, too (a result of the subpixel behavior, I think), but nothing that bad o_O
As for the FBO scale problem, you can try the version from this post and see if it works any better in that respect: http://board.byuu.org/viewtopic.php?p=85432#p85432
Thanks. It looks fine now.
Say I wanted to combine it with the NTSC-RGB filter. When I do so with CRT-Geom, I use a variant that has gamma correction disabled, since the filter already does it. How would I go about doing the same for this shader, which also appears to be doing gamma correction of its own?