Lumiverse  2.5
A framework for creating lighting control applications
ToneMapper.h
1 #ifndef LUMIVERSE_TONEMAPPER_H
2 #define LUMIVERSE_TONEMAPPER_H
3 
4 #include "EXRLayer.h"
5 
6 #ifdef USE_ARNOLD_CACHING
7 
8 namespace Lumiverse {
9 
18 class ToneMapper {
19 public:
23  ToneMapper();
24 
28  ~ToneMapper();
29 
34  std::string get_type();
35 
40  float get_gamma();
41 
46  void set_gamma(float gamma);
47 
52  float get_level();
53 
58  void set_level(float level);
59 
66  void set_input(Pixel4 *buffer, size_t w, size_t h);
67 
72  void set_output_hdr(float *buffer);
73 
78  void set_output_bmp(char *buffer);
79 
85  virtual void apply_hdr();
86 
91  virtual void apply_hdr_inplace(Pixel4* in, float* out, size_t w, size_t h);
92 
98  virtual void apply_bmp();
99 
103  virtual void reset();
104 
105  void update_dims(int width, int height);
106 
107 protected:
111  std::string type;
112 
116  size_t w;
117 
121  size_t h;
122 
128  float gamma;
129 
138  float level;
139 
147  Pixel4 *input_buffer;
148 
156  float *hdr_output_buffer;
157 
164  char *bmp_output_buffer;
165 };
166 
167 }; // namespace LightmanCore
168 
169 #endif // USE_ARNOLD_CACHING
170 
171 #endif // LIGHTMAN_TONEMAPPER_H
Contains all core Lumiverse functions and variables.
Definition: Device.cpp:2