[Bf-blender-cvs] [8194f22] master: Point Cache bake: make sure endframe is initialize with a decent value.

Kévin Dietrich noreply at git.blender.org
Sun Jan 17 03:13:59 CET 2016


Commit: 8194f223d89866a669ad8936ef67e1e1ac45830f
Author: Kévin Dietrich
Date:   Sun Jan 17 03:13:15 2016 +0100
Branches: master
https://developer.blender.org/rB8194f223d89866a669ad8936ef67e1e1ac45830f

Point Cache bake: make sure endframe is initialize with a decent value.

This is how the old code used to initialize it. Current value was
failing big time when baking all caches (always set to MAXFRAME), and it
was added right before commit to quiet a warning... (I know, I know...)

===================================================================

M	source/blender/blenkernel/intern/pointcache.c

===================================================================

diff --git a/source/blender/blenkernel/intern/pointcache.c b/source/blender/blenkernel/intern/pointcache.c
index 7009b4b..ad59994 100644
--- a/source/blender/blenkernel/intern/pointcache.c
+++ b/source/blender/blenkernel/intern/pointcache.c
@@ -3147,7 +3147,7 @@ void BKE_ptcache_bake(PTCacheBaker *baker)
 	PointCache *cache = NULL;
 	float frameleno = scene->r.framelen;
 	int cfrao = CFRA;
-	int startframe = MAXFRAME, endframe = MAXFRAME;
+	int startframe = MAXFRAME, endframe = baker->anim_init ? scene->r.sfra : CFRA;
 	int bake = baker->bake;
 	int render = baker->render;




More information about the Bf-blender-cvs mailing list