summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.github/CODEOWNERS1
-rw-r--r--drivers/gles3/rasterizer_scene_gles3.cpp2
-rw-r--r--editor/connections_dialog.cpp7
-rw-r--r--editor/connections_dialog.h3
-rw-r--r--scene/main/canvas_item.cpp4
-rw-r--r--scene/main/viewport.cpp4
6 files changed, 9 insertions, 12 deletions
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index 7ac048b24a..7dfc3bccc3 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -37,6 +37,7 @@ doc_classes/* @godotengine/documentation
## Rendering
/drivers/dummy/ @godotengine/rendering
+/drivers/gles3/ @godotengine/rendering
/drivers/spirv-reflect/ @godotengine/rendering
/drivers/vulkan/ @godotengine/rendering
diff --git a/drivers/gles3/rasterizer_scene_gles3.cpp b/drivers/gles3/rasterizer_scene_gles3.cpp
index 6e9d4e5963..c9492adb20 100644
--- a/drivers/gles3/rasterizer_scene_gles3.cpp
+++ b/drivers/gles3/rasterizer_scene_gles3.cpp
@@ -595,6 +595,7 @@ void RasterizerSceneGLES3::_setup_sky(const RenderDataGLES3 *p_render_data, cons
sky->reflection_dirty = true;
}
+ glBindBufferBase(GL_UNIFORM_BUFFER, SKY_DIRECTIONAL_LIGHT_UNIFORM_LOCATION, sky_globals.directional_light_buffer);
if (shader_data->uses_light) {
sky_globals.directional_light_count = 0;
for (int i = 0; i < (int)p_lights.size(); i++) {
@@ -678,7 +679,6 @@ void RasterizerSceneGLES3::_setup_sky(const RenderDataGLES3 *p_render_data, cons
}
if (light_data_dirty) {
- glBindBufferBase(GL_UNIFORM_BUFFER, SKY_DIRECTIONAL_LIGHT_UNIFORM_LOCATION, sky_globals.directional_light_buffer);
glBufferData(GL_UNIFORM_BUFFER, sizeof(DirectionalLightData) * sky_globals.max_directional_lights, sky_globals.directional_lights, GL_STREAM_DRAW);
glBindBuffer(GL_UNIFORM_BUFFER, 0);
diff --git a/editor/connections_dialog.cpp b/editor/connections_dialog.cpp
index de7f5c8b88..ed2044c117 100644
--- a/editor/connections_dialog.cpp
+++ b/editor/connections_dialog.cpp
@@ -684,6 +684,7 @@ void ConnectionsDock::_connect(ConnectDialog::ConnectionData p_cd) {
}
Callable callable = p_cd.get_callable();
+ Ref<EditorUndoRedoManager> &undo_redo = EditorNode::get_undo_redo();
undo_redo->create_action(vformat(TTR("Connect '%s' to '%s'"), String(p_cd.signal), String(p_cd.method)));
undo_redo->add_do_method(source, "connect", p_cd.signal, callable, p_cd.flags);
undo_redo->add_undo_method(source, "disconnect", p_cd.signal, callable);
@@ -704,6 +705,7 @@ void ConnectionsDock::_disconnect(TreeItem &p_item) {
ERR_FAIL_COND(cd.source != selected_node); // Shouldn't happen but... Bugcheck.
+ Ref<EditorUndoRedoManager> &undo_redo = EditorNode::get_undo_redo();
undo_redo->create_action(vformat(TTR("Disconnect '%s' from '%s'"), cd.signal, cd.method));
Callable callable = cd.get_callable();
@@ -730,6 +732,7 @@ void ConnectionsDock::_disconnect_all() {
TreeItem *child = item->get_first_child();
String signal_name = item->get_metadata(0).operator Dictionary()["name"];
+ Ref<EditorUndoRedoManager> &undo_redo = EditorNode::get_undo_redo();
undo_redo->create_action(vformat(TTR("Disconnect all from signal: '%s'"), signal_name));
while (child) {
@@ -991,10 +994,6 @@ void ConnectionsDock::_bind_methods() {
ClassDB::bind_method("update_tree", &ConnectionsDock::update_tree);
}
-void ConnectionsDock::set_undo_redo(Ref<EditorUndoRedoManager> p_undo_redo) {
- undo_redo = p_undo_redo;
-}
-
void ConnectionsDock::set_node(Node *p_node) {
selected_node = p_node;
update_tree();
diff --git a/editor/connections_dialog.h b/editor/connections_dialog.h
index 126a0ca828..fcfc501386 100644
--- a/editor/connections_dialog.h
+++ b/editor/connections_dialog.h
@@ -47,7 +47,6 @@
#include "scene/gui/tree.h"
class ConnectDialogBinds;
-class EditorUndoRedoManager;
class ConnectDialog : public ConfirmationDialog {
GDCLASS(ConnectDialog, ConfirmationDialog);
@@ -197,7 +196,6 @@ class ConnectionsDock : public VBoxContainer {
Button *connect_button = nullptr;
PopupMenu *signal_menu = nullptr;
PopupMenu *slot_menu = nullptr;
- Ref<EditorUndoRedoManager> undo_redo;
LineEdit *search_box = nullptr;
HashMap<StringName, HashMap<StringName, String>> descr_cache;
@@ -231,7 +229,6 @@ protected:
static void _bind_methods();
public:
- void set_undo_redo(Ref<EditorUndoRedoManager> p_undo_redo);
void set_node(Node *p_node);
void update_tree();
diff --git a/scene/main/canvas_item.cpp b/scene/main/canvas_item.cpp
index 3bf4e95e68..7bcd4721fc 100644
--- a/scene/main/canvas_item.cpp
+++ b/scene/main/canvas_item.cpp
@@ -1112,7 +1112,7 @@ uint32_t CanvasItem::get_visibility_layer() const {
}
void CanvasItem::set_visibility_layer_bit(uint32_t p_visibility_layer, bool p_enable) {
- ERR_FAIL_INDEX(p_visibility_layer, 32);
+ ERR_FAIL_UNSIGNED_INDEX(p_visibility_layer, 32);
if (p_enable) {
set_visibility_layer(visibility_layer | (1 << p_visibility_layer));
} else {
@@ -1121,7 +1121,7 @@ void CanvasItem::set_visibility_layer_bit(uint32_t p_visibility_layer, bool p_en
}
bool CanvasItem::get_visibility_layer_bit(uint32_t p_visibility_layer) const {
- ERR_FAIL_INDEX_V(p_visibility_layer, 32, false);
+ ERR_FAIL_UNSIGNED_INDEX_V(p_visibility_layer, 32, false);
return (visibility_layer & (1 << p_visibility_layer));
}
diff --git a/scene/main/viewport.cpp b/scene/main/viewport.cpp
index 2385e4f54a..f8b0a66a71 100644
--- a/scene/main/viewport.cpp
+++ b/scene/main/viewport.cpp
@@ -3255,7 +3255,7 @@ uint32_t Viewport::get_canvas_cull_mask() const {
}
void Viewport::set_canvas_cull_mask_bit(uint32_t p_layer, bool p_enable) {
- ERR_FAIL_INDEX(p_layer, 32);
+ ERR_FAIL_UNSIGNED_INDEX(p_layer, 32);
if (p_enable) {
set_canvas_cull_mask(canvas_cull_mask | (1 << p_layer));
} else {
@@ -3264,7 +3264,7 @@ void Viewport::set_canvas_cull_mask_bit(uint32_t p_layer, bool p_enable) {
}
bool Viewport::get_canvas_cull_mask_bit(uint32_t p_layer) const {
- ERR_FAIL_INDEX_V(p_layer, 32, false);
+ ERR_FAIL_UNSIGNED_INDEX_V(p_layer, 32, false);
return (canvas_cull_mask & (1 << p_layer));
}