public struct CameraImpulseSomething that happened somewhere, hard enough to be felt through the camera.
No guide page documents this yet — the page shows what the code says about itself.
Remarks
An impulse is an initial velocity, not a displacement. A shell landing gives the camera a shove of so many metres per second in some direction, and what is seen is the ring-down of that shove: a decaying oscillation whose amplitude is |Velocity| / 2πf. That is why doubling Frequency halves the visible kick from the same number — a high-frequency rattle and a low-frequency lurch are different events rather than the same one played at different speeds, and expressing them as an amplitude would make them the same one.
It has a place, so distance means something. Contributions fall off with DissipationDistance and arrive late by distance / PropagationSpeed — the far explosion is felt smaller and a moment after it is seen, which is free once the impulse knows where it happened.
Fields and properties (7)
public Vector3 PositionWhere it happened, in world space.
public Vector3 VelocityThe shove, in world units per second. Its direction is the direction of the kick.
public float DurationHow long the ring-down lasts, in seconds. The signal is exactly zero at the end.
public float FrequencyHow fast the camera rings, in cycles per second.
public float DissipationDistanceThe distance at which the impulse is no longer felt. Zero means it never fades.
public float PropagationSpeedHow fast the impulse travels outward, in world units per second. Zero arrives everywhere at once.
public float AgeHow long ago it happened. Owned by CameraImpulses.
Methods (1)
public static CameraImpulse Bump(Vector3 position, Vector3 velocity, float duration = 0.5, float dissipation = 0)A short, sharp knock in one direction.
Used by (4)
- CameraImpulsesVixen.Engine
- TypeRegistrationVixen.Engine
- VirtualCameraTestsVixen.Engine.Tests
- Vixen_Engine_Cameras_CameraImpulseSerializerVixen.Engine