2.0.0 • Published 5 months ago

binary-effect v2.0.0

Weekly downloads
-
License
MIT
Repository
github
Last release
5 months ago

Binary Effect

Transform your images into stunning binary art with ease using a customized canvas element. Whether you're looking to add a unique touch to your website or create captivating visuals for your projects, this customized canvas converts images into striking binary representations.

Demo: Binary Effect

Usage

<canvas is="binary-effect">
  <script>
    Object.assign(document.currentScript.parentElement, {
      imageSrc: 'logo.png',
      charactersSrc: 'characters.png',
      smoothness: 0.2,
      characterScaling: 0.35,
      duration: 4000,
      delay: 1000,
    });
  </script>
</canvas>

<script type="module">
  import { createBinaryEffect } from 'binary-effect';

  const canvas = document.querySelector('canvas');
  const effect = await createBinaryEffect(canvas, {
    imageSrc: 'vite.svg',
    charactersSrc: 'characters.png',
    smoothness: 0.2,
    characterScaling: 0.5,
    duration: 4000,
  });

  effect.run();
</script>
2.0.0

5 months ago

1.0.2

11 months ago

1.0.1

1 year ago

1.0.0

1 year ago