Skip to content

Instantly share code, notes, and snippets.

@sasaki-shigeo
Last active January 6, 2019 08:10
Show Gist options
  • Save sasaki-shigeo/d5423e6576a2780b2c2946c0e0246699 to your computer and use it in GitHub Desktop.
Save sasaki-shigeo/d5423e6576a2780b2c2946c0e0246699 to your computer and use it in GitHub Desktop.
The color type in Processing is exactly binary integer.
color transparent = color(0, 0, 0, 0);
color opaque = color(0, 0, 0, 255);
println(transparent); // 0
println(opaque); // 0xff000000
println(#000000 - opaque); // 0
println(#0000ff - opaque); // 0xff
println(#ffffff - opaque); // 0xffffff
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment