summaryrefslogtreecommitdiff
path: root/scene/main/viewport.h
diff options
context:
space:
mode:
Diffstat (limited to 'scene/main/viewport.h')
-rw-r--r--scene/main/viewport.h30
1 files changed, 27 insertions, 3 deletions
diff --git a/scene/main/viewport.h b/scene/main/viewport.h
index e619199424..bd9747d878 100644
--- a/scene/main/viewport.h
+++ b/scene/main/viewport.h
@@ -122,6 +122,24 @@ public:
USAGE_3D_NO_EFFECTS,
};
+ enum RenderInfo {
+
+ RENDER_INFO_OBJECTS_IN_FRAME,
+ RENDER_INFO_VERTICES_IN_FRAME,
+ RENDER_INFO_MATERIAL_CHANGES_IN_FRAME,
+ RENDER_INFO_SHADER_CHANGES_IN_FRAME,
+ RENDER_INFO_SURFACE_CHANGES_IN_FRAME,
+ RENDER_INFO_DRAW_CALLS_IN_FRAME,
+ RENDER_INFO_MAX
+ };
+
+ enum DebugDraw {
+ DEBUG_DRAW_DISABLED,
+ DEBUG_DRAW_UNSHADED,
+ DEBUG_DRAW_OVERDRAW,
+ DEBUG_DRAW_WIREFRAME,
+ };
+
private:
friend class ViewportTexture;
@@ -204,6 +222,8 @@ private:
RID texture_rid;
uint32_t texture_flags;
+ DebugDraw debug_draw;
+
Usage usage;
int shadow_atlas_size;
@@ -393,9 +413,6 @@ public:
Vector2 get_camera_coords(const Vector2 &p_viewport_coords) const;
Vector2 get_camera_rect_size() const;
- void queue_screen_capture();
- Ref<Image> get_screen_capture() const;
-
void set_use_own_world(bool p_world);
bool is_using_own_world() const;
@@ -430,6 +447,11 @@ public:
void set_usage(Usage p_usage);
Usage get_usage() const;
+ void set_debug_draw(DebugDraw p_debug_draw);
+ DebugDraw get_debug_draw() const;
+
+ int get_render_info(RenderInfo p_info);
+
Viewport();
~Viewport();
};
@@ -438,5 +460,7 @@ VARIANT_ENUM_CAST(Viewport::UpdateMode);
VARIANT_ENUM_CAST(Viewport::ShadowAtlasQuadrantSubdiv);
VARIANT_ENUM_CAST(Viewport::MSAA);
VARIANT_ENUM_CAST(Viewport::Usage);
+VARIANT_ENUM_CAST(Viewport::DebugDraw);
+VARIANT_ENUM_CAST(Viewport::RenderInfo);
#endif