diff options
author | ShirenY <yinxiaozhou@gmail.com> | 2023-11-04 22:09:33 +0800 |
---|---|---|
committer | ShirenY <yinxiaozhou@gmail.com> | 2023-12-09 11:41:15 +0800 |
commit | 27f71c4e78db2f502d730f5e34a540665c45af27 (patch) | |
tree | bf182788174ded88ca911e76266ca3a8a7d7b765 /servers/rendering_server.cpp | |
parent | 3e7f638d7b574785f521beafaf52a6ad95be016f (diff) | |
download | redot-engine-27f71c4e78db2f502d730f5e34a540665c45af27.tar.gz |
Transform mesh's AABB to skeleton's space when calculate mesh's bounds.
Diffstat (limited to 'servers/rendering_server.cpp')
-rw-r--r-- | servers/rendering_server.cpp | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/servers/rendering_server.cpp b/servers/rendering_server.cpp index 620262f30e..208a17b493 100644 --- a/servers/rendering_server.cpp +++ b/servers/rendering_server.cpp @@ -1777,6 +1777,14 @@ Array RenderingServer::_mesh_surface_get_skeleton_aabb_bind(RID p_mesh, int p_su } #endif +Rect2 RenderingServer::debug_canvas_item_get_rect(RID p_item) { +#ifdef TOOLS_ENABLED + return _debug_canvas_item_get_rect(p_item); +#else + return Rect2(); +#endif +} + int RenderingServer::global_shader_uniform_type_get_shader_datatype(GlobalShaderParameterType p_type) { switch (p_type) { case RS::GLOBAL_VAR_TYPE_BOOL: @@ -3161,6 +3169,8 @@ void RenderingServer::_bind_methods() { ClassDB::bind_method(D_METHOD("canvas_item_set_visibility_notifier", "item", "enable", "area", "enter_callable", "exit_callable"), &RenderingServer::canvas_item_set_visibility_notifier); ClassDB::bind_method(D_METHOD("canvas_item_set_canvas_group_mode", "item", "mode", "clear_margin", "fit_empty", "fit_margin", "blur_mipmaps"), &RenderingServer::canvas_item_set_canvas_group_mode, DEFVAL(5.0), DEFVAL(false), DEFVAL(0.0), DEFVAL(false)); + ClassDB::bind_method(D_METHOD("debug_canvas_item_get_rect", "item"), &RenderingServer::debug_canvas_item_get_rect); + BIND_ENUM_CONSTANT(NINE_PATCH_STRETCH); BIND_ENUM_CONSTANT(NINE_PATCH_TILE); BIND_ENUM_CONSTANT(NINE_PATCH_TILE_FIT); |