lmbaeza / p5.quadrille.js

Home Page:https://objetos.github.io/p5.quadrille.js/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

p5.quadrille.js

p5.js quadrille library.

In geometry, the square-tiling, square-tessellation or square-grid is a regular tiling of the Euclidean plane. John Horton Conway called it a quadrille.

The internal angle of the square is 90 degrees so four squares at a point make a full 360 degrees. It is one of three regular tilings of the plane. The other two are the triangular-tiling and the hexagonal-tiling.

The library comprises a Quadrille class and provides the createQuadrille and drawQuadrille p5 functions. Quadrille implements geometry transformation and constructive solid geometry-like logical operators, and visual computing methods such as image filtering using convolution matrices and triangle rasterization. It also implements several memory management methods, such as clear, clone, fill, insert, replace and sort. It can be used as an interface to convert to / from other representations such as arrays, images and bitboards.

The library reference and some examples are found at the library site.

Installation

Link the p5.quadrille.js library into your HTML file, after you have linked in p5.js. For example:

<!doctype html>
<html>
<head>
  <script src="p5.js"></script>
  <script src="p5.sound.js"></script>
  <script src=https://cdn.jsdelivr.net/gh/objetos/p5.quadrille.js/p5.quadrille.js></script>
  <script src="sketch.js"></script>
</head>
<body>
</body>
</html>

to include its minified version use:

<script src=https://cdn.jsdelivr.net/gh/objetos/p5.quadrille.js/p5.quadrille.min.js></script>

instead.

vs-code & vs-codium & gitpod hacking instructions

To run and hack the testing examples:

  1. Clone the repo (git clone https://github.com/objetos/p5.quadrille.js) and open it with your favorite editor.
  2. Install the p5-vscode extension.
  3. Head over examples/*/index.html and press your editor Go Live button.

About

https://objetos.github.io/p5.quadrille.js/


Languages

Language:JavaScript 100.0%