diff options
author | Bastien Montagne <montagne29@wanadoo.fr> | 2017-11-06 20:02:46 +0300 |
---|---|---|
committer | Bastien Montagne <montagne29@wanadoo.fr> | 2017-11-06 20:02:46 +0300 |
commit | 91af8f2ae2b5238839b57eaf74b0f950259ec57a (patch) | |
tree | 1e7e775c9830041457cbb5771804b8bddfbeee3a /intern/cycles/render/buffers.cpp | |
parent | 9d77b5d5910b65bed88817169d5444cfb189eb63 (diff) | |
parent | 66a6d160fe26c1bac7a5dd4cd26cb5fbd5cf348e (diff) |
Merge branch 'master' into blender2.8
Conflicts:
intern/cycles/device/device.cpp
source/blender/blenkernel/intern/library.c
source/blender/blenkernel/intern/material.c
source/blender/editors/object/object_add.c
source/blender/editors/object/object_relations.c
source/blender/editors/space_outliner/outliner_draw.c
source/blender/editors/space_outliner/outliner_edit.c
source/blender/editors/space_view3d/drawobject.c
source/blender/editors/util/ed_util.c
source/blender/windowmanager/intern/wm_files_link.c
Diffstat (limited to 'intern/cycles/render/buffers.cpp')
-rw-r--r-- | intern/cycles/render/buffers.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/intern/cycles/render/buffers.cpp b/intern/cycles/render/buffers.cpp index 70912ca8e87..d76eaf793b4 100644 --- a/intern/cycles/render/buffers.cpp +++ b/intern/cycles/render/buffers.cpp @@ -173,8 +173,8 @@ bool RenderBuffers::get_denoising_pass_rect(int offset, float exposure, int samp /* Approximate variance as E[x^2] - 1/N * (E[x])^2, since online variance * update does not work efficiently with atomics in the kernel. */ int mean_offset = offset - components; - float *mean = (float*)buffer.data_pointer + mean_offset; - float *var = (float*)buffer.data_pointer + offset; + float *mean = buffer.data() + mean_offset; + float *var = buffer.data() + offset; assert(mean_offset >= 0); if(components == 1) { @@ -194,7 +194,7 @@ bool RenderBuffers::get_denoising_pass_rect(int offset, float exposure, int samp } } else { - float *in = (float*)buffer.data_pointer + offset; + float *in = buffer.data() + offset; if(components == 1) { for(int i = 0; i < size; i++, in += pass_stride, pixels++) { @@ -228,7 +228,7 @@ bool RenderBuffers::get_pass_rect(PassType type, float exposure, int sample, int continue; } - float *in = (float*)buffer.data_pointer + pass_offset; + float *in = buffer.data() + pass_offset; int pass_stride = params.get_passes_size(); float scale = (pass.filter)? 1.0f/(float)sample: 1.0f; @@ -295,7 +295,7 @@ bool RenderBuffers::get_pass_rect(PassType type, float exposure, int sample, int pass_offset += color_pass.components; } - float *in_divide = (float*)buffer.data_pointer + pass_offset; + float *in_divide = buffer.data() + pass_offset; for(int i = 0; i < size; i++, in += pass_stride, in_divide += pass_stride, pixels += 3) { float3 f = make_float3(in[0], in[1], in[2]); @@ -344,7 +344,7 @@ bool RenderBuffers::get_pass_rect(PassType type, float exposure, int sample, int pass_offset += color_pass.components; } - float *in_weight = (float*)buffer.data_pointer + pass_offset; + float *in_weight = buffer.data() + pass_offset; for(int i = 0; i < size; i++, in += pass_stride, in_weight += pass_stride, pixels += 4) { float4 f = make_float4(in[0], in[1], in[2], in[3]); |