Git Product home page Git Product logo

inkbox's Introduction

i n k b o x

This is an implementation of the fluid simulation system described in "Fast Fluid Dynamics Simulation on the GPU" by Mark J. Harris (a chapter in the book "GPU Gems"). I followed along with the chapter and implemented mostly the same system except using modern OpenGL and GLSL rather than the now-deprecated Cg framework. I've also written a 3D version of the system as well as a WebGL version of the 2D simulation. All three simulations have a UI that lets the user change the parameters of the equations.

2D C++ Simulation

  • A visual representation the velocity, pressure and vorticity fields is shown in the controls window
  • Each step of the solution to the equation can be toggled to see its effect on the fields
  • The constants that are used in the equation can all be modulated
  • Rainbow mode
  • "Droplets" mode

Usage

  • Click and drag to add ink and force
  • Use right-click and drag to only add force
  • Press 'p' key to toggle pause


3D C++ Simulation

  • Mostly functional but there's still a few kinks to work out
  • The constants that are used in the equation can all be modulated
  • Rainbow mode

Usage

  • Click and drag to add ink and force
  • Right-click and drag to rotate cube
  • Use WASD keys to rotate the cube
  • Press 'i' key to add ink at a random location
  • Press 'p' key to toggle pause


2D WebGL Simulation

  • Mostly a straightforward port of the C++ version
  • Hosted on github.io here

Usage

  • Click and drag to add ink and force

Source Material

Credits

inkbox's People

Contributors

bassicali avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.