[Bf-blender-cvs] [40a8ef5] alembic_pointcache: Merge branch 'master' into alembic_pointcache

Lukas Tönne noreply at git.blender.org
Thu Feb 12 16:37:45 CET 2015


Commit: 40a8ef5ef02427215afd6cacca353630a57cdbf5
Author: Lukas Tönne
Date:   Thu Feb 12 16:37:28 2015 +0100
Branches: alembic_pointcache
https://developer.blender.org/rB40a8ef5ef02427215afd6cacca353630a57cdbf5

Merge branch 'master' into alembic_pointcache

Conflicts:
	source/blender/blenkernel/intern/cloth.c

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



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

diff --cc source/blender/blenkernel/intern/cloth.c
index 3ba32f3,3173489..193324b
--- a/source/blender/blenkernel/intern/cloth.c
+++ b/source/blender/blenkernel/intern/cloth.c
@@@ -450,18 -462,13 +449,15 @@@ void clothModifier_do(ClothModifierDat
  	BKE_ptcache_id_time(&pid, scene, framenr, &startframe, &endframe, &timescale);
  	clmd->sim_parms->timescale= timescale;
  
- 	if (clmd->sim_parms->reset ||
- 	    (framenr == (startframe - clmd->sim_parms->preroll) && clmd->sim_parms->preroll != 0) ||
- 	    (clmd->clothObject && dm->getNumVerts(dm) != clmd->clothObject->numverts))
- 	{
+ 	if (clmd->sim_parms->reset || (clmd->clothObject && dm->getNumVerts(dm) != clmd->clothObject->numverts)) {
  		clmd->sim_parms->reset = 0;
 -		cache->flag |= PTCACHE_OUTDATED;
 +		cloth_free_modifier(clmd);
 +		
 +		cache->state.flag |= PTC_STATE_OUTDATED;
  		BKE_ptcache_id_reset(scene, &pid, PTCACHE_RESET_OUTDATED);
  		BKE_ptcache_validate(cache, 0);
 -		cache->last_exact= 0;
 -		cache->flag &= ~PTCACHE_REDO_NEEDED;
 +		cache->state.last_exact= 0;
 +		cache->state.flag &= ~PTC_STATE_REDO_NEEDED;
  	}
  	
  	// unused in the moment, calculated separately in implicit.c
@@@ -496,14 -487,11 +476,14 @@@
  	if (!do_init_cloth(ob, clmd, dm, framenr))
  		return;
  
- 	if ((framenr == startframe) && (clmd->sim_parms->preroll == 0)) {
+ 	if (framenr == startframe) {
 +		cloth_free_modifier(clmd);
 +
  		BKE_ptcache_id_reset(scene, &pid, PTCACHE_RESET_OUTDATED);
 -		do_init_cloth(ob, clmd, dm, framenr);
  		BKE_ptcache_validate(cache, framenr);
 -		cache->flag &= ~PTCACHE_REDO_NEEDED;
 +		cache->state.flag &= ~PTC_STATE_REDO_NEEDED;
 +
 +		do_init_cloth(ob, clmd, dm, framenr);
  		clmd->clothObject->last_frame= framenr;
  		return;
  	}




More information about the Bf-blender-cvs mailing list