Skip to content

Latest commit

 

History

History
136 lines (124 loc) · 5.44 KB

README.md

File metadata and controls

136 lines (124 loc) · 5.44 KB

opencv_js_sample

Contents

All the follow projects used vite, so please install with npm if you would like to download and use these projects.

versions

  • Node.js: 20.12.2
  • npm: 10.8.2
  • vite: 5.3.4

Import and build

  • Build infomation of opencv.js - 0101buildinfo/
    (note) no check npm run build only npm run dev.
  • The list of functions in opencv.js - 0102functions/
    (note) no check npm run build only npm run dev.
  • The list of consts of opencv.js - 0103consts/
    (note) no check npm run build only npm run dev.

Image

  • Examing the structure of an image - 0201metadata/
    (note) no check npm run build only npm run dev.
  • Copy canvas - 0202copycanvas/
    (note) no check npm run build only npm run dev.
  • Pick pixel color - 0203pickpixelcolor/
    (note) no check npm run build only npm run dev.
  • Draw a circle in monochrome - 0204drawcircle/
    (note) no check npm run build only npm run dev.
  • Draw a circle with floating point numbers - 0205drawcircle32/
    (note) no check npm run build only npm run dev.
  • Draw Tool - 0206drawtool/
  • Region of Interest - 0207roi/

Video processing

  • Composite video frames and images - 0301addimage/
  • Camera Flip - 0302cameraflip/
  • Video Miniture - 0303miniture/
  • Video Transitions - 0304transition/
  • Video Mog2 - 0305mog2/
  • Video Opticalflow - 0306opticalflow/

Image processing

  • Image Resize / Mosaic / All - 0401imageresize/
    • (note) no check npm run build only npm run dev.
  • Image Resize / Mosaic / A part - 0402imageresize2/
  • Image Blur - 0403imageblur/
  • Image Resize / Mosaic / A part - 0404imageedge/
  • Image Resize / Mosaic / A part - 0405imageedgeanime/
  • Detect QR Code - 0406qr/
  • Erase Powerlines - 0407morph/
  • Tilt correct - 0408hough/
  • Detect Faces - 0409face/
  • Compose Images - 0410compose/

Color

  • Monochrome color - 0501grayscale/
  • Color Invert - 0502invert/
  • Sepia Color - 0503sepia/
  • Analyze RGB color - 0504rgb/
  • Change Background - 0505background/
    • (note) no check npm run build only npm run dev.
  • White and Black - 0506binary/
  • Color Hue - 0507hue/
  • Color Posterize - 0508poster/

Download and Install

  • OpenCV.js Library download
    • move to the link.
    • download latest version in the page.
    • Extract the zip file you downloaded.
    • Copy opencv.js file in the folder you extract and paste to your work directory.
    • {note} The opencv.js file is not ES Module compatible. You need to customize it a bit to make it ES Module compatible. opencv.js file in this repository is already ES Module compatible.

Build

  • develop / localserver
npm run dev
  • production build
npm run build

After build, upload all files in the dist directory to your host server with FTP and so on.

Functions

Reference page

Reference