| 1 |
|
| 2 |
|
| 3 |
|
| 4 |
|
| 5 |
|
| 6 |
|
| 7 |
|
| 8 |
|
| 9 |
|
| 10 |
|
| 11 |
|
| 12 |
|
| 13 |
|
| 14 |
|
| 15 |
|
| 16 |
|
| 17 |
|
| 18 |
|
| 19 |
|
| 20 |
|
| 21 |
|
| 22 |
|
| 23 |
|
| 24 |
|
| 25 |
|
| 26 |
|
| 27 |
|
| 28 |
|
| 29 |
|
| 30 |
|
| 31 |
#pragma once |
| 32 |
|
| 33 |
#include "scene/3d/camera_3d.h" |
| 34 |
#include "scene/main/viewport.h" |
| 35 |
#include "scene/main/window.h" |
| 36 |
|
| 37 |
#include "tests/test_macros.h" |
| 38 |
|
| 39 |
TEST_CASE("[SceneTree][Camera3D] Getters and setters") { |
| 40 |
Camera3D *test_camera = memnew(Camera3D); |
| 41 |
|
| 42 |
SUBCASE("Cull mask") { |
| 43 |
constexpr int cull_mask = (1 << 5) | (1 << 7) | (1 << 9); |
| 44 |
constexpr int set_enable_layer = 3; |
| 45 |
constexpr int set_disable_layer = 5; |
| 46 |
test_camera->set_cull_mask(cull_mask); |
| 47 |
CHECK(test_camera->get_cull_mask() == cull_mask); |
| 48 |
test_camera->set_cull_mask_value(set_enable_layer, true); |
| 49 |
CHECK(test_camera->get_cull_mask_value(set_enable_layer)); |
| 50 |
test_camera->set_cull_mask_value(set_disable_layer, false); |
| 51 |
CHECK_FALSE(test_camera->get_cull_mask_value(set_disable_layer)); |
| 52 |
} |
| 53 |
|
| 54 |
SUBCASE("Attributes") { |
| 55 |
Ref<CameraAttributes> attributes = memnew(CameraAttributes); |
| 56 |
test_camera->set_attributes(attributes); |
| 57 |
CHECK(test_camera->get_attributes() == attributes); |
| 58 |
Ref<CameraAttributesPhysical> physical_attributes = memnew(CameraAttributesPhysical); |
| 59 |
test_camera->set_attributes(physical_attributes); |
| 60 |
CHECK(test_camera->get_attributes() == physical_attributes); |
| 61 |
} |
| 62 |
|
| 63 |
SUBCASE("Camera frustum properties") { |
| 64 |
constexpr float depth_near = 0.2f; |
| 65 |
constexpr float depth_far = 995.0f; |
| 66 |
constexpr float fov = 120.0f; |
| 67 |
constexpr float size = 7.0f; |
| 68 |
constexpr float h_offset = 1.1f; |
| 69 |
constexpr float v_offset = -1.6f; |
| 70 |
const Vector2 frustum_offset(5, 7); |
| 71 |
test_camera->set_near(depth_near); |
| 72 |
CHECK(test_camera->get_near() == depth_near); |
| 73 |
test_camera->set_far(depth_far); |
| 74 |
CHECK(test_camera->get_far() == depth_far); |
| 75 |
test_camera->set_fov(fov); |
| 76 |
CHECK(test_camera->get_fov() == fov); |
| 77 |
test_camera->set_size(size); |
| 78 |
CHECK(test_camera->get_size() == size); |
| 79 |
test_camera->set_h_offset(h_offset); |
| 80 |
CHECK(test_camera->get_h_offset() == h_offset); |
| 81 |
test_camera->set_v_offset(v_offset); |
| 82 |
CHECK(test_camera->get_v_offset() == v_offset); |
| 83 |
test_camera->set_frustum_offset(frustum_offset); |
| 84 |
CHECK(test_camera->get_frustum_offset() == frustum_offset); |
| 85 |
test_camera->set_keep_aspect_mode(Camera3D::KeepAspect::KEEP_HEIGHT); |
| 86 |
CHECK(test_camera->get_keep_aspect_mode() == Camera3D::KeepAspect::KEEP_HEIGHT); |
| 87 |
test_camera->set_keep_aspect_mode(Camera3D::KeepAspect::KEEP_WIDTH); |
| 88 |
CHECK(test_camera->get_keep_aspect_mode() == Camera3D::KeepAspect::KEEP_WIDTH); |
| 89 |
} |
| 90 |
|
| 91 |
SUBCASE("Projection mode") { |
| 92 |
test_camera->set_projection(Camera3D::ProjectionType::PROJECTION_ORTHOGONAL); |
| 93 |
CHECK(test_camera->get_projection() == Camera3D::ProjectionType::PROJECTION_ORTHOGONAL); |
| 94 |
test_camera->set_projection(Camera3D::ProjectionType::PROJECTION_PERSPECTIVE); |
| 95 |
CHECK(test_camera->get_projection() == Camera3D::ProjectionType::PROJECTION_PERSPECTIVE); |
| 96 |
} |
| 97 |
|
| 98 |
SUBCASE("Helper setters") { |
| 99 |
constexpr float fov = 90.0f, size = 6.0f; |
| 100 |
constexpr float near1 = 0.1f, near2 = 0.5f; |
| 101 |
constexpr float far1 = 1001.0f, far2 = 1005.0f; |
| 102 |
test_camera->set_perspective(fov, near1, far1); |
| 103 |
CHECK(test_camera->get_projection() == Camera3D::ProjectionType::PROJECTION_PERSPECTIVE); |
| 104 |
CHECK(test_camera->get_near() == near1); |
| 105 |
CHECK(test_camera->get_far() == far1); |
| 106 |
CHECK(test_camera->get_fov() == fov); |
| 107 |
test_camera->set_orthogonal(size, near2, far2); |
| 108 |
CHECK(test_camera->get_projection() == Camera3D::ProjectionType::PROJECTION_ORTHOGONAL); |
| 109 |
CHECK(test_camera->get_near() == near2); |
| 110 |
CHECK(test_camera->get_far() == far2); |
| 111 |
CHECK(test_camera->get_size() == size); |
| 112 |
} |
| 113 |
|
| 114 |
SUBCASE("Doppler tracking") { |
| 115 |
test_camera->set_doppler_tracking(Camera3D::DopplerTracking::DOPPLER_TRACKING_IDLE_STEP); |
| 116 |
CHECK(test_camera->get_doppler_tracking() == Camera3D::DopplerTracking::DOPPLER_TRACKING_IDLE_STEP); |
| 117 |
test_camera->set_doppler_tracking(Camera3D::DopplerTracking::DOPPLER_TRACKING_PHYSICS_STEP); |
| 118 |
CHECK(test_camera->get_doppler_tracking() == Camera3D::DopplerTracking::DOPPLER_TRACKING_PHYSICS_STEP); |
| 119 |
test_camera->set_doppler_tracking(Camera3D::DopplerTracking::DOPPLER_TRACKING_DISABLED); |
| 120 |
CHECK(test_camera->get_doppler_tracking() == Camera3D::DopplerTracking::DOPPLER_TRACKING_DISABLED); |
| 121 |
} |
| 122 |
|
| 123 |
memdelete(test_camera); |
| 124 |
} |
| 125 |
|
| 126 |
TEST_CASE("[SceneTree][Camera3D] Position queries") { |
| 127 |
|
| 128 |
Camera3D *test_camera = memnew(Camera3D); |
| 129 |
SubViewport *mock_viewport = memnew(SubViewport); |
| 130 |
|
| 131 |
mock_viewport->set_size(Vector2(400, 200)); |
| 132 |
SceneTree::get_singleton()->get_root()->add_child(mock_viewport); |
| 133 |
mock_viewport->add_child(test_camera); |
| 134 |
test_camera->set_keep_aspect_mode(Camera3D::KeepAspect::KEEP_WIDTH); |
| 135 |
REQUIRE_MESSAGE(test_camera->is_current(), "Camera3D should be made current upon entering tree."); |
| 136 |
|
| 137 |
SUBCASE("Orthogonal projection") { |
| 138 |
test_camera->set_projection(Camera3D::ProjectionType::PROJECTION_ORTHOGONAL); |
| 139 |
|
| 140 |
|
| 141 |
test_camera->set_global_position(Vector3(1, 2, 3)); |
| 142 |
test_camera->look_at(Vector3(-4, 5, 1)); |
| 143 |
|
| 144 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 145 |
const Basis basis = test_camera->get_global_basis(); |
| 146 |
|
| 147 |
const Vector3 offset1 = basis.xform(Vector3(-1.5f, 3.5f, 0.2f - test_camera->get_near())); |
| 148 |
const Vector3 offset2 = basis.xform(Vector3(2.0f, -0.5f, -0.6f - test_camera->get_near())); |
| 149 |
const Vector3 offset3 = basis.xform(Vector3(-3.0f, 1.0f, -0.6f - test_camera->get_near())); |
| 150 |
const Vector3 offset4 = basis.xform(Vector3(-2.0f, 1.5f, -0.6f - test_camera->get_near())); |
| 151 |
const Vector3 offset5 = basis.xform(Vector3(0, 0, 10000.0f - test_camera->get_near())); |
| 152 |
|
| 153 |
SUBCASE("is_position_behind") { |
| 154 |
CHECK(test_camera->is_position_behind(test_camera->get_global_position() + offset1)); |
| 155 |
CHECK_FALSE(test_camera->is_position_behind(test_camera->get_global_position() + offset2)); |
| 156 |
|
| 157 |
SUBCASE("h/v offset should have no effect on the result of is_position_behind") { |
| 158 |
test_camera->set_h_offset(-11.0f); |
| 159 |
test_camera->set_v_offset(22.1f); |
| 160 |
CHECK(test_camera->is_position_behind(test_camera->get_global_position() + offset1)); |
| 161 |
test_camera->set_h_offset(4.7f); |
| 162 |
test_camera->set_v_offset(-3.0f); |
| 163 |
CHECK_FALSE(test_camera->is_position_behind(test_camera->get_global_position() + offset2)); |
| 164 |
} |
| 165 |
|
| 166 |
test_camera->set_h_offset(0); |
| 167 |
test_camera->set_v_offset(0); |
| 168 |
} |
| 169 |
|
| 170 |
SUBCASE("is_position_in_frustum") { |
| 171 |
|
| 172 |
|
| 173 |
CHECK_FALSE(test_camera->is_position_in_frustum(test_camera->get_global_position() + offset1)); |
| 174 |
|
| 175 |
|
| 176 |
CHECK(test_camera->is_position_in_frustum(test_camera->get_global_position() + offset2)); |
| 177 |
CHECK_FALSE(test_camera->is_position_in_frustum(test_camera->get_global_position() + offset3)); |
| 178 |
CHECK_FALSE(test_camera->is_position_in_frustum(test_camera->get_global_position() + offset4)); |
| 179 |
|
| 180 |
CHECK_FALSE(test_camera->is_position_in_frustum(test_camera->get_global_position() + offset5)); |
| 181 |
} |
| 182 |
} |
| 183 |
|
| 184 |
SUBCASE("Perspective projection") { |
| 185 |
test_camera->set_projection(Camera3D::ProjectionType::PROJECTION_PERSPECTIVE); |
| 186 |
|
| 187 |
test_camera->set_global_position(Vector3(0, 0, 0)); |
| 188 |
test_camera->set_global_rotation(Vector3(0, 0, 0)); |
| 189 |
|
| 190 |
|
| 191 |
|
| 192 |
test_camera->set_perspective(120.0f, 1.0f, 1000.0f); |
| 193 |
|
| 194 |
SUBCASE("is_position_behind") { |
| 195 |
CHECK_FALSE(test_camera->is_position_behind(Vector3(0, 0, -1.5f))); |
| 196 |
CHECK(test_camera->is_position_behind(Vector3(2, 0, -0.2f))); |
| 197 |
} |
| 198 |
|
| 199 |
SUBCASE("is_position_in_frustum") { |
| 200 |
CHECK(test_camera->is_position_in_frustum(Vector3(-1.3f, 0, -1.1f))); |
| 201 |
CHECK_FALSE(test_camera->is_position_in_frustum(Vector3(2, 0, -1.1f))); |
| 202 |
CHECK(test_camera->is_position_in_frustum(Vector3(1, 0.5f, -1.1f))); |
| 203 |
CHECK_FALSE(test_camera->is_position_in_frustum(Vector3(1, 1, -1.1f))); |
| 204 |
CHECK(test_camera->is_position_in_frustum(Vector3(0, 0, -1.5f))); |
| 205 |
CHECK_FALSE(test_camera->is_position_in_frustum(Vector3(0, 0, -0.5f))); |
| 206 |
} |
| 207 |
} |
| 208 |
|
| 209 |
memdelete(test_camera); |
| 210 |
memdelete(mock_viewport); |
| 211 |
} |
| 212 |
|
| 213 |
TEST_CASE("[SceneTree][Camera3D] Project/Unproject position") { |
| 214 |
|
| 215 |
Camera3D *test_camera = memnew(Camera3D); |
| 216 |
SubViewport *mock_viewport = memnew(SubViewport); |
| 217 |
|
| 218 |
mock_viewport->set_size(Vector2(400, 200)); |
| 219 |
SceneTree::get_singleton()->get_root()->add_child(mock_viewport); |
| 220 |
mock_viewport->add_child(test_camera); |
| 221 |
test_camera->set_global_position(Vector3(0, 0, 0)); |
| 222 |
test_camera->set_global_rotation(Vector3(0, 0, 0)); |
| 223 |
test_camera->set_keep_aspect_mode(Camera3D::KeepAspect::KEEP_HEIGHT); |
| 224 |
|
| 225 |
SUBCASE("project_position") { |
| 226 |
SUBCASE("Orthogonal projection") { |
| 227 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 228 |
|
| 229 |
CHECK(test_camera->project_position(Vector2(200, 100), 0.5f).is_equal_approx(Vector3(0, 0, -0.5f))); |
| 230 |
CHECK(test_camera->project_position(Vector2(200, 100), test_camera->get_far()).is_equal_approx(Vector3(0, 0, -test_camera->get_far()))); |
| 231 |
|
| 232 |
CHECK(test_camera->project_position(Vector2(0, 0), 1.5f).is_equal_approx(Vector3(-5.0f, 2.5f, -1.5f))); |
| 233 |
CHECK(test_camera->project_position(Vector2(0, 0), test_camera->get_near()).is_equal_approx(Vector3(-5.0f, 2.5f, -test_camera->get_near()))); |
| 234 |
|
| 235 |
CHECK(test_camera->project_position(Vector2(400, 200), 5.0f).is_equal_approx(Vector3(5.0f, -2.5f, -5.0f))); |
| 236 |
CHECK(test_camera->project_position(Vector2(400, 200), test_camera->get_far()).is_equal_approx(Vector3(5.0f, -2.5f, -test_camera->get_far()))); |
| 237 |
} |
| 238 |
|
| 239 |
SUBCASE("Perspective projection") { |
| 240 |
test_camera->set_perspective(120.0f, 0.5f, 1000.0f); |
| 241 |
|
| 242 |
CHECK(test_camera->project_position(Vector2(200, 100), 0.5f).is_equal_approx(Vector3(0, 0, -0.5f))); |
| 243 |
CHECK(test_camera->project_position(Vector2(200, 100), 100.0f).is_equal_approx(Vector3(0, 0, -100.0f))); |
| 244 |
CHECK(test_camera->project_position(Vector2(200, 100), test_camera->get_far()).is_equal_approx(Vector3(0, 0, -1.0f) * test_camera->get_far())); |
| 245 |
|
| 246 |
CHECK(test_camera->project_position(Vector2(100, 50), 0.5f).is_equal_approx(Vector3(-Math::SQRT3 * 0.5f, Math::SQRT3 * 0.25f, -0.5f))); |
| 247 |
CHECK(test_camera->project_position(Vector2(100, 50), 1.0f).is_equal_approx(Vector3(-Math::SQRT3, Math::SQRT3 * 0.5f, -1.0f))); |
| 248 |
CHECK(test_camera->project_position(Vector2(100, 50), test_camera->get_near()).is_equal_approx(Vector3(-Math::SQRT3, Math::SQRT3 * 0.5f, -1.0f) * test_camera->get_near())); |
| 249 |
|
| 250 |
CHECK(test_camera->project_position(Vector2(300, 150), 0.5f).is_equal_approx(Vector3(Math::SQRT3 * 0.5f, -Math::SQRT3 * 0.25f, -0.5f))); |
| 251 |
CHECK(test_camera->project_position(Vector2(300, 150), 1.0f).is_equal_approx(Vector3(Math::SQRT3, -Math::SQRT3 * 0.5f, -1.0f))); |
| 252 |
CHECK(test_camera->project_position(Vector2(300, 150), test_camera->get_far()).is_equal_approx(Vector3(Math::SQRT3, -Math::SQRT3 * 0.5f, -1.0f) * test_camera->get_far())); |
| 253 |
} |
| 254 |
} |
| 255 |
|
| 256 |
|
| 257 |
SUBCASE("unproject_position") { |
| 258 |
SUBCASE("Orthogonal projection") { |
| 259 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 260 |
|
| 261 |
CHECK(test_camera->unproject_position(Vector3(0, 0, -0.5f)).is_equal_approx(Vector2(200, 100))); |
| 262 |
|
| 263 |
CHECK(test_camera->unproject_position(Vector3(-5.0f, 2.5f, -1.5f)).is_equal_approx(Vector2(0, 0))); |
| 264 |
|
| 265 |
CHECK(test_camera->unproject_position(Vector3(5.0f, -2.5f, -5.0f)).is_equal_approx(Vector2(400, 200))); |
| 266 |
} |
| 267 |
|
| 268 |
SUBCASE("Perspective projection") { |
| 269 |
test_camera->set_perspective(120.0f, 0.5f, 1000.0f); |
| 270 |
|
| 271 |
CHECK(test_camera->unproject_position(Vector3(0, 0, -0.5f)).is_equal_approx(Vector2(200, 100))); |
| 272 |
CHECK(test_camera->unproject_position(Vector3(0, 0, -100.0f)).is_equal_approx(Vector2(200, 100))); |
| 273 |
|
| 274 |
WARN(test_camera->unproject_position(Vector3(-Math::SQRT3 * 0.5f, Math::SQRT3 * 0.25f, -0.5f)).is_equal_approx(Vector2(100, 50))); |
| 275 |
WARN(test_camera->unproject_position(Vector3(-Math::SQRT3, Math::SQRT3 * 0.5f, -1.0f)).is_equal_approx(Vector2(100, 50))); |
| 276 |
|
| 277 |
CHECK(test_camera->unproject_position(Vector3(Math::SQRT3 * 0.5f, -Math::SQRT3 * 0.25f, -0.5f)).is_equal_approx(Vector2(300, 150))); |
| 278 |
CHECK(test_camera->unproject_position(Vector3(Math::SQRT3, -Math::SQRT3 * 0.5f, -1.0f)).is_equal_approx(Vector2(300, 150))); |
| 279 |
} |
| 280 |
} |
| 281 |
|
| 282 |
memdelete(test_camera); |
| 283 |
memdelete(mock_viewport); |
| 284 |
} |
| 285 |
|
| 286 |
TEST_CASE("[SceneTree][Camera3D] Project ray") { |
| 287 |
|
| 288 |
Camera3D *test_camera = memnew(Camera3D); |
| 289 |
SubViewport *mock_viewport = memnew(SubViewport); |
| 290 |
|
| 291 |
mock_viewport->set_size(Vector2(400, 200)); |
| 292 |
SceneTree::get_singleton()->get_root()->add_child(mock_viewport); |
| 293 |
mock_viewport->add_child(test_camera); |
| 294 |
test_camera->set_global_position(Vector3(0, 0, 0)); |
| 295 |
test_camera->set_global_rotation(Vector3(0, 0, 0)); |
| 296 |
test_camera->set_keep_aspect_mode(Camera3D::KeepAspect::KEEP_HEIGHT); |
| 297 |
|
| 298 |
SUBCASE("project_ray_origin") { |
| 299 |
SUBCASE("Orthogonal projection") { |
| 300 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 301 |
|
| 302 |
CHECK(test_camera->project_ray_origin(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, -0.5f))); |
| 303 |
|
| 304 |
CHECK(test_camera->project_ray_origin(Vector2(0, 0)).is_equal_approx(Vector3(-5.0f, 2.5f, -0.5f))); |
| 305 |
|
| 306 |
CHECK(test_camera->project_ray_origin(Vector2(400, 200)).is_equal_approx(Vector3(5.0f, -2.5f, -0.5f))); |
| 307 |
} |
| 308 |
|
| 309 |
SUBCASE("Perspective projection") { |
| 310 |
test_camera->set_perspective(120.0f, 0.5f, 1000.0f); |
| 311 |
|
| 312 |
CHECK(test_camera->project_ray_origin(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, 0))); |
| 313 |
|
| 314 |
CHECK(test_camera->project_ray_origin(Vector2(0, 0)).is_equal_approx(Vector3(0, 0, 0))); |
| 315 |
|
| 316 |
CHECK(test_camera->project_ray_origin(Vector2(400, 200)).is_equal_approx(Vector3(0, 0, 0))); |
| 317 |
} |
| 318 |
} |
| 319 |
|
| 320 |
SUBCASE("project_ray_normal") { |
| 321 |
SUBCASE("Orthogonal projection") { |
| 322 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 323 |
|
| 324 |
CHECK(test_camera->project_ray_normal(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, -1))); |
| 325 |
|
| 326 |
CHECK(test_camera->project_ray_normal(Vector2(0, 0)).is_equal_approx(Vector3(0, 0, -1))); |
| 327 |
|
| 328 |
CHECK(test_camera->project_ray_normal(Vector2(400, 200)).is_equal_approx(Vector3(0, 0, -1))); |
| 329 |
} |
| 330 |
|
| 331 |
SUBCASE("Perspective projection") { |
| 332 |
test_camera->set_perspective(120.0f, 0.5f, 1000.0f); |
| 333 |
|
| 334 |
CHECK(test_camera->project_ray_normal(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, -1))); |
| 335 |
|
| 336 |
CHECK(test_camera->project_ray_normal(Vector2(0, 0)).is_equal_approx(Vector3(-Math::SQRT3, Math::SQRT3 / 2, -0.5f).normalized())); |
| 337 |
|
| 338 |
CHECK(test_camera->project_ray_normal(Vector2(400, 200)).is_equal_approx(Vector3(Math::SQRT3, -Math::SQRT3 / 2, -0.5f).normalized())); |
| 339 |
} |
| 340 |
} |
| 341 |
|
| 342 |
SUBCASE("project_local_ray_normal") { |
| 343 |
test_camera->set_rotation_degrees(Vector3(60, 60, 60)); |
| 344 |
|
| 345 |
SUBCASE("Orthogonal projection") { |
| 346 |
test_camera->set_orthogonal(5.0f, 0.5f, 1000.0f); |
| 347 |
|
| 348 |
CHECK(test_camera->project_local_ray_normal(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, -1))); |
| 349 |
|
| 350 |
CHECK(test_camera->project_local_ray_normal(Vector2(0, 0)).is_equal_approx(Vector3(0, 0, -1))); |
| 351 |
|
| 352 |
CHECK(test_camera->project_local_ray_normal(Vector2(400, 200)).is_equal_approx(Vector3(0, 0, -1))); |
| 353 |
} |
| 354 |
|
| 355 |
SUBCASE("Perspective projection") { |
| 356 |
test_camera->set_perspective(120.0f, 0.5f, 1000.0f); |
| 357 |
|
| 358 |
CHECK(test_camera->project_local_ray_normal(Vector2(200, 100)).is_equal_approx(Vector3(0, 0, -1))); |
| 359 |
|
| 360 |
CHECK(test_camera->project_local_ray_normal(Vector2(0, 0)).is_equal_approx(Vector3(-Math::SQRT3, Math::SQRT3 / 2, -0.5f).normalized())); |
| 361 |
|
| 362 |
CHECK(test_camera->project_local_ray_normal(Vector2(400, 200)).is_equal_approx(Vector3(Math::SQRT3, -Math::SQRT3 / 2, -0.5f).normalized())); |
| 363 |
} |
| 364 |
} |
| 365 |
|
| 366 |
memdelete(test_camera); |
| 367 |
memdelete(mock_viewport); |
| 368 |
} |