diff options
author | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-08-15 14:02:45 +0300 |
---|---|---|
committer | Sybren A. Stüvel <sybren@stuvel.eu> | 2017-08-15 14:02:45 +0300 |
commit | 3bca9f5fed1f6d3dd485e3cff2174c3394bb1162 (patch) | |
tree | 7083a56f6b8db22ad51a6319f7281cb4d7124c12 /source/blender/blenkernel/intern/scene.c | |
parent | 3311505fd07310a6bfac79ce787dbd394002dd1f (diff) | |
parent | f20d7bed1426ca3d1268182835f04e7ab8212cac (diff) |
Merge branch 'master' into blender2.8
# Conflicts:
# source/blender/makesrna/intern/rna_render.c
Diffstat (limited to 'source/blender/blenkernel/intern/scene.c')
-rw-r--r-- | source/blender/blenkernel/intern/scene.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/source/blender/blenkernel/intern/scene.c b/source/blender/blenkernel/intern/scene.c index 0229616ff7b..f71191a2211 100644 --- a/source/blender/blenkernel/intern/scene.c +++ b/source/blender/blenkernel/intern/scene.c @@ -2028,6 +2028,14 @@ int BKE_scene_num_threads(const Scene *scene) return BKE_render_num_threads(&scene->r); } +int BKE_render_preview_pixel_size(const RenderData *r) +{ + if (r->preview_pixel_size == 0) { + return (U.pixelsize > 1.5f)? 2 : 1; + } + return r->preview_pixel_size; +} + /* Apply the needed correction factor to value, based on unit_type (only length-related are affected currently) * and unit->scale_length. */ |