Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8098265

Check use of HIGHP with es shaders.

    Details

    • Type: Enhancement
    • Status: Closed
    • Priority: P3
    • Resolution: Won't Fix
    • Affects Version/s: 8
    • Fix Version/s: None
    • Component/s: javafx

      Description

      GLES has an issue with the definition of precision with integers. It solves this with defining 3 integers as, lowp, mediump and highp. But highp may not be available.

      Of 4 GPU families tested, only one, the Mali seems to have issue with highp, and emits a warning that highp will fallback to midp.
      Currently that GPU is not on the critical path, so this is probably not a "high" Jira.

      Note, I found several suggestions that using lower precision may (or may not) improve performance.

      Per the spec: "If an implementation does not support highp precision in the fragment language, and state is listed as highp, then that state will only be available as mediump in the fragment language."\

      Looking at the generated fragments, we mention HIGHP, MEDIUMP and LOWP, and we define int and float as 'highp', so any use of those may be impacted in the fragments.

      The minimum ranges that OpenGL ES 2.0 implementations have to support for integers are:
      lowp [-255, +255]
      mediump [-1023, +1023]
      highp [-65535, +65535]

      Our "standard" intro for all fragments:

      #ifdef GL_ES
      #extension GL_OES_standard_derivatives : enable
      precision highp float;
      precision highp int;
      #define HIGHP highp
      #define MEDIUMP mediump
      #define LOWP lowp
      #else
      #define HIGHP
      #define MEDIUMP
      #define LOWP
      #endif


        Attachments

          Activity

            People

            • Assignee:
              flar Jim Graham
              Reporter:
              ddhill David Hill (Inactive)
            • Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:
                Imported: