Open3D (C++ API)  0.18.0
View.h
Go to the documentation of this file.
1 // ----------------------------------------------------------------------------
2 // - Open3D: www.open3d.org -
3 // ----------------------------------------------------------------------------
4 // Copyright (c) 2018-2023 www.open3d.org
5 // SPDX-License-Identifier: MIT
6 // ----------------------------------------------------------------------------
7 
8 #pragma once
9 
10 #include <Eigen/Geometry>
11 
13 
14 namespace open3d {
15 namespace visualization {
16 namespace rendering {
17 
18 class Scene;
19 class Camera;
20 class ColorGradingParams;
21 
22 class View {
23 public:
24  enum class TargetBuffers : std::uint8_t {
25  None = 0u,
26  Color = 1u,
27  Depth = 2u,
28  Stencil = 4u,
29 
33  All = Color | Depth | Stencil
34  };
35 
36  enum class Mode : std::uint8_t {
37  Color = 0u,
38  Depth,
39  Normals,
40  // This three modes always stay at end
41  ColorMapX,
42  ColorMapY,
43  ColorMapZ
44  };
45 
46  enum class ShadowType : std::uint8_t {
47  kPCF, /* Percentage closer filter, the default */
48  kVSM /* Variance shadow map */
49  };
50 
51  virtual ~View() {}
52 
53  virtual void SetDiscardBuffers(const TargetBuffers& buffers) = 0;
54  virtual Mode GetMode() const = 0;
55  virtual void SetMode(Mode mode) = 0;
56  virtual void SetWireframe(bool enable) = 0;
57 
58  virtual void SetSampleCount(int n) = 0;
59  virtual int GetSampleCount() const = 0;
60 
61  virtual void SetViewport(std::int32_t x,
62  std::int32_t y,
63  std::uint32_t w,
64  std::uint32_t h) = 0;
65  virtual std::array<int, 4> GetViewport() const = 0;
66 
67  virtual void SetPostProcessing(bool enabled) = 0;
68  virtual void SetAmbientOcclusion(bool enabled,
69  bool ssct_enabled = false) = 0;
70  virtual void SetBloom(bool enabled,
71  float strength = 0.5f,
72  int spread = 6) = 0;
73  virtual void SetAntiAliasing(bool enabled, bool temporal = false) = 0;
74  virtual void SetShadowing(bool enabled, ShadowType type) = 0;
75 
76  virtual void SetColorGrading(const ColorGradingParams& color_grading) = 0;
77 
78  virtual void ConfigureForColorPicking() = 0;
79 
80  virtual void EnableViewCaching(bool enable) = 0;
81  virtual bool IsCached() const = 0;
83 
84  virtual Camera* GetCamera() const = 0;
85 };
86 
87 } // namespace rendering
88 } // namespace visualization
89 } // namespace open3d
Manages.
Definition: ColorGrading.h:18
virtual TextureHandle GetColorBuffer()=0
virtual void SetAmbientOcclusion(bool enabled, bool ssct_enabled=false)=0
virtual void SetViewport(std::int32_t x, std::int32_t y, std::uint32_t w, std::uint32_t h)=0
virtual Camera * GetCamera() const =0
virtual void SetPostProcessing(bool enabled)=0
virtual void SetColorGrading(const ColorGradingParams &color_grading)=0
virtual void SetMode(Mode mode)=0
virtual void SetSampleCount(int n)=0
virtual void SetAntiAliasing(bool enabled, bool temporal=false)=0
virtual void SetDiscardBuffers(const TargetBuffers &buffers)=0
virtual void SetBloom(bool enabled, float strength=0.5f, int spread=6)=0
virtual void SetShadowing(bool enabled, ShadowType type)=0
virtual void EnableViewCaching(bool enable)=0
virtual ~View()
Definition: View.h:51
virtual std::array< int, 4 > GetViewport() const =0
virtual void SetWireframe(bool enable)=0
virtual int GetSampleCount() const =0
virtual bool IsCached() const =0
char type
Definition: FilePCD.cpp:41
const char const char value recording_handle imu_sample recording_handle uint8_t size_t data_size k4a_record_configuration_t config target_format k4a_capture_t capture_handle k4a_imu_sample_t imu_sample playback_handle k4a_logging_message_cb_t void min_level device_handle k4a_imu_sample_t timeout_in_ms capture_handle capture_handle capture_handle image_handle temperature_c k4a_image_t image_handle uint8_t image_handle image_handle image_handle image_handle uint32_t
Definition: K4aPlugin.cpp:548
const char const char value recording_handle imu_sample recording_handle uint8_t size_t data_size k4a_record_configuration_t config target_format k4a_capture_t capture_handle k4a_imu_sample_t imu_sample playback_handle k4a_logging_message_cb_t void min_level device_handle k4a_imu_sample_t timeout_in_ms capture_handle capture_handle capture_handle image_handle temperature_c k4a_image_t image_handle uint8_t image_handle image_handle image_handle image_handle image_handle timestamp_usec white_balance image_handle k4a_device_configuration_t config device_handle char size_t serial_number_size bool int32_t int32_t int32_t int32_t k4a_color_control_mode_t default_mode mode
Definition: K4aPlugin.cpp:678
const char const char value recording_handle imu_sample recording_handle uint8_t size_t data_size k4a_record_configuration_t config target_format k4a_capture_t capture_handle k4a_imu_sample_t imu_sample playback_handle k4a_logging_message_cb_t void min_level device_handle k4a_imu_sample_t int32_t
Definition: K4aPlugin.cpp:395
Definition: PinholeCameraIntrinsic.cpp:16