feat: updated engine version to 4.4-rc1
This commit is contained in:
parent
ee00efde1f
commit
21ba8e33af
5459 changed files with 1128836 additions and 198305 deletions
|
|
@ -31,6 +31,7 @@
|
|||
#include "shader_globals_editor.h"
|
||||
|
||||
#include "core/config/project_settings.h"
|
||||
#include "editor/editor_inspector.h"
|
||||
#include "editor/editor_node.h"
|
||||
#include "editor/editor_undo_redo_manager.h"
|
||||
#include "servers/rendering/shader_language.h"
|
||||
|
|
@ -64,6 +65,7 @@ static const char *global_var_type_names[RS::GLOBAL_VAR_TYPE_MAX] = {
|
|||
"sampler2DArray",
|
||||
"sampler3D",
|
||||
"samplerCube",
|
||||
"samplerExternalOES",
|
||||
};
|
||||
|
||||
class ShaderGlobalsEditorInterface : public Object {
|
||||
|
|
@ -231,6 +233,11 @@ protected:
|
|||
pinfo.hint = PROPERTY_HINT_RESOURCE_TYPE;
|
||||
pinfo.hint_string = "Cubemap,CompressedCubemap";
|
||||
} break;
|
||||
case RS::GLOBAL_VAR_TYPE_SAMPLEREXT: {
|
||||
pinfo.type = Variant::OBJECT;
|
||||
pinfo.hint = PROPERTY_HINT_RESOURCE_TYPE;
|
||||
pinfo.hint_string = "ExternalTexture";
|
||||
} break;
|
||||
default: {
|
||||
} break;
|
||||
}
|
||||
|
|
@ -338,6 +345,9 @@ static Variant create_var(RS::GlobalShaderParameterType p_type) {
|
|||
case RS::GLOBAL_VAR_TYPE_SAMPLERCUBE: {
|
||||
return "";
|
||||
}
|
||||
case RS::GLOBAL_VAR_TYPE_SAMPLEREXT: {
|
||||
return "";
|
||||
}
|
||||
default: {
|
||||
return Variant();
|
||||
}
|
||||
|
|
@ -349,7 +359,7 @@ String ShaderGlobalsEditor::_check_new_variable_name(const String &p_variable_na
|
|||
return TTR("Name cannot be empty.");
|
||||
}
|
||||
|
||||
if (!p_variable_name.is_valid_identifier()) {
|
||||
if (!p_variable_name.is_valid_ascii_identifier()) {
|
||||
return TTR("Name must be a valid identifier.");
|
||||
}
|
||||
|
||||
|
|
@ -437,7 +447,7 @@ void ShaderGlobalsEditor::_notification(int p_what) {
|
|||
} break;
|
||||
|
||||
case NOTIFICATION_THEME_CHANGED: {
|
||||
variable_add->set_icon(get_editor_theme_icon(SNAME("Add")));
|
||||
variable_add->set_button_icon(get_editor_theme_icon(SNAME("Add")));
|
||||
} break;
|
||||
|
||||
case NOTIFICATION_PREDELETE: {
|
||||
|
|
@ -457,7 +467,7 @@ ShaderGlobalsEditor::ShaderGlobalsEditor() {
|
|||
variable_name->set_h_size_flags(SIZE_EXPAND_FILL);
|
||||
variable_name->set_clear_button_enabled(true);
|
||||
variable_name->connect(SceneStringName(text_changed), callable_mp(this, &ShaderGlobalsEditor::_variable_name_text_changed));
|
||||
variable_name->connect("text_submitted", callable_mp(this, &ShaderGlobalsEditor::_variable_added).unbind(1));
|
||||
variable_name->connect(SceneStringName(text_submitted), callable_mp(this, &ShaderGlobalsEditor::_variable_added).unbind(1));
|
||||
|
||||
add_menu_hb->add_child(variable_name);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue