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:
authorDalai Felinto <dfelinto@gmail.com>2018-12-07 22:01:45 +0300
committerDalai Felinto <dfelinto@gmail.com>2018-12-12 02:57:16 +0300
commit6871402614f48ef9c454d057c544ed43abeb87ae (patch)
treed8e97b1993d626c3dfc6004abdb98df9e851f73f /source/blender/render
parent174acd9ca376a4fb0e4a50d27359ee5f8ac7f3fe (diff)
Fix Cycles baking active/cage
Basically what we address here is to make sure the active object and the cage are not interferring with the baking result (e.g., when baking Combined). To do so, we take advantage of the fact that we create our own depsgraph for baking. So now we can change the cowed objects, instead of the original ones. Note: There is still a way to get a crash. If you try to bake from selected to active when is_cage, but with no cage object, we get an assert: ``` BLI_assert failed: //source/blender/blenkernel/intern/DerivedMesh.c mesh_calc_modifiers(), at (((Mesh *)ob->data)->id.tag & LIB_TAG_COPIED_ON_WRITE_EVAL_RESULT) == 0 ``` We can bypass this by passing ob_low instead of ob_low_eval to bake_mesh_new_from_object on object_bake_api.c:847 . But then the edge split modifier change will take no effect.
Diffstat (limited to 'source/blender/render')
-rw-r--r--source/blender/render/extern/include/RE_bake.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/source/blender/render/extern/include/RE_bake.h b/source/blender/render/extern/include/RE_bake.h
index 298bb72a02c..4489efc6a10 100644
--- a/source/blender/render/extern/include/RE_bake.h
+++ b/source/blender/render/extern/include/RE_bake.h
@@ -59,8 +59,8 @@ typedef struct BakePixel {
typedef struct BakeHighPolyData {
struct Object *ob;
+ struct Object *ob_eval;
struct Mesh *me;
- char restrict_flag;
bool is_flip_object;
float obmat[4][4];