Repulsion Effect

Repulsion Effect

Code
Damien Montastier
Damien Montastier
repulsioneffecthover

This experiment demonstrates a dynamic repulsion effect where particles react to mouse movement, creating an engaging interactive experience. Watch as particles flee from your cursor in realistic physics-based motion, showcasing advanced particle systems and user interaction.

What You'll See

An interactive particle field featuring:

  • Responsive Particles: Hundreds of particles that dynamically respond to cursor movement
  • Repulsion Physics: Realistic force-based particle displacement away from mouse position
  • Smooth Animations: Fluid particle movement with natural physics simulation
  • Interactive Feedback: Immediate visual response to user input
  • Performance Optimization: Efficient rendering of numerous moving particles

Technical Implementation

This experiment showcases particle system techniques:

  • Force-Based Physics: Mathematical force calculations for realistic repulsion behavior
  • Mouse Interaction: Real-time cursor tracking converted to 3D world coordinates
  • Particle Management: Efficient handling of hundreds of individual particle instances
  • Animation Loop: Smooth 60fps particle movement using optimized update cycles
  • Distance Calculations: Proximity detection for force application

Interactive Features

  • Real-Time Response: Instant particle reaction to mouse movement
  • Natural Physics: Believable force-based motion following physics principles
  • Smooth Transitions: Gradual particle movement creating organic flowing effects
  • Boundary Handling: Particles that respect scene boundaries and return to rest positions

This experiment perfectly demonstrates how interactive particle systems can create engaging user experiences, combining physics simulation with real-time user input for dynamic visual feedback.