qgis / QGIS

QGIS is a free, open source, cross platform (lin/win/mac) geographical information system (GIS)
https://qgis.org
GNU General Public License v2.0
10.05k stars 2.92k forks source link

3D Map Canvas is black #40324

Open roya0045 opened 3 years ago

roya0045 commented 3 years ago

tested on 3.16.0 and 3.16.1 on windows 10, installed with osgeo. Two different machines no open GL.

No matter what I do the 3d canvas stays black. All the displays (tiles loading, compass) work as usual but when nothing displays, even if I use the zoom to full extent.

The measurement tool took some clicking about but works.

No opencl support is available on those machines. Machines are VM, issue not present on a normal laptop. 3D in 3.10 works as intended.

image

roya0045 commented 3 years ago

I have installed 3.10.12 through osgeo on the machine with the mentioned issue. Rendering works as intended on 3.10.12. This rules out machine issues.

roya0045 commented 3 years ago

Same behavior with standalone install on the affected machines.

gioman commented 3 years ago

Confirmed here too.

roya0045 commented 3 years ago

@gioman is your machine without a dedicated gpus? The issue seems to occur on machine with integrated graphics on the ones I tested.

gioman commented 3 years ago

is your machine without a dedicated gpus?

yes, integrated gpu.

roya0045 commented 3 years ago

@wonder-sk @nyalldawson @vcloarec I'm pinging you just in case. It seems that machine on win10 without dedicated GPU cannot render the 3D canvas anymore. If the issue was present on linux I would guess that the testing servers would also show that behavior unless they have a gpu. I'm not sure how common this is but I'm curious to know if this is a hardware limitation, how should this be handled?

With a fallback 'more basic' approach or simply not do anything and state that 3D can only be used in 3.10 for users with hardware limitation?

vcloarec commented 3 years ago

Two different machines no open GL.

Rendering works as intended on 3.10.12.

I found those two statement incompatible but maybe I am wrong... @wonder-sk do you know if Qt3D could work without open GL?

roya0045 commented 3 years ago

@vcloarec I meant OpenCL as the message states "No OpenCL compatible devices were found".

vcloarec commented 3 years ago

@roya0045 ah! ok, is it possible to check the version of open GL of the machines ?

roya0045 commented 3 years ago

With GPU Caps Viewer I got the following information:

GL_VENDOR: Microsoft Corporation GL_RENDERER: GDI Generic GL_VERSION: 1.1.0

uclaros commented 3 years ago

Is this reproducible on a real machine (not a VM)? It sounds like an issue between VM and OpenGL.

gioman commented 3 years ago

Is this reproducible on a real machine (not a VM)?

will check this.

gioman commented 3 years ago

issue not present on a normal laptop

Is this reproducible on a real machine (not a VM)? @uclaros seems the answer is in the description

uclaros commented 3 years ago

Wanted to make sure. Braking it down:

Missing info that could affect:

gioman commented 3 years ago
  • host os

  • hypervisor sw

  • qt versions for working vs non working buil

in my case:

host: ubuntu 20.04 hyp: virtualbox qt: using qgis installed with osgeo4w in the vm

roya0045 commented 3 years ago

host: win, I would assume Hyp: citrix qt: osgeo version, can't recall

uclaros commented 3 years ago

working vs non-working qt3d version might be useful

roya0045 commented 3 years ago

@uclaros i think its more about recent changes that are no longer feasible on some hardware (textures, etc) rather than simple dependencies issue.

vcloarec commented 3 years ago

i think its more about recent changes that are no longer feasible on some hardware (textures, etc) rather than simple dependencies issue.

As the GL_VERSION is quite low, indeed, I think it is a new feature that does not work with old opengl. But which one? No idea for now.

Is it possible to try with 3.12 or 3.14 ?

uclaros commented 3 years ago

Comparing the working vs non-working qt versions won't hurt anyway. I have similar black stuff on my taskbar after a recent qt upgrade: Screenshot_2020-12-22_16-13-22

roya0045 commented 3 years ago

@vcloarec once I'm back from vacation I could try 3.12 and 3.14 to see.

agiudiceandrea commented 3 years ago

I can confirm the issue with QGIS 3.16.3 on a Windows 7 SP 1 64 bit (HP Pavillon dv6 - Intel Core i5) using the integrated graphics device (no OpenCL support).

GPU Caps Viewer reports: OpenGL: OpenGL 2.1 (92 ext) - Intel(R) HD Graphics GL_VENDOR: Intel GL_RENDERER: Intel(R) HD Graphics GL_VERSION: 2.1.0 - Build 8.15.10.2189

The issue doesn't occur using QGIS 3.10.1 or 3.14.16 on the same system.

All the tested QGIS versions are installed via OSGeo4W and use Qt 5.11.2.

agiudiceandrea commented 3 years ago

Also tested on the same system, same Qt version 5.11.2:

So it seems it could be some change, introduced between 3.14.16 and 3.16.0, that was not backported to 3.10 branch.

roya0045 commented 3 years ago

@agiudiceandrea Should be a feature adding new capacities to 3d canvas, I suspect its was the material render but I'm not too sure.

PeterPetrik commented 3 years ago

@agiudiceandrea or @roya0045 based on https://qgis.org/en/site/forusers/visualchangelog316/index.html#d-features, it could be well shadows could you verify that you have shadows switched off?

Screen Shot 2021-02-17 at 13 28 53

agiudiceandrea commented 3 years ago

@PeterPetrik the "Shadows" are switched off. Anyway the options panel is different... image

michikommader commented 2 years ago

QGIS 3.20.3 on Windows 10, Version 20H2, Laptop with both Intel HD 520 and NVIDIA GeForce 930 MX graphics cards and recent drivers:

roya0045 commented 2 years ago

Issue seems resolved for me on 3.24

Mouse2 commented 2 years ago

Still present on my machine on QGIS 3.24.3 when trying to display Geotiff raster in 3d Map view. Shadows off.

Kind Regards

Mouse2

System Details Windows 7, fully updated apart from .net 4.51 and updated to same. Currently using (integrated) Intel HD graphics 2000 - as my AMD card is causing BSODs. Open GL version 3.1.0, Direct X 10.1 Driver version: 9.17.10.4229

DCCP80 commented 2 years ago

I tried 3.24 and 3.22, and have the same issue, windows 10 pro for workstation 19044.1706

UHD graphics P630 NVIDIA Quadro RTX 4000 with Max-Q design driver version" 30.0.15.1215

northrivergeo commented 2 years ago

I'm getting the same problem on a Lenovo Laptop and here are the specs: Intel Core i7-8850 2.59 Ghz Ram 16 GB Nvidia Quadro Pro p2000 Integrated card QGIS 3.26.0 and QGIS 3.22 qgis3 26

kannes commented 1 year ago

Is there a list of the GL Extensions used by QGIS 3D available? Maybe that would help drill down on the issue.

wonder-sk commented 8 months ago

Few notes:

kannes commented 8 months ago

Without an ad blocker that site's downloads site is aggressively trying to make the user install malware :\ And the .exe triggers a malware warning on Windows 10 at least. I looked around, Esri and others recommend OpenGL Extensions Viewer. Also triggers a warning from Windows but at least the download page does not present the user with 5 malware download links :D What a crazy world.


I did some tests with VirtualBox, it seems to work alright with its Mesa SVGA3D driver and the default 128MB video RAM assigned to it:

Without 3D acceleration enabled for the guest

GPU 1: VirtualBox Graphics Adapter (WDDM)

GL_VENDOR: Microsoft Corporation
GL_RENDERER: GDI Generic
GL_VERSION: 1.1.0
GL_MAX_TEXTURE_SIZE: 1024
GL_MAX_COLOR_ATTACHMENTS: 0
GL_MAX_TEXTURE_IMAGE_UNITS: 0
GL_MAX_TESS_GEN_LEVEL: 0

Available extensions:

GL_WIN_swap_hint
GL_EXT_bgra

With 3D acceleration enabled for the guest

GPU 1: Microsoft Basic Display Driver

OpenGL 1.1 (2 ext) - GDI Generic

GL_VENDOR: Microsoft Corporation
GL_RENDERER: GDI Generic
GL_VERSION: 1.1.0
GL_MAX_TEXTURE_SIZE: 1024
GL_MAX_COLOR_ATTACHMENTS: 0
GL_MAX_TEXTURE_IMAGE_UNITS: 0
GL_MAX_TESS_GEN_LEVEL: 0

Available extensions:

GL_WIN_swap_hint
GL_EXT_bgra (OpenGL 1.2)

With 3D acceleration enabled for the guest and guest extensions installed

 Renderer: SVGA3D; build: RELEASE;  
 Vendor: Mesa
 Version: 4.1 (Core Profile) Mesa mesa-21.3.8
 Shading language version: 4.10

 Max texture size: 16384 x 16384
 Max vertex texture image units: 16
 Maximum Texture Image Units: 16
 Max geometry texture units: 16
 Maximum Anisotropic Filtering Value: 16
 Max viewport size: 16384 x 16384
 Max Clip Distances: 8
 Max samples: 0

 GL Extensions: 162

 GL_ARB_tessellation_shader
 GL_ARB_parallel_shader_compile
 GL_ARB_half_float_pixel
 GL_KHR_texture_compression_astc_ldr
 GL_EXT_framebuffer_multisample_blit_scaled
 GL_EXT_packed_depth_stencil
 GL_EXT_provoking_vertex
 GL_NV_packed_depth_stencil
 GL_ARB_texture_compression_rgtc
 GL_ARB_draw_instanced
 GL_EXT_draw_buffers2
 GL_ARB_viewport_array
 GL_ARB_gpu_shader_fp64
 GL_EXT_texture_shared_exponent
 GL_ARB_draw_elements_base_vertex
 GL_ARB_arrays_of_arrays
 GL_ARB_explicit_attrib_location
 GL_NV_depth_clamp
 GL_ARB_texture_float
 GL_KHR_no_error
 GL_EXT_EGL_sync
 GL_EXT_transform_feedback
 GL_ARB_depth_buffer_float
 GL_EXT_timer_query
 WGL_EXT_create_context_es_profile
 GL_ARB_vertex_buffer_object
 GL_EXT_packed_float
 GL_ARB_pixel_buffer_object
 GL_ARB_separate_shader_objects
 GL_ARB_buffer_storage
 GL_AMD_draw_buffers_blend
 WGL_EXT_swap_control
 GL_ARB_program_interface_query
 WGL_ARB_extensions_string
 GL_KHR_debug
 GL_ARB_get_texture_sub_image
 GL_ARB_texture_storage
 GL_ATI_blend_equation_separate
 GL_ARB_gpu_shader5
 GL_ARB_ES3_compatibility
 GL_ARB_texture_swizzle
 GL_AMD_conservative_depth
 GL_EXT_texture_compression_dxt1
 GL_EXT_texture_compression_s3tc
 GL_EXT_texture_compression_rgtc
 GL_EXT_texture_sRGB
 GL_ARB_texture_rectangle
 GL_ARB_depth_clamp
 GL_ARB_shading_language_packing
 GL_ARB_texture_cube_map_array
 GL_ARB_framebuffer_sRGB
 WGL_ARB_render_texture
 GL_ARB_texture_rg
 GL_ARB_blend_func_extended
 GL_ATI_texture_float
 WGL_EXT_extensions_string
 GL_ARB_vertex_attrib_64bit
 GL_AMD_shader_trinary_minmax
 GL_EXT_texture_sRGB_decode
 GL_ARB_multi_draw_indirect
 GL_ARB_texture_gather
 GL_ARB_half_float_vertex
 WGL_EXT_create_context_es2_profile
 GL_ARB_debug_output
 GL_EXT_texture_filter_anisotropic
 GL_EXT_pixel_buffer_object
 GL_MESA_texture_signed_rgba
 GL_ARB_invalidate_subdata
 GL_ARB_vertex_array_object
 GL_ARB_explicit_uniform_location
 GL_ARB_vertex_array_bgra
 GL_NV_copy_image
 GL_KHR_parallel_shader_compile
 GL_ARB_shader_texture_lod
 GL_IBM_multimode_draw_arrays
 GL_ARB_texture_filter_anisotropic
 WGL_ARB_pixel_format
 GL_ARB_texture_query_levels
 GL_ARB_point_sprite
 GL_ARB_fragment_layer_viewport
 GL_ARB_copy_buffer
 WGL_ARB_make_current_read
 GL_ARB_robustness
 GL_ARB_get_program_binary
 GL_ARB_transform_feedback2
 GL_ARB_transform_feedback3
 WGL_ARB_pbuffer
 GL_EXT_EGL_image_storage
 GL_EXT_vertex_array_bgra
 GL_ARB_vertex_attrib_binding
 GL_ARB_map_buffer_range
 WGL_ARB_create_context
 GL_ARB_fragment_shader
 GL_ARB_draw_buffers
 GL_EXT_vertex_attrib_64bit
 GL_ARB_copy_image
 GL_ARB_vertex_shader
 GL_EXT_framebuffer_blit
 GL_EXT_framebuffer_sRGB
 GL_ARB_draw_indirect
 GL_ARB_shading_language_420pack
 GL_MESA_shader_integer_functions
 GL_EXT_abgr
 GL_ARB_texture_non_power_of_two
 GL_ARB_texture_buffer_object
 GL_AMD_texture_texture4
 GL_ARB_sync
 GL_ARB_texture_query_lod
 GL_ARB_clear_buffer_object
 GL_EXT_framebuffer_object
 GL_EXT_texture_integer
 GL_NV_conditional_render
 GL_ARB_draw_buffers_blend
 GL_ARB_sample_shading
 GL_ARB_internalformat_query
 GL_ARB_timer_query
 GL_KHR_context_flush_control
 GL_ARB_shader_subroutine
 GL_ARB_conservative_depth
 WGL_ARB_multisample
 GL_ARB_texture_buffer_range
 GL_ARB_shader_precision
 GL_ARB_clip_control
 GL_EXT_texture_swizzle
 GL_KHR_texture_compression_astc_sliced_3d
 GL_ARB_provoking_vertex
 GL_ARB_internalformat_query2
 GL_OES_EGL_image
 GL_AMD_multi_draw_indirect
 GL_ARB_compressed_texture_pixel_storage
 GL_S3_s3tc
 GL_ARB_shader_objects
 GL_ARB_direct_state_access
 GL_EXT_blend_equation_separate
 GL_MESA_pack_invert
 GL_ARB_vertex_type_2_10_10_10_rev
 GL_EXT_draw_instanced
 WGL_ARB_create_context_profile
 GL_ARB_transform_feedback_instanced
 GL_ANGLE_texture_compression_dxt3
 GL_ANGLE_texture_compression_dxt5
 GL_ARB_texture_buffer_object_rgb32
 GL_ARB_instanced_arrays
 GL_ARB_texture_storage_multisample
 GL_ARB_ES2_compatibility
 GL_ARB_uniform_buffer_object
 GL_EXT_framebuffer_multisample
 GL_ARB_texture_multisample
 GL_EXT_shader_integer_mix
 GL_ARB_map_buffer_alignment
 GL_ARB_sampler_objects
 GL_ARB_occlusion_query2
 GL_ARB_shading_language_include
 GL_ARB_framebuffer_object
 GL_ARB_multi_bind
 GL_EXT_texture_array
 GL_ARB_seamless_cube_map
 GL_EXT_texture_snorm
 GL_ARB_texture_rgb10_a2ui
 GL_ARB_fragment_coord_conventions
 GL_ARB_clear_texture
 GL_ARB_shader_bit_encoding

Core features
 v3.0 (100 % - 23/23)
v3.1 (100 % - 7/7)
v3.2 (100 % - 10/10)
v3.3 (100 % - 10/10)
v4.0 (100 % - 14/14)
v4.1 (100 % - 7/7)
v4.2 (61 % - 8/13)
v4.3 (65 % - 13/20)
v4.4 (30 % - 3/10)
v4.5 (27 % - 3/11)
v4.6 (18 % - 2/11)
vARB 2015 (8 % - 1/12)

...
kannes commented 8 months ago

This is GPU_Caps_Viewer_1.62.0.0.zip mirrored straight from the source: GPU_Caps_Viewer_1.62.0.0.zip

wonder-sk commented 8 months ago

Thanks @kannes for testing!

It makes sense that one needs to have guest extensions installed to be able to use any 3D.

Apologies for the GPU Caps Viewer web site - I always use ad blocker, so I did not notice some bad content there...

Can you please post more details about your setup? I am a bit confused as you mention both VirtualBox and the MESA SVGA3D driver - I thought the SVGA3D driver works with VMWare virtualization, not VirtualBox (https://docs.mesa3d.org/drivers/svga3d.html). Also on that matter, I see you get OpenGL 4.1 even though we ask for OpenGL 4.3 and SVGA3D should support 4.3 as well - at the end of the SVGA3D driver documentation page, there are some hints why you may be getting 4.1 instead of 4.3.

And by the way, what do you mean by "the same z-fighting vertex soup" ? A screencast may be useful :-)

I think it would be good if we checked in QGIS 3D views at the start what OpenGL version we got, and in case of some old one (like 1.1), we would show some more reasonable error message with hints or links to documentation.

kannes commented 8 months ago

Apologies for the GPU Caps Viewer web site - I always use ad blocker, so I did not notice some bad content there...

I only noticed when I used the default browser in my VM, brrrrr what a feeling =)

Can you please post more details about your setup? I am a bit confused as you mention both VirtualBox and the MESA SVGA3D driver - I thought the SVGA3D driver works with VMWare virtualization, not VirtualBox (https://docs.mesa3d.org/drivers/svga3d.html). Also on that matter, I see you get OpenGL 4.1 even though we ask for OpenGL 4.3 and SVGA3D should support 4.3 as well - at the end of the SVGA3D driver documentation page, there are some hints why you may be getting 4.1 instead of 4.3.

That's all! I guess Virtualbox added support for the SVGA3D driver, regardless of its origin at Vmware it seems to be free and open-source in Mesa.

And by the way, what do you mean by "the same z-fighting vertex soup" ? A screencast may be useful :-)

I'll make a new bug report later. It's seems a bit like pieces of geometry flipping their normals or something.

I think it would be good if we checked in QGIS 3D views at the start what OpenGL version we got, and in case of some old one (like 1.1), we would show some more reasonable error message with hints or links to documentation.

That would ace!

wonder-sk commented 8 months ago

That's all! I guess Virtualbox added support for the SVGA3D driver, regardless of its origin at Vmware it seems to be free and open-source in Mesa.

Apparently yes - Virtualbox >= 6.0 ships with SVGA3D driver (https://www.phoronix.com/review/virtualbox-60-vmsvga), and it looks like originally it was just OpenGL 2.1, but probably since then, newer OpenGL versions were made available as well. Good to know!