A customizable particle simulation engine built with Pygame.
-
Particle Types:
- Circle
- Snow
- Leaves
- Steam
- Firefly
- Rain
- Sakura
- Vortex
-
Customizable Properties:
- Color selection via color picker
- Particle size (min/max)
- Movement speed (min/max)
- Fade speed (min/max)
- Particle multiplier for density control
-
Animation Sequence Mode:
- Process video files to create particle animations
- Convert video frames to particle coordinates
- Synchronized audio playback
- Mini player display during playback
- Space Bar: Toggle video playback (first time will load the video before playing)
- C Key: Clear all particles
- Mouse Click: Remove particles at cursor position
- Bad Apple Animation

- Circle Particle

- Firefly Particle

- Leaves Particle

- Rain Particle

- Sakura Particle

- Snow Particle

- Steam Particle

- Vortex Particle

-
When you first load a video:
- The application extracts frames from the video
- Each frame is converted to grayscale and resized
- Frames are saved as images in the
assets/images/directory - Image pixels are analyzed to extract coordinate data
- Coordinate data is saved in the
coordinates/directory as NumPy files
-
During video playback:
- The application loads coordinate data from files
- Coordinates are used to position particles on screen
- Audio is synchronized with particle animations
- A mini player shows the original video in the corner
I know this might sounds ineffecient and performance heavy (it is). But i don't really care because this was made when i still learning how to code. In fact, i'm quite proud with how it turned out
- Clone this repository:
git clone https://github.com/Rigelyon/ParticleSimulation.git
cd ParticleSimulation
- Install dependencies:
pip install -r requirements.txt
- Run the application:
python main.py
Feel free to contribute by creating a pull request
This project is licensed under the MIT License