diff options
Diffstat (limited to 'source/blender/render/intern/source/multires_bake.c')
-rw-r--r-- | source/blender/render/intern/source/multires_bake.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/source/blender/render/intern/source/multires_bake.c b/source/blender/render/intern/source/multires_bake.c index 4ac1593d1bb..6ba85ea5329 100644 --- a/source/blender/render/intern/source/multires_bake.c +++ b/source/blender/render/intern/source/multires_bake.c @@ -42,6 +42,7 @@ #include "BLI_threads.h" #include "BKE_ccg.h" +#include "BKE_depsgraph.h" #include "BKE_global.h" #include "BKE_image.h" #include "BKE_multires.h" @@ -1154,10 +1155,10 @@ static void apply_ao_callback(DerivedMesh *lores_dm, DerivedMesh *hires_dm, void /* this gives results identical to the so-called cosine * weighted distribution relative to the north pole. */ - float SiPhi = sqrt(SiSqPhi); + float SiPhi = sqrtf(SiSqPhi); float CoPhi = SiSqPhi < 1.0f ? sqrtf(1.0f - SiSqPhi) : 0; - float CoThe = cos(Theta); - float SiThe = sin(Theta); + float CoThe = cosf(Theta); + float SiThe = sinf(Theta); const float dx = CoThe * CoPhi; const float dy = SiThe * CoPhi; @@ -1297,6 +1298,7 @@ static void finish_images(MultiresBakeRender *bkr, MultiresBakeResult *result) } BKE_image_release_ibuf(ima, ibuf, NULL); + DAG_id_tag_update(&ima->id, 0); } } |