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:
authorSergey Sharybin <sergey.vfx@gmail.com>2018-02-14 14:33:34 +0300
committerSergey Sharybin <sergey.vfx@gmail.com>2018-02-15 13:53:57 +0300
commitff82968a6ca3332cc5cccbf766821274d8bb469e (patch)
tree8926615b93532c94860f016d155a09ce3667bed3 /source/blender/blenkernel/particle_private.h
parent58ba89b5bec5a2b7b74ef93fe18f0a3811cb48db (diff)
Particles: Wrap insane amount of arguments to child modifier evaluation
Use single structure. It seems we will need to pass more information soon, so better to do it via the structure.
Diffstat (limited to 'source/blender/blenkernel/particle_private.h')
-rw-r--r--source/blender/blenkernel/particle_private.h17
1 files changed, 14 insertions, 3 deletions
diff --git a/source/blender/blenkernel/particle_private.h b/source/blender/blenkernel/particle_private.h
index b4878807df7..00a7637e246 100644
--- a/source/blender/blenkernel/particle_private.h
+++ b/source/blender/blenkernel/particle_private.h
@@ -31,12 +31,23 @@
#ifndef __PARTICLE_PRIVATE_H__
#define __PARTICLE_PRIVATE_H__
+typedef struct ParticleChildModifierContext {
+ ParticleThreadContext *thread_ctx;
+ ParticleSimulationData *sim;
+ ParticleTexture *ptex;
+ ChildParticle *cpa;
+ const float *par_co; /* float3 */
+ const float *par_vel; /* float3 */
+ const float *par_rot; /* float4 */
+ const float *par_orco; /* float3 */
+ const float *orco; /* float3 */
+} ParticleChildModifierContext;
+
void do_kink(ParticleKey *state, const float par_co[3], const float par_vel[3], const float par_rot[4], float time, float freq, float shape, float amplitude, float flat,
short type, short axis, float obmat[4][4], int smooth_start);
float do_clump(ParticleKey *state, const float par_co[3], float time, const float orco_offset[3], float clumpfac, float clumppow, float pa_clump,
bool use_clump_noise, float clump_noise_size, CurveMapping *clumpcurve);
-void do_child_modifiers(ParticleThreadContext *ctx, ParticleSimulationData *sim,
- ParticleTexture *ptex, const float par_co[3], const float par_vel[3], const float par_rot[4], const float par_orco[3],
- ChildParticle *cpa, const float orco[3], float mat[4][4], ParticleKey *state, float t);
+void do_child_modifiers(const ParticleChildModifierContext *modifier_ctx,
+ float mat[4][4], ParticleKey *state, float t);
#endif /* __PARTICLE_PRIVATE_H__ */