summaryrefslogtreecommitdiff
path: root/servers/visual/visual_server_scene.h
diff options
context:
space:
mode:
Diffstat (limited to 'servers/visual/visual_server_scene.h')
-rw-r--r--servers/visual/visual_server_scene.h12
1 files changed, 7 insertions, 5 deletions
diff --git a/servers/visual/visual_server_scene.h b/servers/visual/visual_server_scene.h
index 38c5258116..2c2ba7e15f 100644
--- a/servers/visual/visual_server_scene.h
+++ b/servers/visual/visual_server_scene.h
@@ -5,8 +5,8 @@
/* GODOT ENGINE */
/* https://godotengine.org */
/*************************************************************************/
-/* Copyright (c) 2007-2018 Juan Linietsky, Ariel Manzur. */
-/* Copyright (c) 2014-2018 Godot Engine contributors (cf. AUTHORS.md) */
+/* Copyright (c) 2007-2019 Juan Linietsky, Ariel Manzur. */
+/* Copyright (c) 2014-2019 Godot Engine contributors (cf. AUTHORS.md) */
/* */
/* Permission is hereby granted, free of charge, to any person obtaining */
/* a copy of this software and associated documentation files (the */
@@ -33,7 +33,6 @@
#include "servers/visual/rasterizer.h"
-#include "core/allocators.h"
#include "core/math/geometry.h"
#include "core/math/octree.h"
#include "core/os/semaphore.h"
@@ -78,12 +77,14 @@ public:
enum Type {
PERSPECTIVE,
- ORTHOGONAL
+ ORTHOGONAL,
+ FRUSTUM
};
Type type;
float fov;
float znear, zfar;
float size;
+ Vector2 offset;
uint32_t visible_layers;
bool vaspect;
RID env;
@@ -98,6 +99,7 @@ public:
znear = 0.05;
zfar = 100;
size = 1.0;
+ offset = Vector2();
vaspect = false;
}
};
@@ -107,6 +109,7 @@ public:
virtual RID camera_create();
virtual void camera_set_perspective(RID p_camera, float p_fovy_degrees, float p_z_near, float p_z_far);
virtual void camera_set_orthogonal(RID p_camera, float p_size, float p_z_near, float p_z_far);
+ virtual void camera_set_frustum(RID p_camera, float p_size, Vector2 p_offset, float p_z_near, float p_z_far);
virtual void camera_set_transform(RID p_camera, const Transform &p_transform);
virtual void camera_set_cull_mask(RID p_camera, uint32_t p_layers);
virtual void camera_set_environment(RID p_camera, RID p_env);
@@ -120,7 +123,6 @@ public:
VS::ScenarioDebugMode debug;
RID self;
- // well wtf, balloon allocator is slower?
Octree<Instance, true> octree;