RFR: 8237770: Error creating fragment phong shader on iOS

Kevin Rushforth kcr at openjdk.java.net
Fri Jan 31 06:51:37 UTC 2020

On Fri, 24 Jan 2020 11:31:02 GMT, Jose Pereda <jpereda at openjdk.org> wrote:

> This PR defines a pre-processor in the phong frag files to avoid inline declaration of #extension when several frags are combined that leads to the error:
> syntax error: #extension must always be before any non-preprocessor tokens

I verified that this works correctly. I have a minor style comment for you to consider.

modules/javafx.graphics/src/main/resources/com/sun/prism/es2/glsl/diffuse_color.frag line 32:

> 31: #extension GL_OES_standard_derivatives : enable
> 33: #endif

Usual practice is to put the `#define` right after the `#ifndef`, but I don't have a strong opinion about that.


PR: https://git.openjdk.java.net/jfx/pull/93

More information about the openjfx-dev mailing list