### Godot version

4.1.1

### System information

Windows 11 - Godot 4.1.1

### Issue description

Using EditorPlugin.make_mesh_previews() crashes Godot. 
The MRP contains a minimal EditorPlugin.

### Steps to reproduce

```
@tool
extends EditorPlugin
 
func _ready():

	var _mesh = preload("res://box.tres")

	var _mesh_arr : Array[Mesh]
	_mesh_arr.append(_mesh)

	var _2d_array : Array[Texture2D] = get_editor_interface().make_mesh_previews(_mesh_arr, 128)

```
### Minimal reproduction project

[MakeMeshPreview.zip](https://github.com/godotengine/godot/files/12269663/MakeMeshPreview.zip)

}
EditorPluginSettings::EditorPluginSettings() {
	ProjectSettings::get_singleton()->add_hidden_prefix("editor_plugins/");
	plugin_config_dialog = memnew(PluginConfigDialog);
	plugin_config_dialog->config("");
	add_child(plugin_config_dialog);
	HBoxContainer *title_hb = memnew(HBoxContainer);
	Label *l = memnew(Label(TTR("Installed Plugins:")));
	l->set_theme_type_variation("HeaderSmall");
	title_hb->add_child(l);
	title_hb->add_spacer();
	Button *create_plugin = memnew(Button(TTR("Create New Plugin")));
	create_plugin->connect("pressed", callable_mp(this, &EditorPluginSettings::_create_clicked));
	title_hb->add_child(create_plugin);
	add_child(title_hb);
	plugin_list = memnew(Tree);
	plugin_list->set_v_size_flags(SIZE_EXPAND_FILL);