Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clipping planes don't work on certain Android devices #8061

Open
OmarShehata opened this issue Aug 14, 2019 · 7 comments
Open

Clipping planes don't work on certain Android devices #8061

OmarShehata opened this issue Aug 14, 2019 · 7 comments

Comments

@OmarShehata
Copy link
Contributor

OmarShehata commented Aug 14, 2019

Brought up on the forum.

On my Pixel 3 phone, clipping planes don't work at all. I can see the plane moving but it's as if the discard isn't doing anything. Testing this on the clipping planes Sandcastle

https://cesiumjs.org/Cesium/Apps/Sandcastle/index.html?src=3D%20Tiles%20Clipping%20Planes.html

I thought it might be when we changed clipping planes from passing uniforms, to packing it into a texture, which was in 1.44, but trying the 1.43 version also doesn't work (try the model in the drop down):

https://cesiumjs.org/releases/1.43/Apps/Sandcastle/index.html?src=3D%20Tiles%20Clipping%20Planes.html&label=Showcases

Here's my WebGLReport on this phone:

Screenshot_20190814-094523

Interestingly, it works on @likangning93 's much older Android, which is also Qualcomm but is an Adreno (TM) 308.

The model does sort of shimmer a bit, so you can tell that something is happening. On the globe clipping planes, the result is different:

Screenshot_20190814-100437

The only one that seems to work is isolating a piece of terrain, but this is only because of the CPU clipping full tiles, still not actually successfully discarding fragments:

Screenshot_20190814-100458

@likangning93
Copy link
Contributor

likangning93 commented Aug 14, 2019

Interestingly, it works on @likangning93 's much older Android, which is also Qualcomm but is an Adreno (TM) 308.

here's my webglreport:

Platform:    Linux armv7l
Browser User Agent:    Mozilla/5.0 (Linux; Android 7.1.1; Moto E (4)) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/76.0.3809.89 Mobile Safari/537.36
Context Name:    webgl
GL Version:    WebGL 1.0 (OpenGL ES 2.0 Chromium)
Shading Language Version:    WebGL GLSL ES 1.0 (OpenGL ES GLSL ES 1.0 Chromium)
Vendor:    WebKit
Renderer:    WebKit WebGL
Unmasked Vendor:    Qualcomm
Unmasked Renderer:    Adreno (TM) 308
Antialiasing:    Available
ANGLE:    No
Major Performance Caveat:    No
Vertex Shader
Max Vertex Attributes:    16
Max Vertex Uniform Vectors:    256
Max Vertex Texture Image Units:    16
Max Varying Vectors:    16
Best float precision:    [-2127, 2127] (23)
Transform Feedback
Coming in WebGL 2
Rasterizer
Aliased Line Width Range:    [1, 8]
Aliased Point Size Range:    [1, 1023]
Fragment Shader
Max Fragment Uniform Vectors:    224
Max Texture Image Units:    16
float/int precision:    highp/highp
Best float precision:    [-2127, 2127] (23)
Framebuffer
Max Color Buffers:    1
RGBA Bits:    [8, 8, 8, 8]
Depth / Stencil Bits:    [24, 8]
Max Render Buffer Size:    4096
Max Viewport Dimensions:    [4096, 4096]
Textures
Max Texture Size:    4096
Max Cube Map Texture Size:    4096
Max Combined Texture Image Units:    32
Max Anisotropy:    16
Uniform Buffers
Coming in WebGL 2
Supported Extensions:
ANGLE_instanced_arrays
EXT_blend_minmax
EXT_color_buffer_half_float
EXT_texture_filter_anisotropic
WEBKIT_EXT_texture_filter_anisotropic
EXT_sRGB
OES_element_index_uint
OES_standard_derivatives
OES_texture_float
OES_texture_half_float
OES_texture_half_float_linear
OES_vertex_array_object
WEBGL_color_buffer_float
WEBGL_compressed_texture_etc1
WEBGL_debug_renderer_info
WEBGL_debug_shaders
WEBGL_lose_context
WEBKIT_WEBGL_lose_context

@OmarShehata
Copy link
Contributor Author

WebGL report from the forum user who encountered this, also a Qualcomm, and Adreno 640:

Adreno_640

@zhangwenjin
Copy link

On my phone, clipping planes don't work at all
mywebgl

@OmarShehata
Copy link
Contributor Author

@zhangwenjin what kind of phone is it? Your WebGL report screenshot is missing the "platform/vendor/renderer" information at the top which is relevant here.

@zhangwenjin
Copy link

@OmarShehata
web2

@zhangwenjin
Copy link

@OmarShehata
Vertex Shader
Max Vertex Attributes: 16
Max Vertex Uniform Vectors: 1024
Max Vertex Texture Image Units: 16
Max Varying Vectors: 15
Best float precision: [-2127, 2127] (23)
Max Vertex Uniform Components: 4096
Max Vertex Uniform Blocks: 12
Max Vertex Output Components: 64
Max Varying Components: 60
Transform Feedback
Max Interleaved Components: 64
Max Separate Attribs: 4
Max Separate Components: 4
Rasterizer
Aliased Line Width Range: [1, 4095.9375]
Aliased Point Size Range: [1, 1024]
Fragment Shader
Max Fragment Uniform Vectors: 1024
Max Texture Image Units: 16
float/int precision: highp/highp
Best float precision: [-2127, 2127] (23)
Max Fragment Uniform Components: 4096
Max Fragment Uniform Blocks: 12
Max Fragment Input Components: 60
Min Program Texel Offset: -8
Max Program Texel Offset: 7
Framebuffer
Max Draw Buffers: 4
Max Color Attachments: 4
Max Samples: 4
RGBA Bits: [8, 8, 8, 8]
Depth / Stencil Bits: [24, 8]
Max Render Buffer Size: 8192
Max Viewport Dimensions: [8192, 8192]
Textures
Max Texture Size: 4096
Max Cube Map Texture Size: 4096
Max Combined Texture Image Units: 96
Max Anisotropy: n/a
Max 3D Texture Size: 4096
Max Array Texture Layers: 256
Max Texture LOD Bias: 256
Uniform Buffers
Max Uniform Buffer Bindings: 72
Max Uniform Block Size: 16384
Uniform Buffer Offset Alignment: 16
Max Combined Uniform Blocks: 72
Max Combined Vertex Uniform Components: 53248
Max Combined Fragment Uniform Components: 53248
Supported Extensions:
EXT_color_buffer_float
WEBGL_compressed_texture_astc
WEBGL_compressed_texture_etc
WEBGL_compressed_texture_etc1
WEBGL_debug_renderer_info
WEBGL_debug_shaders
WEBGL_lose_context

To see draft extensions in Chrome, browse to about:flags, enable the "Enable WebGL Draft Extensions" option, and relaunch.

WebGL 2 Functions Implementation Status:
88 of 88 new functions implemented.

copyBufferSubData
getBufferSubData
blitFramebuffer
framebufferTextureLayer
getInternalformatParameter
invalidateFramebuffer
invalidateSubFramebuffer
readBuffer
renderbufferStorageMultisample
texStorage2D
texStorage3D
texImage3D
texSubImage3D
copyTexSubImage3D
compressedTexImage3D
compressedTexSubImage3D
getFragDataLocation
uniform1ui
uniform2ui
uniform3ui
uniform4ui
uniform1uiv
uniform2uiv
uniform3uiv
uniform4uiv
uniformMatrix2x3fv
uniformMatrix3x2fv
uniformMatrix2x4fv
uniformMatrix4x2fv
uniformMatrix3x4fv
uniformMatrix4x3fv
vertexAttribI4i
vertexAttribI4iv
vertexAttribI4ui
vertexAttribI4uiv
vertexAttribIPointer
vertexAttribDivisor
drawArraysInstanced
drawElementsInstanced
drawRangeElements
drawBuffers
clearBufferiv
clearBufferuiv
clearBufferfv
clearBufferfi
createQuery
deleteQuery
isQuery
beginQuery
endQuery
getQuery
getQueryParameter
createSampler
deleteSampler
isSampler
bindSampler
samplerParameteri
samplerParameterf
getSamplerParameter
fenceSync
isSync
deleteSync
clientWaitSync
waitSync
getSyncParameter
createTransformFeedback
deleteTransformFeedback
isTransformFeedback
bindTransformFeedback
beginTransformFeedback
endTransformFeedback
transformFeedbackVaryings
getTransformFeedbackVarying
pauseTransformFeedback
resumeTransformFeedback
bindBufferBase
bindBufferRange
getIndexedParameter
getUniformIndices
getActiveUniforms
getUniformBlockIndex
getActiveUniformBlockParameter
getActiveUniformBlockName
uniformBlockBinding
createVertexArray
deleteVertexArray
isVertexArray
bindVertexArray

@zhangwenjin
Copy link

Several tpye of Huawei mobile phones have been tested,clipping planes don't work at all

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants