Search Issue Tracker

By Design

Votes

10

Found in

5.4.0b21

Issue ID

804159

Regression

No

[iOS][GLES] Extension 'GL_EXT_frag_depth' is not supported when running on GLES2

Image Effects

-

To Reproduce:

1. Build and run the attached project with 5.4 (tested on b21) on iOS with GLES2 on iOS.
2. Observe that these errors are outputted to the console:

-------- failed compiling:
fragment evaluation shader
WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
ERROR: 0:31: Use of undeclared identifier 'gl_FragDepthEXT'

--

shader ‘Fishlabs/Diffuse’ shader in ‘Assets/Shaders’

This is not reproducible when using the same shader on 5.3:
Version 5.3.4p6 (9eb825cf2ca3)
Mon, 02 May 2016 11:15:14 GMT
Branch: 5.3/patch-release

Reprodcued on:
Version 5.4.0b21 (ebe3d2a59a59)
Wed, 01 Jun 2016 05:42:30 GMT
Branch: 5.4/staging

Comments (18)

  1. moodooguru123

    Nov 19, 2016 15:01

    I'm having the same issue using Unity 5.4.0f3 when I test on iPad2 and iPod Touch 5th generation. Will we get a notice from Unity when this issue is fixed?

  2. Christin2015

    Nov 08, 2016 12:53

    I get the same issue in Unity 5.4.2f2 , using MacOS El Sierra here.
    on
    iPad mini (iOS 9.3.5)
    iPad Air 2, (iOS 9.3.5)
    iPhone6 , (iOS 10.1.1)

  3. kupalinka

    Nov 06, 2016 09:31

    WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
    ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'

    Unity 5.5.0xb2linux

  4. naveen_pambi

    Nov 02, 2016 06:13

    I face the same issue in Unity5.4.2 p2, any fixes?

  5. elpuerco63

    Oct 24, 2016 13:48

    I'm getting the same issue on my iPads regardless of iOS version!

  6. Mukabr

    Oct 19, 2016 03:39

    I'm having the same issue with my app.
    1 iPad mini 1 + iOS 8.3, running failed
    2 iPad mini 2 + iOS 9.3.5, running failed
    3 iPhone 5 + iOS 10.0.2, running success

    Builded with Unity 5.4.1p2

    2016-10-19 11:20:20.787 fishingtreasure[5157:877814] -> registered mono modules 0xfa8f10
    -> applicationDidFinishLaunching()
    -> applicationDidBecomeActive()
    Renderer: PowerVR SGX 543
    Vendor: Imagination Technologies
    Version: OpenGL ES 2.0 IMGSGX543-115.5
    GLES: 2
    GL_OES_depth_texture GL_OES_depth24 GL_OES_element_index_uint GL_OES_fbo_render_mipmap GL_OES_mapbuffer GL_OES_packed_depth_stencil GL_OES_rgb8_rgba8 GL_OES_standard_derivatives GL_OES_texture_float GL_OES_texture_half_float GL_OES_texture_half_float_linear GL_OES_vertex_array_object GL_EXT_blend_minmax GL_EXT_color_buffer_half_float GL_EXT_debug_label GL_EXT_debug_marker GL_EXT_discard_framebuffer GL_EXT_draw_instanced GL_EXT_instanced_arrays GL_EXT_map_buffer_range GL_EXT_occlusion_query_boolean GL_EXT_pvrtc_sRGB GL_EXT_read_format_bgra GL_EXT_separate_shader_objects GL_EXT_shader_framebuffer_fetch GL_EXT_shader_texture_lod GL_EXT_shadow_samplers GL_EXT_sRGB GL_EXT_texture_filter_anisotropic GL_EXT_texture_rg GL_EXT_texture_storage GL_APPLE_clip_distance GL_APPLE_color_buffer_packed_float GL_APPLE_copy_texture_levels GL_APPLE_framebuffer_multisample GL_APPLE_rgb_422 GL_APPLE_sync GL_APPLE_texture_format_BGRA8888 GL_APPLE_texture_max_level GL_APPLE_texture_packed_float GL_IMG_read_format GL_IMG_texture_comp
    ression_pvrtc
    OPENGL LOG: Creating OpenGL ES 2.0 graphics device ; Context level <OpenGL ES 2.0> ; Context handle 384130096
    Initialize engine version: 5.4.1p2 (a8ddefd1bf1d)
    OnLevelWasLoaded was found on Reporter
    This message has been deprecated and will be removed in a later version of Unity.
    Add a delegate to SceneManager.sceneLoaded instead to get notifications after scene loading has completed

    (Filename: Line: 375)

    OnLevelWasLoaded was found on SoundManager
    This message has been deprecated and will be removed in a later version of Unity.
    Add a delegate to SceneManager.sceneLoaded instead to get notifications after scene loading has completed

    (Filename: Line: 375)

    -------- Shader compilation failed
    #version 100
    #extension GL_EXT_frag_depth : enable
    precision highp float;
    uniform highp vec4 _ProjectionParams;
    uniform highp vec4 _ZBufferParams;
    uniform highp mat4 unity_CameraToWorld;
    uniform highp mat4 _NonJitteredVP;
    uniform highp mat4 _PreviousVP;
    uniform highp sampler2D _CameraDepthTexture;
    varying highp vec2 xlv_TEXCOORD0;
    varying highp vec3 xlv_TEXCOORD1;
    void main ()
    {
    highp vec4 tmpvar_1;
    tmpvar_1 = texture2D (_CameraDepthTexture, xlv_TEXCOORD0);
    mediump vec2 tmpvar_2;
    highp vec4 tmpvar_3;
    tmpvar_3.w = 1.0;
    tmpvar_3.xyz = ((xlv_TEXCOORD1 * (_ProjectionParams.z / xlv_TEXCOORD1.z)) * (1.0/((
    (_ZBufferParams.x * tmpvar_1.x)
    + _ZBufferParams.y))));
    highp vec4 tmpvar_4;
    tmpvar_4 = (unity_CameraToWorld * tmpvar_3);
    highp vec4 tmpvar_5;
    tmpvar_5 = (_PreviousVP * tmpvar_4);
    highp vec4 tmpvar_6;
    tmpvar_6 = (_NonJitteredVP * tmpvar_4);
    highp vec2 tmpvar_7;
    tmpvar_7 = (((tmpvar_5.xy / tmpvar_5.w) + 1.0) / 2.0);

    highp vec2 tmpvar_8;
    tmpvar_8 = (((tmpvar_6.xy / tmpvar_6.w) + 1.0) / 2.0);
    tmpvar_2 = (tmpvar_8 - tmpvar_7);
    mediump vec4 tmpvar_9;
    tmpvar_9.zw = vec2(0.0, 1.0);
    tmpvar_9.xy = tmpvar_2;
    gl_FragDepthEXT = tmpvar_1.x;
    gl_FragData[0] = tmpvar_9;
    }
    -------- failed compiling:
    fragment evaluation shader
    WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
    ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'

    Note: Creation of internal variant of shader 'Hidden/Internal-MotionVectors' failed.
    WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Pass '' has no vertex shader
    WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Setting to default shader.

  7. Velvety

    Oct 07, 2016 03:48

    This is STILL and issue in the latest Unity 5.4.1p4. Is this ever going to be fixed? My game works great on iPhone 6, but on Ipad Mini, multiple shaders including the built in mobile/diffuse return this same error and don't render on the device. All of this worked fine prior to Unity 5.

    The status says this is fixed but it is definitely not! Can we get an update on this please?

    -------- Shader compilation failed
    #version 100
    #extension GL_EXT_frag_depth : enable
    precision highp float;
    uniform highp vec4 _ProjectionParams;
    uniform highp vec4 _ZBufferParams;
    uniform highp mat4 unity_CameraToWorld;
    uniform highp mat4 _NonJitteredVP;
    uniform highp mat4 _PreviousVP;
    uniform highp sampler2D _CameraDepthTexture;
    varying highp vec2 xlv_TEXCOORD0;
    varying highp vec3 xlv_TEXCOORD1;
    void main ()
    {
    highp vec4 tmpvar_1;
    tmpvar_1 = texture2D (_CameraDepthTexture, xlv_TEXCOORD0);
    mediump vec2 tmpvar_2;
    highp vec4 tmpvar_3;
    tmpvar_3.w = 1.0;
    tmpvar_3.xyz = ((xlv_TEXCOORD1 * (_ProjectionParams.z / xlv_TEXCOORD1.z)) * (1.0/((
    (_ZBufferParams.x * tmpvar_1.x)
    + _ZBufferParams.y))));
    highp vec4 tmpvar_4;
    tmpvar_4 = (unity_CameraToWorld * tmpvar_3);
    highp vec4 tmpvar_5;
    tmpvar_5 = (_PreviousVP * tmpvar_4);
    highp vec4 tmpvar_6;
    tmpvar_6 = (_NonJitteredVP * tmpvar_4);
    highp vec2 tmpvar_7;
    tmpvar_7 = (((tmpvar_5.xy / tmpvar_5.w) + 1.0) / 2.0);
    highp vec2 tmpvar_8;
    tmpvar_8 = (((tmpvar_6.xy / tmpvar_6.w) + 1.0) / 2.0);
    tmpvar_2 = (tmpvar_8 - tmpvar_7);
    mediump vec4 tmpvar_9;
    tmpvar_9.zw = vec2(0.0, 1.0);
    tmpvar_9.xy = tmpvar_2;
    gl_FragDepthEXT = tmpvar_1.x;
    gl_FragData[0] = tmpvar_9;
    }
    -------- failed compiling:
    fragment evaluation shader
    WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
    ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'

    Note: Creation of internal variant of shader 'Hidden/Internal-MotionVectors' failed.
    WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Pass '' has no vertex shader
    WARNING: Shader Unsupported: 'Hidden/Internal-MotionVectors' - Setting to default shader.

  8. szu3d

    Sep 06, 2016 07:57

    -------- Shader compilation failed
    #version 100
    #extension GL_EXT_frag_depth : enable
    precision highp float;
    uniform highp vec4 _ProjectionParams;
    uniform highp vec4 _ZBufferParams;
    uniform highp mat4 unity_CameraToWorld;
    uniform highp mat4 _NonJitteredVP;
    uniform highp mat4 _PreviousVP;
    uniform highp sampler2D _CameraDepthTexture;
    varying highp vec2 xlv_TEXCOORD0;
    varying highp vec3 xlv_TEXCOORD1;
    void main ()
    {
    highp vec4 tmpvar_1;
    tmpvar_1 = texture2D (_CameraDepthTexture, xlv_TEXCOORD0);
    mediump vec2 tmpvar_2;
    highp vec4 tmpvar_3;
    tmpvar_3.w = 1.0;
    tmpvar_3.xyz = ((xlv_TEXCOORD1 * (_ProjectionParams.z / xlv_TEXCOORD1.z)) * (1.0/((
    (_ZBufferParams.x * tmpvar_1.x)
    + _ZBufferParams.y))));
    highp vec4 tmpvar_4;
    tmpvar_4 = (unity_CameraToWorld * tmpvar_3);
    highp vec4 tmpvar_5;
    tmpvar_5 = (_PreviousVP * tmpvar_4);
    highp vec4 tmpvar_6;
    tmpvar_6 = (_NonJitteredVP * tmpvar_4);
    highp vec2 tmpvar_7;
    tmpvar_7 = (((tmpvar_5.xy / tmpvar_5.w) + 1.0) / 2.0);
    highp vec2 tmpvar_8;
    tmpvar_8 = (((tmpvar_6.xy / tmpvar_6.w) + 1.0) / 2.0);
    tmpvar_2 = (tmpvar_8 - tmpvar_7);
    mediump vec4 tmpvar_9;
    tmpvar_9.zw = vec2(0.0, 1.0);
    tmpvar_9.xy = tmpvar_2;
    gl_FragDepthEXT = tmpvar_1.x;
    gl_FragData[0] = tmpvar_9;
    }
    -------- failed compiling:
    fragment evaluation shader
    WARNING: 0:4: extension 'GL_EXT_frag_depth' is not supported
    ERROR: 0:38: Use of undeclared identifier 'gl_FragDepthEXT'

    5.4.0P4

Add comment

Log in to post comment

All about bugs

View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.