Faulty generated OpenGL Shader keyword fails "silently"

27 views
Skip to first unread message

William Candillon

unread,
May 28, 2024, 8:18:14 AMMay 28
to skia-discuss
Hello team, 


Here with WebGL the error is clear and this how we were able to fix it immediately.
However the error is not really thrown by Skia but rather WebGL.
So on Android for instance, the runtime effect factory returns non-null and no text error.

On Metal, such SKSL works as expected.

Here it looks like something could be consolidated here? Let me know your thoughts here.

Kind regards,

William

John Stiles

unread,
May 28, 2024, 8:33:03 AMMay 28
to skia-d...@googlegroups.com
I'll take a look today and sort it out. Thanks for letting me know. 

--
You received this message because you are subscribed to the Google Groups "skia-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to skia-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/skia-discuss/dfe0cda8-cb66-4999-918b-a562e48d483en%40googlegroups.com.

John Stiles

unread,
May 28, 2024, 11:20:46 AMMay 28
to skia-d...@googlegroups.com
Interesting; the word "filter" was added as a reserved word in OpenGL ES3. SkSL does enforce the ES2 reserved-word list, but the spec added additional reserved words in later versions of the standard.

That's a good catch. For now, the simple fix is to avoid using reserved words in a shader; I will look at expanding our reserved-word list to encompass the latest standards in a future Skia milestone. 
Reply all
Reply to author
Forward
0 new messages