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

Adding a NoiseTexture3D within a VisualShader crashes Godot #79360

Closed
billyp673 opened this issue Jul 12, 2023 · 3 comments · Fixed by #80407
Closed

Adding a NoiseTexture3D within a VisualShader crashes Godot #79360

billyp673 opened this issue Jul 12, 2023 · 3 comments · Fixed by #80407

Comments

@billyp673
Copy link

Godot version

v4.1.stable.official [9704596]

System information

Godot v4.1.stable - Windows 10.0.22621 (this is what "copy system info" says, but I'm running Windows 11 Home) - Vulkan (Compatibility) - NVIDIA GeForce RTX 4090 (NVIDIA; 31.0.15.3168) - 12th Gen Intel(R) Core(TM) i7-12700F (20 Threads)

Issue description

Adding a NoiseTexture3D to a Visual Shader crashes Godot.

Steps to reproduce

  • In a new project, create a "MeshInstance3D"
  • Set the mesh to any mesh that has the "Surface Material Overide" property (New BoxMesh for instance)
  • In said property, create a "New ShaderMaterial"
  • Set the ShaderMaterial's shader to a new shader, with the type: "VisualShader"
  • Edit the VisualShader
  • Add a Texture3D node
  • Set the texture to "New NoiseTexture3D"

Godot then crashes (note, the crash takes place even if you remove the "MeshInstance3D")

Minimal reproduction project

N/A

@viksl
Copy link
Contributor

viksl commented Jul 12, 2023

It works in the Forward renderer, I can confirm the crash in the Compatibility renderer (which OP uses) in windows 10 4.1 stable, I get this in the console:
I'm not really sure how far Compatibility renderer is honestly. I thought it was still a work in progress but never tried it much. :)

Godot Engine v4.1.stable.mono.official.970459615 - https://godotengine.org
Requested V-Sync mode: Enabled - FPS will likely be capped to the monitor refresh rate.
OpenGL API 3.3.0 NVIDIA 531.79 - Compatibility - Using Device: NVIDIA - NVIDIA GeForce GTX 1660 Ti

ERROR: Condition "!texture_allocs_cache.has(p_id)" is true.
   at: texture_free_data (drivers/gles3/storage/utilities.h:111)
ERROR: Cubemap Arrays are not supported in the GL Compatibility backend.
   at: (drivers/gles3/storage/texture_storage.cpp:763)
ERROR: Attempting to use an uninitialized RID
   at: (./core/templates/rid_owner.h:199)
ERROR: Condition "!t" is true.
   at: texture_free (drivers/gles3/storage/texture_storage.cpp:705)
WARNING: Glow is not supported when using the GL Compatibility backend yet. Support will be added in a future release.
     at: environment_set_glow (servers/rendering/storage/environment_storage.cpp:387)
ERROR: FATAL: Index p_index = 0 is out of bounds (size() = 0).
   at: get (./core/templates/cowdata.h:155)

@douze
Copy link

douze commented Jul 22, 2023

Reproduced on Godot v4.1.1.stable - Ubuntu 22.04.2 LTS 22.04 - Vulkan (Compatibility) - Mesa Intel(R) HD Graphics 520 (SKL GT2) () - Intel(R) Core(TM) i5-6200U CPU @ 2.30GHz (4 Threads)

You don't even need nodes/shaders : it also happens when you try to create a new NoiseTexture3D resource from the inspector

@YuriSizov
Copy link
Contributor

This should be fixed by #80407.

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