New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] SKRuntimeEffect compilation is missing build-in functions #1868
Comments
It errors with 'round' or 'mod' as well.. I'm wondering if it's 'cause it's a bit older of Skia? It kinda hampers the simple 'checkerboard' pattern shader I was gonna make. Not even 'coord.x % 32.0' works. |
Can confirm it fails with 'mod' as well. I'm using version 2.88.3 of SkiaSharp inside a .NET MAUI application. It would be great if support for these basic shader functions was added, especially since they work perfectly in the skia shader playground |
Updating skia to the latest makes most of the functions work, however, the |
Duplicate of #2543 |
Description
I've been trying out the new SKRuntimeEffect support in 2.88.0-preview.155 . Compilation of shaders using some opengl functions fails. (Tested with step and smoothstep). Not sure if this a skiasharp problem or a skia problem.
Code
Expected Behavior
This should compile. The same code works on the skia-sksl demo https://shaders.skia.org/.
Actual Behavior
Compilation outputs the following error:
error: 9: unknown identifier 'step'
This also happens with 'smoothstep'. Its weird that the 'length' function still works though. I have read that Skia only supports a subset of GL functions, but since it works on the demo site and these being very important shader functions, I doubt that they aren't included.
Basic Information
The text was updated successfully, but these errors were encountered: