14 float fixedDt = 1.f / 60.f;
15 float agentRadius = 0.25f;
16 float obstaclePredictTime = 0.35f;
24 float separationRadius = 1.5f;
25 float cohesionRadius = 4.0f;
26 float alignmentRadius = 3.0f;
27 float perceptionFovDegrees = 270.f;
28 int maxNeighborSamples = 24;
30 float separationWeight = 1.4f;
31 float cohesionWeight = 0.8f;
32 float alignmentWeight = 1.0f;
33 float goalWeight = 0.6f;
34 float dangerWeight = 1.8f;
35 float currentWeight = 1.0f;
36 float depthWeight = 0.5f;
38 float maxSpeed = 4.0f;
39 float maxAcceleration = 12.0f;
40 float maxHorizontalTurn = 4.0f;
41 float maxVerticalTurn = 2.5f;
42 float preferredDepth = 0.0f;
43 float depthTolerance = 2.0f;
50 int fieldResolution = 64;
51 float worldSize = 32.f;
54 float sensorDistance = 1.5f;
55 float sensorAngle = 0.6f;
56 float trailFollow = 1.2f;
57 float nutrient = 0.4f;
58 float repulsion = 0.8f;
61 float depositStrength = 0.35f;
62 float trailDecayRate = 0.15f;
63 float freshnessHalfLife = 4.0f;
64 float diffusionRate = 0.08f;
65 float moveSpeed = 1.8f;
66 float minSurfaceNormalZ = 0.35f;
73 float separationRadius = 2.0f;
74 float cohesionRadius = 6.0f;
75 float alignmentRadius = 5.0f;
76 float perceptionFovDegrees = 300.f;
77 int maxNeighborSamples = 20;
79 float separationWeight = 1.2f;
80 float cohesionWeight = 0.7f;
81 float alignmentWeight = 1.1f;
82 float goalWeight = 0.5f;
84 float stallSpeed = 2.5f;
85 float cruiseSpeed = 6.0f;
86 float maxSpeed = 10.0f;
87 float liftCoefficient = 1.4f;
88 float gravityScale = 1.0f;
89 float airDrag = 0.35f;
91 float maxClimbSpeed = 3.0f;
92 float maxDescentSpeed = 5.0f;
93 float maxTurnRate = 2.8f;
94 float maxBankAngle = 0.85f;
96 float timeToCollision = 0.8f;
97 float groundClearance = 1.5f;
98 float ceilingClearance = 2.0f;
99 float windResponseTime = 0.4f;
100 float gustAcceleration = 2.0f;
101 glm::vec3 uniformWindLocal{0.f, 0.f, 0.f};
112 float sizeVariation = 0.25f;
114 float frontalDrag = 1.8f;
115 float edgeDrag = 0.35f;
116 float liftCoeff = 0.55f;
117 float angularDrag = 0.9f;
118 float pressureCenterOffset = 0.15f;
121 float settleSpeed = 0.15f;
122 float softBoundPadding = 1.0f;
123 float groundY = 0.0f;
125 glm::vec3 worldMin{-20.f, -1.f, -20.f};
126 glm::vec3 worldMax{20.f, 30.f, 20.f};
140 case EffectKind::LifeNetwork:
return life.base;
141 case EffectKind::Bird:
return bird.base;
142 case EffectKind::Petal:
return petal.base;
143 case EffectKind::Fish:
144 default:
return fish.base;
151 case EffectKind::LifeNetwork:
return life.base;
152 case EffectKind::Bird:
return bird.base;
153 case EffectKind::Petal:
return petal.base;
154 case EffectKind::Fish:
155 default:
return fish.base;
162 p.
kind = EffectKind::Fish;
163 p.fish.base.kind = EffectKind::Fish;
164 p.fish.base.maxAgents = maxAgents;
171 p.
kind = EffectKind::LifeNetwork;
172 p.life.base.kind = EffectKind::LifeNetwork;
173 p.life.base.maxAgents = maxAgents;
174 p.life.fieldResolution = resolution;
181 p.
kind = EffectKind::Bird;
182 p.bird.base.kind = EffectKind::Bird;
183 p.bird.base.maxAgents = maxAgents;
190 p.
kind = EffectKind::Petal;
191 p.petal.base.kind = EffectKind::Petal;
192 p.petal.base.maxAgents = maxAgents;
#define EVENGINE_API_DOMAINS
std::weak_ptr< const void > lifetime
EffectKind
Effect kind selecting the solver kernel.
Bird flock flight-dynamics parameters.
Shared capacity / timing / collision envelope for every effect.
Type-erased profile bundle owned by an EffectBackend.
EffectProfileBase & base()
Mutable shared base slice for the active kind.
static EffectProfile makePetal(int maxAgents=512)
Factory for a default petal profile.
const EffectProfileBase & base() const
Returns the shared base slice for the active kind.
static EffectProfile makeBird(int maxAgents=256)
Factory for a default bird profile.
static EffectProfile makeFish(int maxAgents=256)
Factory for a default fish profile.
static EffectProfile makeLife(int maxAgents=128, int resolution=64)
Factory for a default life-network profile.
3D Boids fish school parameters.
Life Network 2D surface-trail parameters.
Passive petal rigid-body aerodynamic parameters.