Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@lonekorean
Last active June 10, 2018 22:56
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save lonekorean/469d11c86346476b7555f8035f820909 to your computer and use it in GitHub Desktop.
Save lonekorean/469d11c86346476b7555f8035f820909 to your computer and use it in GitHub Desktop.
Options for hex bokeh
options: {
canvasSelector: '', // to find <canvas> in DOM to draw on
radiusRange: [30, 60], // random range of body radii
xVarianceRange: [0.1, 0.3], // random range of x velocity scaling on bodies
yVarianceRange: [0.5, 1.5], // random range of y velocity scaling on bodies
airFriction: 0.03, // air friction of bodies
opacity: 0.5, // opacity of bodies
collisions: false, // do bodies collide or pass through
scrollVelocity: 0.025, // scaling of scroll delta to velocity applied to bodies
pixelsPerBody: 40000, // viewport pixels required for each body added
// colors to cycle through to fill bodies
colors: ['#7ef2cf', '#bea6ff', '#8ccdff']
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment