RetroPie cocktail shader

Hello, To start sorry to dig up this topic and sorry for my english (google translation). Already, thank you for the work done on this beautiful cocktail shader that works perfectly well with my config already quite a lot of systems (see photo).

New photo by Jerome Boulinguez

That being said, I have a little problem with this one on some systems and some arcade games. I can not call the 2 zones correctly: I have a zone in the center that is superimposed, when I modify the parameter “image separation”, it still remains a white zone and moreover, it removes pixels in low image (see photos). When I reduce the zoom, it fixes the problem of missing pixels but suddenly, I can not display the area across the width of the screen.

New photo by Jerome Boulinguez New photo by Jerome Boulinguez

I tried to understand the programming of the shader but I did not understand anything and I can not find the changes to make to avoid these 2 problems. If you can give me a hand, it’ll be really good of you Thanks again, MarbleMad

VOFR : Bonjour, Pour commencer désolé de déterrer ce sujet et désolé pour mon anglais (google traduction). Déjà, merci pour le travail effectué sur ce superbe shader cocktail qui fonctionne parfaitement bien avec ma config déjà pas mal de systèmes (voir photo). Ceci étant dit, j’ai un petit problème avec celui-ci sur certains systèmes et certains jeux arcade. Je n’arrive pas à caller correctement les 2 zones : J’ai une zone au centre qui se superpose, quand je modifie le paramètre « image séparation », il reste tout de même une zone blanche et de plus, cela enlève des pixels en bas d’image (voir photos). Quand je réduis le zoom, cela régle le problème des pixels manquant mais du coup, je n’arrive pas à afficher la zone sur toute la largeur de l’écran. J’ai essayé de comprendre la programmation du shader mais je n’ai rien compris et je n’arrive pas à trouver les modifications à effectuer pour éviter ces 2 problèmes. Si vous pouvez me filer un coup de main, ça serai vraiment super de votre part Merci encore, MarbleMad

If you’re using the ‘image separation’ parameter, I think you’re using a very old version of the shader. Try updating and see if it treats you any better.

I’m using this one : https://github.com/bengalaviz/RetroPie

Is it the latest version?

I have also just figured out how to increase the minimum and maximum image height in the script. I was able to exceed the image height has more than 2 which allows me to zoom out and still have the area in any width. I almost reached my goal alone

No, the latest version is here:

Thanks for the link to the uptodate shader !

I have another problem with the uptodate shader, look the photos New photo by Jerome Boulinguez New photo by Jerome Boulinguez

I worked well this morning and I left the old version of shader to make some changes and add parameters to solve the last problems that I had with this version and I got there!

New photo by Jerome Boulinguez

I added the following dynamic parameters: min_, max_, min_, max_y to dynamically define the shader’s processing area and thus I was able to solve my problem of no display at the bottom of the zone and this also solves the problem in the central zone .

I have not yet understood how to add my code edit in github so here is a pastebin failing : https://pastebin.com/m0yNg2XP

I still have a problem of display of parameter in the menus of retroarch because this does not display 2 decimals, I try to multiply by 10 the parameters (0.13 become 1.3) then to divide by 10 (1.3 become 0.13 ) in the script but apparently it does not work because the shader is not applied :frowning:

VOFR : J’ai bien bossé ce matin et je suis partie de l’ancienne version de shader pour effectuer quelques modifications et ajouter des paramètres afin de régler les derniers problèmes que j’avais avec cette version et j’y suis arrivé !

J’ai ajouté les paramètres dynamiques suivant : min_,max_, min_,max_y pour définir dynamiquement la zone de traitement du shader et j’ai ainsi pu régler mon problème de non affichage en bas de zone et cela règle également le problème en zone centrale.

Je n’ai pas encore bien compris comment ajouter mon code modifier sous github donc voici un pastebin à défaut : https://pastebin.com/m0yNg2XP

Il me reste encore un problème d’affichage de paramètre dans les menus de retroarch car ceci n’affichage de 2 décimals, j’ai essayer de multiplier par 10 les paramètres (0.13 deviens 1.3) puis de les diviser par 10 (1.3 deviens 0.13) dans le script mais apparemment ça ne va pas car le shader n’est pas appliqué :frowning:

1 Like

The mirror settings that I have (detailed below) look and work great. My issue is that I would like to be able to turn them on/off with a button. I know that there is a hotkey for “next shader” but my issue is that my settings are a combination of a shader and a Custom Aspect Ratio, so “next shader” alone does not work for me.

My settings:

  • The display is rotated with display_rotate=1 in /boot/config.txt
  • The shader that I am using is: cocktail-cab-portrait.glsl from https://github.com/bengalaviz/RetroPie (it might be an older version but it works for me. I get vertical artifacts with the newer version)
  • To get the image to use the entire screen, I change the Aspect Ratio to Custom and then 1200x1920

Again, my final goal is to have a working solution that I can turn on/off with a button (i.e. when there’s only one player, I would like to turn mirroring off.) Any suggestions? Is there any way for the shader to work without changing the aspect ratio?

Thanks!

You could have another shader that handles aspect ratio, like the border or autobox shaders, and switch between them with the ‘next shader’ hotkey.

1 Like

I am a beginner and I am not sure I follow. What I am trying to do is:

Let’s say I launch a new horizontal game (e.g. Metal Slug). With a press of a button you can activare mirroring and then another click of a button would return to single mode - a single horizontal screen, placed in the middle of my vertical display.

Any shader I tried was confined to the preset aspect ratio and unless I changed the aspect ratio of a horizontal game, the mirror shader would not use the whole screen.

The border shaders use the full 16:9 aspect ratio, as well, but they set their own aspect for the game image with the border around it. You could keep your aspect ratio at 16:9 and then switch between the border shader and cocktail table shader using the next/previous shader hotkeys.

Those hotkeys only work on presets that are in the top-level of your shader directory, so you’ll need to create some presets there that point to the shader files.

Hello Hunter! I’m sorry to revive this thread but I am also having the same issues as above with the newest cocktail-cab-portrait.glsl

I have tried all of the hacks in this thread and I am still unable to get things working. Thank you in advance for any help!

The portrait version didn’t have the fix from the landscape version. I’ve added it now, so it should make its way to the online updater pretty soon. If it still gives you trouble, let me know.

Awesome news! Thank you for adding the update. Unfortunately the problem is still there.

I am running retroarch 1.6.0. Do you think an update to the retroarch binary might be the issue after the shader update?

No, updating RA won’t do anything. Can you verify that the shader has the updates?

If you can open the file in a text editor, just make sure the last bit looks like this:

   FragColor = screen1 + screen2;
} 
#endif

I just checked and it does. I verified the date modified on GitHub and then copy/pasted the new shader with ssh.

Ok, thanks for checking. I’ll have to wait until I’m around a GLES device to figure out what’s up.

Sounds good. Thank you again for all of your help!

It’s a strange issue. In the SF2 example it starts to happen during a match. The coin load, and player select screens are fine.

I rewrote the whole thing to work more simply and hopefully without the ugly clamping stuff. It works on my Shield ATV, at least. It should make its way to the online updater soon and should require little-to-no adjustment per-core now, too. Let me know how it treats you.

The new shader is working perfectly! Thank you so much for this, as well as all of your help and hard work!

did you get it up and running?