kokoko3k / koko-aio-slang

Multi purpose crt shader for retroarch
GNU General Public License v3.0
70 stars 3 forks source link

Background Images in FinalBurnNeo vertical games need to be tilted by -90° #1

Closed estefan3112 closed 1 year ago

estefan3112 commented 1 year ago

Most importantly, HUGE THANKS for this shader, which is exactly the thing I was looking for. After Vulkan having landed on the MacOS build of RetroArch, I can finally create content with a fancy shader like this (the HSM shaders let an M1 Mac Mini crawl). Performance of your shader is perfect!

The following relates to Version 3 of your package which I downloaded from here, as the bundled RetroArch shaders are still older.

It is a known issue with FinalBurn Neo: The background images are tilted by -90°. The easy workaround is to tilt the background image as well, then all fine.

To overcome this, the HSM Shaders provide an option: "FinalBurn Neo: If your game is vertical set the Rotate CRT Tube parameter to 1. If it is now upside down set Flip Core Image Vertical and Horizontal to 1"

I tried to set the Aspect Ration Numerator to -6 (but it was not available in the Shader Options, so I did it manually in the slangp-file), but with no effect.

Screenshots (obvious, no further explanation needed, except that the Monitor apparently has to be adjusted further):

IMG_8526

IMG_8527

I just wanted to be sure that I am not doing something wrong before moving forward with vertical FBNeo games.

This is huge, many thanks!!!

Stefan

estefan3112 commented 1 year ago

PS: Only the current master version from GitHub has the option -6, but neither version 3 nor RetroArch. It did not help anyway.

Of course I can provide you with the sample code and the picture.

estefan3112 commented 1 year ago

PPS: You can test it easily with your own Commodore background on any vertical game in FBNeo (just for illustration purposes):

Bildschirm­foto 2023-01-09 um 16 07 39 Bildschirm­foto 2023-01-09 um 16 09 32
kokoko3k commented 1 year ago

Hi there, i added another option to rotate the image. Please try if it fixes it for you.

estefan3112 commented 1 year ago

Many thanks, but it works only if the picture is the foreground picture. It does not rotate if it is the background picture. Would it be possible to apply rotation to both pictures, as I would assume that they should always rotate the same way? Because depending on the picture, sometimes foreground is better (if the artwork goes intentionally over the screen), but most of the time background image is better. Cheers!

kokoko3k commented 1 year ago

Wops, done.

estefan3112 commented 1 year ago

It is perfect! Two small things:

kokoko3k commented 1 year ago

It depends on what are you trying to achieve. If you are just adding bg graphics, then the safest choice is to target the shader that you like more for the content itself, so slotmask. About the directory structure, it probably will remain the same on retroarch, so, depending on your target (the one in retroarch or this on github), you may choose one or the other.

Looking forward to your preset!

estefan3112 commented 1 year ago

So in the zip there is the 1942.slangp and the background image (came a long way from John Merrit, he did some of my absolute favs). Here on my Mac, this is HDR enabled, so hopefully colors are nice on other platforms as well. Still need to test on Windows. Obviously I overemphasized the bezel reflection a bit too much (because I like it so much ;-).

It's better to start from the shader I like most - also because I can benefit from future tweaks on your end.

Directory structure: Currently I obviously need to stay with the github structure due to the rotation function. Changes to the files wouldn't be that dramatic, just the main reference, I guess.

I would then start slangp production based on this template and the dedicated folder for the background image mentioned in the slangp. So if you see something strange, I would be glad for feedback.

Best!

1942-koko-aio.zip

kokoko3k commented 1 year ago

Well then, you can think to do something like the following so that the shader can be used with both source directory structures (git repo and retroarch) Put your directory "1942-koko-aio/" in the folder that contain the other -already in place, done by me- presets. If you plan to do other presets, you may even think to put all of their files (.slangp and images) into a single folder like "estefan-kokoaio/", or whatever:

image

Then: Reference the main preset by going up one level: #reference "../monitor-slotmask.slangp" Reference the texture by looking right in your preset dir: bg_under = "./1942.png"

#reference "../monitor-slotmask.slangp"
GEOM_WARP_X = "0.750000"
GEOM_WARP_Y = "0.750000"
GEOM_CORNER_SIZE = "0.025000"
DO_BEZEL = "1.000000"
BEZEL_R = "-0.160000"
BEZEL_G = "-0.160000"
BEZEL_B = "-0.160000"
BEZEL_INNER_ZOOM = "-0.090000"
BEZEL_FRAME_ZOOM = "0.080000"
BEZEL_IMAGE_BORDER = "1.020000"
DO_BG_IMAGE = "1.000000"
BG_IMAGE_ROTATION = "1.000000"
DO_AMBILIGHT = "0.000000"
bg_under = "./1942.png"

As for what you are targetting, maybe referencing to the ones in retroarch is a better way, because on git things may change, while on retroarch they stay the same for longer time. I plan to update them when I'll release a new stable here on github, hopefully shortly, and speaking about it, I've to say you that maybe you'll have to tewak zoom levels, because i'll need to slightly change the aspect ratio of monitor frame texture, so my advice is to wait a bit for the retroarch shaders to be updated.

Talking about the preset you sent, the background image is slightly off on x axis; I think you need to zoom it a bit and move the whole image to the left: image

estefan3112 commented 1 year ago

Perfect advice, thank you so much! As I will create at least 70 configurations (those I've done for MAME), I need to plan properly, and I'll definitely wait for your next stable release.

I will also have to check whether it is perfectly safe to create a sub-folder into the one RetroArch provides, so that it is not deleted when RetroArch updates the slangp-shaders.

Having further played around with the shaders, it is a fair statement that this is a huge leap forward on Macs!!!

Best, Stefan

kokoko3k commented 1 year ago

Latest git have another "-1" setting for image rotation that should take care of rotating background images automagically. This work for mame2003 and fbneo.

estefan3112 commented 1 year ago

Sooo, I did a fancy Fork, and I like it 👍🏻

kokoko3k commented 1 year ago

You're welcome :)

estefan3112 commented 1 year ago

By the way: the -1 rotation option does not work for me, e.g. in 1943, where I still have to choose 1. No big issue, just to inform you. Is there any further relation of -1 with another option, such as Aspect Ratio?

kokoko3k commented 1 year ago

That's weird. I just tested with fbneo core and 1084S preset with 1942a.zip from mame 2003 plus and -1 and 1 acts exactly the same (the code does the same thing). Are you using the latest version?

Il giorno mer 11 gen 2023 alle ore 12:14 estefan3112 < @.***> ha scritto:

By the way: the -1 rotation option does not work for me, e.g. in 1943, where I still have to choose 1. No big issue, just to inform you. Is there any further relation of -1 with another option, such as Aspect Ratio?

— Reply to this email directly, view it on GitHub https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1378592303, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAJMPBV55TNWRSVBYJYWRLLWR2IXRANCNFSM6AAAAAATUTNTRU . You are receiving this because you commented.Message ID: @.***>

estefan3112 commented 1 year ago

Interesting: I restarted the 1942.slangp from scratch, and suddenly, the picture is also exactly centered.

reference "../../shaders/shaders_slang/bezel/koko-aio/monitor-slotmask-bloom-bezel.slangp"

DO_BG_IMAGE = "1.000000" BG_IMAGE_ROTATION = "1.000000" DO_AMBILIGHT = "0.000000" bg_under = "../../shaders/shaders_slang/bezel/koko-aio/textures/arcade_textures/1942.png"

Results in this - but auto-rotate still does not work for me, I need to choose 1:

Bildschirm­foto 2023-01-11 um 12 51 35

In the previous configuration (as I sent you), the picture was not centered (as you noticed), but also the picture offset did not work, so there was something going on there. Setting up the new configuration now.

Having bleeding edge RetroArch (with new Mac Vulkan driver) plus latest FBNeo core installed.

estefan3112 commented 1 year ago

In fact, with the latest Github code, I do not have to apply any zoom any longer, only a bit more RGB bezel effect, so much more convenient than before. Maybe the missing auto-rotate is a Mac thing, will check on Windows as well.

estefan3112 commented 1 year ago

Im checked on Windows, and -1 auto-rotate also does not work there. To be sure, we are talking about the Vulkan video driver, right? Are there any other options to consider that might be relevant?

kokoko3k commented 1 year ago

I'm not expert of fbneo. Are you using tate mode, maybe? (the core pre-rotates the content)? Is retroarch scaling/aspect set to full (stupid question)

On 12 January 2023 00:09:14 CET, estefan3112 @.***> wrote:

Im checked on Windows, and -1 auto-rotate also does not work there. To be sure, we are talking about the Vulkan video driver, right? Are there any other options to consider that might be relevant?

-- Reply to this email directly or view it on GitHub: https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1379598141 You are receiving this because you commented.

Message ID: @.***>

kokoko3k commented 1 year ago

Yes, Vulkan btw. In a few hours i'll check with glcore. I'm on Linux, but I've had feedback that it should work even on Windows at least.

On 12 January 2023 00:09:14 CET, estefan3112 @.***> wrote:

Im checked on Windows, and -1 auto-rotate also does not work there. To be sure, we are talking about the Vulkan video driver, right? Are there any other options to consider that might be relevant?

-- Reply to this email directly or view it on GitHub: https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1379598141 You are receiving this because you commented.

Message ID: @.***>

estefan3112 commented 1 year ago

I'm not expert of fbneo. Are you using tate mode, maybe? (the core pre-rotates the content)? Is retroarch scaling/aspect set to full (stupid question)

On 12 January 2023 00:09:14 CET, estefan3112 @.***> wrote:

Im checked on Windows, and -1 auto-rotate also does not work there. To be sure, we are talking about the Vulkan video driver, right? Are there any other options to consider that might be relevant?

-- Reply to this email directly or view it on GitHub: https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1379598141 You are receiving this because you commented.

Message ID: @.***>

All negative, sir 😃

estefan3112 commented 1 year ago

Yes, Vulkan btw. In a few hours i'll check with glcore. I'm on Linux, but I've had feedback that it should work even on Windows at least.

On 12 January 2023 00:09:14 CET, estefan3112 @.***> wrote:

Im checked on Windows, and -1 auto-rotate also does not work there. To be sure, we are talking about the Vulkan video driver, right? Are there any other options to consider that might be relevant?

-- Reply to this email directly or view it on GitHub: https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1379598141 You are receiving this because you commented.

Message ID: @.***>

It is no issue anyway, as I just set the correct rotation by game.

estefan3112 commented 1 year ago

Hello again :-). May I ask you for a favour and look into my fork: https://github.com/estefan3112/koko-aio-slang I have now 5 presets ready that should be ready for release. I would be very grateful for your opinion whether this is fine from your perspective as well.
Basic structure:

kokoko3k commented 1 year ago

Hi there. What a nice place is Vienna!

I'll take a deeper look tomorrow (not to Vienna, sadly, "just" your presets), but by now, my suggestion is to release the whole repo, your whole fork, because :

1) you are certain that the presets you made will act exactly as you want, because you are protected against changes made to koko aio upstream. 2) you can reference your own parent presets, more or less as I suggested you here , less directories jumping up and down, all stays relative to your subdirectory. 3) you can tell users to download the zip file of your fork release and just unpack it somewhere in retroarch slangp shader folder.

I think it would be much simpler and be not dependant on retroarch's folder structure or koko-aio changes.

The part about fbneo and its config file is not clear to me, as i dont use it, but prefer mame plus.

As for libretro forums, why don't you publish your work there standalone as others already do, see great sonkun's presets of the great guest.r parent/main shader?

estefan3112 commented 1 year ago

Many thanks for your immediate reply, much appreciated!

  1. Yes you are right, I should publish a full repo. That I'll only if I have some artwork ready, not just five.
  2. I considered your suggestion at length, however, there is a huge benefit in putting the dedicated slangp's into the config directory (should also work for Mame2003, will check). Because they just then start without any further configuration required.
  3. Correct, plus the extra step to move the slangp's into the config/FinalBurn Neo or Mame2003 (to be checked) folder.

I will also try the same logic with Mame2003. Only with a first serious release, I'll then go into the forums.

Speaking of Vienna/Italy: For me end of May will see some serious vintage biking in Montalcino, very much look forward to this event!!!

estefan3112 commented 1 year ago

I briefly tested Mame2003, and the slangp shaders work exactly the same (however Mame2003 tends to crash on my Apple Silicon on some games). So you can put all game-specific .slangp files into /config/Mame 2003 (0.78)/, and the games will launch the shader automatically without further configuration required. Cheers!

kokoko3k commented 1 year ago

Hi there, maybe you are interested in knowing that i've made this new repo: https://github.com/kokoko3k/koko-aio-slang-presets-and-overlays

estefan3112 commented 1 year ago

Hi, many thanks for this offer! Right now, I prepare a first release with 20 game-specific presets that require to be installed in the respective core config directory (as discussed above). I need to see whether this also fits in your repository - but I'll definitely will always stay as a fork under your repo, still syncing your recent changes 😅

kokoko3k commented 1 year ago

Hi there, I wanted to tell you that i'm refactoring bezel/reflection code to hopefully improve look and customization possibilities. So if you see something strange about it, it is probably expected till i'll end this.

Cheers!

estefan3112 commented 1 year ago

Thanks, I am a regular reader of your GitHub commit notes - not that I would understand that much 😂

kokoko3k commented 1 year ago

Ahah, I commit so much to keep teack of every single bit i change and keep track of regression easilly, git is great. Btw, reading my own commits after some time makes heavier to understand even for me, so i can understand :)

On 28 February 2023 20:29:23 CET, estefan3112 @.***> wrote:

Thanks, I am a regular reader of your GitHub commit notes - not that I would understand that much 😂>

-- > Reply to this email directly or view it on GitHub:> https://github.com/kokoko3k/koko-aio-slang/issues/1#issuecomment-1448741874> You are receiving this because you commented.>

Message ID: @.***>

estefan3112 commented 1 year ago

Did some testing with today's codebase and my custom arcade artwork: all three systems work perfectly, bezel effects subjectively look nicer than ever. Besides my main Silicon Mac mini, shaders look perfect on the Intel iMac and the Windows 11 PC (both with GeForce cards). Couldn't be happier. Time to update the bezel packages...