1
0
mirror of https://github.com/godotengine/godot.git synced 2026-01-05 19:31:35 +00:00

Add a material preview to visual shader editor

This commit is contained in:
Yuri Rubinsky
2024-07-11 16:20:25 +03:00
committed by Chaosus
parent 1bd740d18d
commit f202a3d24e
6 changed files with 491 additions and 91 deletions

View File

@@ -45,6 +45,7 @@ class MeshInstance3D;
class SubViewport;
class SubViewportContainer;
class Button;
class Label;
class MaterialEditor : public Control {
GDCLASS(MaterialEditor, Control);
@@ -69,6 +70,10 @@ class MaterialEditor : public Control {
Ref<SphereMesh> sphere_mesh;
Ref<BoxMesh> box_mesh;
VBoxContainer *layout_error = nullptr;
Label *error_label = nullptr;
bool is_unsupported_shader_mode = false;
HBoxContainer *layout_3d = nullptr;
Ref<Material> material;