Skip to content

Instantly share code, notes, and snippets.

@SpiffGreen
Created April 28, 2022 06:46
Show Gist options
  • Save SpiffGreen/1dbbf1d53f320132c61e85e78eb1f1ba to your computer and use it in GitHub Desktop.
Save SpiffGreen/1dbbf1d53f320132c61e85e78eb1f1ba to your computer and use it in GitHub Desktop.
Image pixel manipulation
/*
* @description An image to ascii text conversion library
*/
class ImageToAscii {
constructor(image) {
this.image = image;
this.toText = this.toText.bind(this);
}
#toGrayScale() {}
#resize() {}
toText() {}
}
const imgToText = new ImageToAscii(img);
const text = imgToText.toText();
console.log(text)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment