Skip to content

GL_EXT_frag_depth reported missing even if enabled #1405

Closed
avaer/webgl-to-opengl
#7
@chrismile

Description

@chrismile

Describe the bug
When using gl_FragDepthEXT in a WebGL 1 context with exokit, the following error message is printed on the command line even when GL_EXT_frag_depth is enabled (unimportant parts omitted in the text below).

[
  '#extension GL_EXT_frag_depth : enable',
  'precision highp float;',
  'uniform vec3 uAmbient;',
  ...
  'gl_FragDepthEXT = (projPoint.z / projPoint.w + 1.0) / 2.0;',
  ...
]
v {
  message: 'Error compiling shader:\n0(158) : error C7531: global variable ' +
    'gl_FragDepthEXT requires "#extension GL_EXT_frag_depth : enable" ' +
    'before use\n'
}

To Reproduce
Open any web page using GL_EXT_frag_depth and gl_FragDepthEXT in exokit.

System information:

  • OS: Ubuntu 18.04

  • Exokit Version: master branch from 2019-08-27 (today)

  • Node version: v12.2.0

  • Is your Exokit downloaded or built? Built

  • GPU: NVIDIA GTX 1070

  • Driver version: 430.40

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions