diff options
author | Jacques Lucke <jacques@blender.org> | 2020-06-08 16:41:41 +0300 |
---|---|---|
committer | Jacques Lucke <jacques@blender.org> | 2020-06-08 16:49:17 +0300 |
commit | 6f96dfabe5cbf6966282decd2307ade9aacdeaee (patch) | |
tree | 01529fbad8453faf81a62877d03373eaf0b77b57 /source/blender/editors/space_action | |
parent | bf4198cdaf7d4fa1a5f91526fb6bbe84d2fa2a37 (diff) |
Simulations: initial simulation state and cache
The current particle state is stored in a `CustomData` instance and
the cache is stored in `PointCache`.
The current state exists on the copy-on-write copies of the simulation,
while the cache only exists in the original data block.
This patch implements a temporary trivial particle simulation that does not
use the node system yet. It is used for testing and will be replaced soon.
`PointCache` still has some limitations that need to be overcome using
separate refactorings. For example, we need to be able to store the number
of particles in the point cache. Also we need to change which attributes
are stored for a particle system more dynamically than is currently possible afaik.
Reviewers: brecht
Differential Revision: https://developer.blender.org/D7836
Diffstat (limited to 'source/blender/editors/space_action')
-rw-r--r-- | source/blender/editors/space_action/action_draw.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/source/blender/editors/space_action/action_draw.c b/source/blender/editors/space_action/action_draw.c index 52287b07b28..ada4243ab4e 100644 --- a/source/blender/editors/space_action/action_draw.c +++ b/source/blender/editors/space_action/action_draw.c @@ -360,6 +360,7 @@ static bool timeline_cache_is_hidden_by_setting(SpaceAction *saction, PTCacheID } break; case PTCACHE_TYPE_PARTICLES: + case PTCACHE_TYPE_SIM_PARTICLES: if ((saction->cache_display & TIME_CACHE_PARTICLES) == 0) { return true; } @@ -399,6 +400,7 @@ static void timeline_cache_color_get(PTCacheID *pid, float color[4]) color[3] = 0.1; break; case PTCACHE_TYPE_PARTICLES: + case PTCACHE_TYPE_SIM_PARTICLES: color[0] = 1.0; color[1] = 0.1; color[2] = 0.02; |