0.1.5 • Published 5 years ago

vue-low-poly v0.1.5

Weekly downloads
12
License
-
Repository
github
Last release
5 years ago

Vue-Low-Poly

An low-poly image generator component for Vue.js.

Installation

yarn

$ yarn add vue-low-poly

npm

$ npm install vue-low-poly

Using the component

<template>
 <div id="app">
  <vue-low-poly src="./sample.png"/>
 </div>
</template>

<script>
import VueLowPoly from "vue-low-poly";

export default {
  name: "App",
  data() {
    return {
    };
  },
  components: {
    VueLowPoly
  }
};
</script>

API

Attributes

Attr. NameDescriptionTypeDefault ValueAccepted Values
srcoriginal image's srcstring""-
widthimage width(px)number800-
heightimage height(px)number600-
pointsamount of points for trianglesnumber7500-
accuracyportion of points on the special postion(%)number75-
grayscalewhether output the image in grayscale stylebooleanfalsetrue/false