CloudyEMS / MetaBalls

MetaBalls glory in Unity3D

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

MetaBalls

An implementation Metaballs (a.k.a Blobs) inside Unity3D. Written as a shader for the Particle System to allow formore control and fun ;-)

Demo Glass Metaball

Demo

Demo scene included. As I didn't have time to make GUI, I included the following commands to interact with the demo.

Commands

  • RMB and move mouse to rotate camera.
  • Mouse Wheel to zoom in/out.
  • 1, 2, 3 to change between 3 shader varients.
  • q, w to change between 2 particle system.
  • a to change the speed of the particles between (0.5, 1, 2)
  • s to stop the particle system.
  • d to disable the noise effect of the particle system.
  • z, x, c to change the background.
  • v to stop the auto rotation of the camera

Usage

  1. Create a new Particle System and make sure it is set to Prewarm and the Max Particles are 10.
  2. Create a new material with one of the provided shaders.
  3. Add the material to the renderer component in the Particle System.
  4. Add the script MetaBalls.cs to the Particle System.
  5. Enjoy a mesmerizing effect.

TO DO

  • Further optimise the raymarching on the particles.
  • Write a main cginclude file to allow reusability and extensibility.
  • Further integrate the shader it can take colours directly from the Particle System.
  • Add support to Blend Probes.
  • Support huge amounts of particles. (Currently only support max of 10 particles)

Disclaimer

Skybox from http://pauldebevec.com/Probes/

About

MetaBalls glory in Unity3D


Languages

Language:GLSL 71.7%Language:C# 28.3%