Skip to content
/ pixasso Public

Simple JavaScript library for browsers to pixelate images with customizations

License

Notifications You must be signed in to change notification settings

howion/pixasso

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

pixasso

Javascript library for browsers to generate pixel arts from images with custom pixel size, zoom and color pick mode.

Usage

Download and include pixasso.min.js

<script src="pixasso.min.js"></script>
var img = document.createElement('img');
// img.src = ''

var options = {
  pixSize: 10, // pixSize > 0
  zoom: 10,    // zoom    > 0
  colorPickMode: pixasso.colorPickMode.JointColor // OR pixasso.colorPickMode.FirstColor
};

pixasso.createPixelArt(img, options.pixSize, options.zoom, options.colorPickMode);
//-> <img>

Example

Related

License

MIT