Skip to content

Fix shader not working on macos - #226

Open
Catizard wants to merge 1 commit into
seraxis:mainfrom
Catizard:fix/shader_wont_work
Open

Fix shader not working on macos#226
Catizard wants to merge 1 commit into
seraxis:mainfrom
Catizard:fix/shader_wont_work

Conversation

@Catizard

Copy link
Copy Markdown
Collaborator

This pr is demanding volunteers for testing on linux and widnows.

This pr aims to fix the issue that shander doesn't work on macos, and properly, linux. The initial problem is some old bms, e.g. gengaozo, is using an old trick which is so called "black color keying" to mimic the "transparent color". In beatoraja, this is achieved by using a shader. However, the shader file is using the old standard that simply won't compile on macos and linux. Causing gengaozo's bga looks funny and has crazy flashes that can burn ppl eyes.

In this pr, I rerouted the shader files to _unix variant if os is mac or linux.

For more information, please check out https://hitkey.bms.ms/cmds.htm#BMPXX-LAYER.

This pr has a high possibility is related to #210, I haven't looked into it yet

Side notes for devs
There was an old issue when supporting mac: the bga video is displaying RGB color in wrong order (Expected RGB, Got BGR iirc), this issue is having a high possibility that is because the ffmpeg shader is not applying because it cannot be compiled on macos

Comment thread core/src/bms/player/beatoraja/ShaderManager.java Outdated
@Catizard
Catizard force-pushed the fix/shader_wont_work branch from cc4ff8b to 6f3a2e2 Compare February 26, 2026 12:33
@Catizard

Copy link
Copy Markdown
Collaborator Author

After looking into the issues pointed in #210, I found none of them would be fixed in this pr although they seems to be rather related to the problem solved in this pr. Especially the transparent colors are still broken after the changes based on the fact that they are looking fine on my test application.

@Catizard
Catizard force-pushed the fix/shader_wont_work branch from 6f3a2e2 to 422101d Compare March 9, 2026 12:40
@Catizard
Catizard force-pushed the fix/shader_wont_work branch from 422101d to 05bdb91 Compare March 17, 2026 09:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants