godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
91.23k stars 21.22k forks source link

Vive Focus 3 Android: Default mobile renderer does not start correctly on HMD #76752

Open Psychophylaxis2 opened 1 year ago

Psychophylaxis2 commented 1 year ago

Godot version

4.0.2 stable

System information

Vive Focus 3 Release 5.5

Issue description

The current master godot-xr-tools sets the mobile renderer by default, but only gl_compatibilty starts correctly on the Vive Focus 3. Mobile results in a black start screen, then holding the controller trigger loads the first scene but as a corrupted 2d display.

Steps to reproduce

Import the godot-xr-tools master Leave renderer as mobile Install godot_openxr_loaders Export as Android Khronos with Open XRKHR plugin selected Run on the HMD Corrupted display

Change renderer to gl_compatible and rebuild Display is now correct.

Minimal reproduction project

N/A

BastiaanOlij commented 1 year ago

It would be good to get some logs that may tell us more of what is happening. We are having issues with Vulkan on a number of android devices where there are issues potentially with multiview or other extensions.

One thing that would help is turning verbose on in your project settings and running the project using the remote debug function, this should provide a bunch more extra information in the log window in the Godot IDE.

Psychophylaxis2 commented 1 year ago

Hi. Probably me being thick. How do I export the debug error log text to a file or clipboard? I can right click 1 entry and copy, but I can't find a way to do more than 1. CTRL-A doesn't seem to select them all.

Anyway. Below are snippets I copied 1-by-1.

At the start I get this.

E 0:00:00:0807   interaction_profile_supports_io_path: OpenXR: Unsupported io path /interaction_profiles/htc/vive_focus3_controller/user/hand/left/input/system/click
  <C++ Error>    Parameter "io_path" is null.
  <C++ Source>   modules/openxr/openxr_api.cpp:264 @ interaction_profile_supports_io_path()

E 0:00:00:0807   interaction_profile_supports_io_path: OpenXR: Unsupported io path /interaction_profiles/htc/vive_focus3_controller/user/hand/right/input/trigger/touch
  <C++ Error>    Parameter "io_path" is null.
  <C++ Source>   modules/openxr/openxr_api.cpp:264 @ interaction_profile_supports_io_path()

E 0:00:00:0807   interaction_profile_supports_io_path: OpenXR: Unsupported io path /interaction_profiles/htc/vive_focus3_controller/user/hand/left/input/thumbrest/touch
  <C++ Error>    Parameter "io_path" is null.
  <C++ Source>   modules/openxr/openxr_api.cpp:264 @ interaction_profile_supports_io_path()

E 0:00:00:0996   find_interface: Interface not found.
  <C++ Error>    Condition "idx == -1" is true. Returning: nullptr
  <C++ Source>   servers/xr_server.cpp:227 @ find_interface()

W 0:00:01:0000   _update_swap_chain: The requested V-Sync mode Disabled is not available. Falling back to V-Sync mode Enabled.
  <C++ Source>   drivers/vulkan/vulkan_context.cpp:1899 @ _update_swap_chain()

W 0:00:01:0024   The function 'get_webxr_primary_action()' is a static function but was called from an instance. Instead, it should be directly called from the type: 'Node.get_webxr_primary_action()'.
  <GDScript Error>STATIC_CALLED_ON_INSTANCE
  <GDScript Source>demo_scene_base.gd:19

W 0:00:01:0054   open: res://addons/godot-xr-tools/hands/materials/cleaning_glove.material: In external resource #0, invalid UID: uid://c5cnjs0vgmwpb - using text path instead: res://addons/godot-xr-tools/hands/textures/cleaning_glove_baseColor.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

W 0:00:01:0054   open: res://addons/godot-xr-tools/hands/materials/cleaning_glove.material: In external resource #1, invalid UID: uid://bpr3hcb5m0pkc - using text path instead: res://addons/godot-xr-tools/hands/textures/glove_occlusionRoughnessMetallic.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

W 0:00:01:0054   open: res://addons/godot-xr-tools/hands/materials/cleaning_glove.material: In external resource #2, invalid UID: uid://dnlns2kfjkwhh - using text path instead: res://addons/godot-xr-tools/hands/textures/glove_normal.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

E 0:00:01:0187   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:01:0187   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:01:0187   draw_list_set_push_constant: This render pipeline requires (0) bytes of push constant data, supplied: (128)
  <C++ Error>    Condition "p_data_size != dl->validation.pipeline_push_constant_size" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7307 @ draw_list_set_push_constant()

E 0:00:01:0187   draw_list_draw: No render pipeline was set before attempting to draw.
  <C++ Error>    Condition "!dl->validation.pipeline_active" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7324 @ draw_list_draw()

W 0:00:01:0252   open: res://addons/godot-xr-tools/hands/materials/labglove.material: In external resource #0, invalid UID: uid://bv21ei62pffeb - using text path instead: res://addons/godot-xr-tools/hands/textures/labglove_baseColor.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

W 0:00:01:0252   open: res://addons/godot-xr-tools/hands/materials/labglove.material: In external resource #1, invalid UID: uid://bpr3hcb5m0pkc - using text path instead: res://addons/godot-xr-tools/hands/textures/glove_occlusionRoughnessMetallic.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

W 0:00:01:0252   open: res://addons/godot-xr-tools/hands/materials/labglove.material: In external resource #2, invalid UID: uid://dnlns2kfjkwhh - using text path instead: res://addons/godot-xr-tools/hands/textures/glove_normal.png
  <C++ Source>   core/io/resource_format_binary.cpp:1064 @ open()

E 0:00:01:0364   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:01:0364   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:01:0364   draw_list_set_push_constant: This render pipeline requires (0) bytes of push constant data, supplied: (128)
  <C++ Error>    Condition "p_data_size != dl->validation.pipeline_push_constant_size" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7307 @ draw_list_set_push_constant()

E 0:00:01:0364   draw_list_draw: No render pipeline was set before attempting to draw.
  <C++ Error>    Condition "!dl->validation.pipeline_active" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7324 @ draw_list_draw()

E 0:00:01:0409   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:01:0409   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:01:0409   draw_list_set_push_constant: This render pipeline requires (0) bytes of push constant data, supplied: (128)
  <C++ Error>    Condition "p_data_size != dl->validation.pipeline_push_constant_size" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7307 @ draw_list_set_push_constant()

E 0:00:01:0409   draw_list_draw: No render pipeline was set before attempting to draw.
  <C++ Error>    Condition "!dl->validation.pipeline_active" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7324 @ draw_list_draw()

E 0:00:01:0410   get_width: Viewport Texture must be set to use it.
  <C++ Error>    Condition "!vp" is true. Returning: 0
  <C++ Source>   scene/main/viewport.cpp:111 @ get_width()

E 0:00:01:0410   get_width: Viewport Texture must be set to use it.
  <C++ Error>    Condition "!vp" is true. Returning: 0
  <C++ Source>   scene/main/viewport.cpp:111 @ get_width()

And then the same errors repeat until I hold the trigger to switch to the main menu scene. Then I get this.

E 0:00:10:0798   draw_list_draw: The vertex format used to create the pipeline does not match the vertex format bound.
  <C++ Error>    Condition "dl->validation.pipeline_vertex_format != dl->validation.vertex_format" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7331 @ draw_list_draw()

E 0:00:10:0842   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:10:0842   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:10:0842   draw_list_bind_render_pipeline: Condition "!pipeline" is true.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7124 @ draw_list_bind_render_pipeline()

E 0:00:10:0843   draw_list_draw: Uniforms supplied for set (3):
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
are not the same format as required by the pipeline shader. Pipeline shader requires the following bindings:
Set: 0 Binding: 1 Type: Sampler Writable: N Length: 12
Set: 0 Binding: 2 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 3 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 4 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 5 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 6 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 7 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 8 Type: UniformBuffer Writable: N Length: 3712
Set: 0 Binding: 9 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 10 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 11 Type: Texture Writable: N Length: 1
Set: 0 Binding: 12 Type: Texture Writable: N Length: 1
Set: 0 Binding: 13 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 14 Type: StorageBuffer Writable: N Length: 0
Set: 1 Binding: 0 Type: UniformBuffer Writable: N Length: 5632
Set: 1 Binding: 2 Type: Texture Writable: N Length: 1
Set: 1 Binding: 3 Type: Texture Writable: N Length: 1
Set: 1 Binding: 4 Type: Texture Writable: N Length: 1
Set: 1 Binding: 5 Type: Texture Writable: N Length: 1
Set: 1 Binding: 6 Type: Texture Writable: N Length: 2
Set: 1 Binding: 9 Type: Texture Writable: N Length: 1
Set: 1 Binding: 10 Type: Texture Writable: N Length: 1
Set: 2 Binding: 0 Type: StorageBuffer Writable: N Length: 0
Set: 3 Binding: 0 Type: UniformBuffer Writable: N Length: 128
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
Set: 3 Binding: 2 Type: Texture Writable: N Length: 1
Set: 3 Binding: 3 Type: Texture Writable: N Length: 1
  <C++ Error>    Method/function failed.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7357 @ draw_list_draw()

E 0:00:10:0875   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:10:0875   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:10:0875   draw_list_draw: Uniforms supplied for set (3):
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
are not the same format as required by the pipeline shader. Pipeline shader requires the following bindings:
Set: 0 Binding: 1 Type: Sampler Writable: N Length: 12
Set: 0 Binding: 2 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 3 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 4 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 5 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 6 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 7 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 8 Type: UniformBuffer Writable: N Length: 3712
Set: 0 Binding: 9 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 10 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 11 Type: Texture Writable: N Length: 1
Set: 0 Binding: 12 Type: Texture Writable: N Length: 1
Set: 0 Binding: 13 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 14 Type: StorageBuffer Writable: N Length: 0
Set: 1 Binding: 0 Type: UniformBuffer Writable: N Length: 5632
Set: 1 Binding: 2 Type: Texture Writable: N Length: 1
Set: 1 Binding: 3 Type: Texture Writable: N Length: 1
Set: 1 Binding: 4 Type: Texture Writable: N Length: 1
Set: 1 Binding: 5 Type: Texture Writable: N Length: 1
Set: 1 Binding: 6 Type: Texture Writable: N Length: 2
Set: 1 Binding: 9 Type: Texture Writable: N Length: 1
Set: 1 Binding: 10 Type: Texture Writable: N Length: 1
Set: 2 Binding: 0 Type: StorageBuffer Writable: N Length: 0
Set: 3 Binding: 0 Type: UniformBuffer Writable: N Length: 128
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
Set: 3 Binding: 2 Type: Texture Writable: N Length: 1
Set: 3 Binding: 3 Type: Texture Writable: N Length: 1
  <C++ Error>    Method/function failed.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7357 @ draw_list_draw()

E 0:00:10:0907   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

E 0:00:10:0907   _generate_version: Condition "pipeline.is_null()" is true. Returning: RID()
  <C++ Source>   servers/rendering/renderer_rd/pipeline_cache_rd.cpp:61 @ _generate_version()

E 0:00:10:0908   draw_list_draw: Uniforms supplied for set (3):
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
are not the same format as required by the pipeline shader. Pipeline shader requires the following bindings:
Set: 0 Binding: 1 Type: Sampler Writable: N Length: 12
Set: 0 Binding: 2 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 3 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 4 Type: Sampler Writable: N Length: 1
Set: 0 Binding: 5 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 6 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 7 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 8 Type: UniformBuffer Writable: N Length: 3712
Set: 0 Binding: 9 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 10 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 11 Type: Texture Writable: N Length: 1
Set: 0 Binding: 12 Type: Texture Writable: N Length: 1
Set: 0 Binding: 13 Type: StorageBuffer Writable: N Length: 0
Set: 0 Binding: 14 Type: StorageBuffer Writable: N Length: 0
Set: 1 Binding: 0 Type: UniformBuffer Writable: N Length: 5632
Set: 1 Binding: 2 Type: Texture Writable: N Length: 1
Set: 1 Binding: 3 Type: Texture Writable: N Length: 1
Set: 1 Binding: 4 Type: Texture Writable: N Length: 1
Set: 1 Binding: 5 Type: Texture Writable: N Length: 1
Set: 1 Binding: 6 Type: Texture Writable: N Length: 2
Set: 1 Binding: 9 Type: Texture Writable: N Length: 1
Set: 1 Binding: 10 Type: Texture Writable: N Length: 1
Set: 2 Binding: 0 Type: StorageBuffer Writable: N Length: 0
Set: 3 Binding: 0 Type: UniformBuffer Writable: N Length: 128
Set: 3 Binding: 1 Type: Texture Writable: N Length: 1
Set: 3 Binding: 2 Type: Texture Writable: N Length: 1
Set: 3 Binding: 3 Type: Texture Writable: N Length: 1
  <C++ Error>    Method/function failed.
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:7357 @ draw_list_draw()

E 0:00:10:0941   render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'.
  <C++ Error>    Condition "err" is true. Returning: RID()
  <C++ Source>   drivers/vulkan/rendering_device_vulkan.cpp:6402 @ render_pipeline_create()

Which also then repeats until I stop the app.

chk1226 commented 1 year ago

HI,

render_pipeline_create: vkCreateGraphicsPipelines failed with error -13 for shader 'SceneForwardMobileShaderRD:5'. This error didn't occur in Godot 4.1.2.

In Godot 4.1.2 Vulkan, it can run correctly on the Focus 3, but there is a render issue. This is root caused by the MSAA feature of the swapchain image. VIVE have already fixed it, and the problem will be resolved in the next HTC WAVE ROM update.