Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'intern/cycles/render/session.h')
-rw-r--r--intern/cycles/render/session.h51
1 files changed, 35 insertions, 16 deletions
diff --git a/intern/cycles/render/session.h b/intern/cycles/render/session.h
index c7ff1446171..e63cad0d977 100644
--- a/intern/cycles/render/session.h
+++ b/intern/cycles/render/session.h
@@ -17,15 +17,15 @@
#ifndef __SESSION_H__
#define __SESSION_H__
-#include "buffers.h"
-#include "device.h"
-#include "shader.h"
-#include "tile.h"
+#include "render/buffers.h"
+#include "device/device.h"
+#include "render/shader.h"
+#include "render/tile.h"
-#include "util_progress.h"
-#include "util_stats.h"
-#include "util_thread.h"
-#include "util_vector.h"
+#include "util/util_progress.h"
+#include "util/util_stats.h"
+#include "util/util_thread.h"
+#include "util/util_vector.h"
CCL_NAMESPACE_BEGIN
@@ -45,7 +45,6 @@ public:
DeviceInfo device;
bool background;
bool progressive_refine;
- string output_path;
bool progressive;
bool experimental;
@@ -53,10 +52,17 @@ public:
int2 tile_size;
TileOrder tile_order;
int start_resolution;
+ int pixel_size;
int threads;
bool display_buffer_linear;
+ bool use_denoising;
+ int denoising_radius;
+ float denoising_strength;
+ float denoising_feature_strength;
+ bool denoising_relative_pca;
+
double cancel_timeout;
double reset_timeout;
double text_timeout;
@@ -64,19 +70,30 @@ public:
ShadingSystem shadingsystem;
+ function<bool(const uchar *pixels,
+ int width,
+ int height,
+ int channels)> write_render_cb;
+
SessionParams()
{
background = false;
progressive_refine = false;
- output_path = "";
progressive = false;
experimental = false;
samples = INT_MAX;
tile_size = make_int2(64, 64);
start_resolution = INT_MAX;
+ pixel_size = 1;
threads = 0;
+ use_denoising = false;
+ denoising_radius = 8;
+ denoising_strength = 0.0f;
+ denoising_feature_strength = 0.0f;
+ denoising_relative_pca = false;
+
display_buffer_linear = false;
cancel_timeout = 0.1;
@@ -92,12 +109,12 @@ public:
{ return !(device == params.device
&& background == params.background
&& progressive_refine == params.progressive_refine
- && output_path == params.output_path
/* && samples == params.samples */
&& progressive == params.progressive
&& experimental == params.experimental
&& tile_size == params.tile_size
&& start_resolution == params.start_resolution
+ && pixel_size == params.pixel_size
&& threads == params.threads
&& display_buffer_linear == params.display_buffer_linear
&& cancel_timeout == params.cancel_timeout
@@ -126,7 +143,7 @@ public:
Stats stats;
function<void(RenderTile&)> write_render_tile_cb;
- function<void(RenderTile&)> update_render_tile_cb;
+ function<void(RenderTile&, bool)> update_render_tile_cb;
explicit Session(const SessionParams& params);
~Session();
@@ -141,7 +158,7 @@ public:
void set_pause(bool pause);
void update_scene();
- void load_kernels();
+ void load_kernels(bool lock_scene=true);
void device_free();
@@ -162,7 +179,7 @@ protected:
void update_status_time(bool show_pause = false, bool show_done = false);
void tonemap(int sample);
- void path_trace();
+ void render();
void reset_(BufferParams& params, int samples);
void run_cpu();
@@ -177,6 +194,9 @@ protected:
void update_tile_sample(RenderTile& tile);
void release_tile(RenderTile& tile);
+ void map_neighbor_tiles(RenderTile *tiles, Device *tile_device);
+ void unmap_neighbor_tiles(RenderTile *tiles, Device *tile_device);
+
bool device_use_gl;
thread *session_thread;
@@ -195,6 +215,7 @@ protected:
thread_mutex display_mutex;
bool kernels_loaded;
+ DeviceRequestedFeatures loaded_kernel_features;
double reset_time;
@@ -202,8 +223,6 @@ protected:
double last_update_time;
bool update_progressive_refine(bool cancel);
- vector<RenderBuffers *> tile_buffers;
-
DeviceRequestedFeatures get_requested_device_features();
/* ** Split kernel routines ** */