# get-image-data

> isomorphic image data extraction

Latest version **5.0.0** (published 2020-07-21) · CC0-1.0 license · 0 weekly downloads

## Install

```sh
npm install get-image-data
pnpm add get-image-data
yarn add get-image-data
bun add get-image-data
```

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 5.0.0 |
| Published | 2020-07-21 |
| First published | 2013-10-30 |
| Weekly downloads | 0 |
| License | CC0-1.0 |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 0 |
| Unpacked size | 2.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Michael Rhodes |
| Maintainers | michaelrhodes |

## Links

- npm: https://www.npmjs.com/package/get-image-data
- npm.io page: https://npm.io/package/get-image-data

## Recent versions

- 5.0.0 (latest) — 2020-07-21
- 4.1.0 — 2019-02-11
- 4.0.0 — 2019-02-05
- 3.0.1 — 2017-01-16
- 3.0.0 — 2017-01-16
- 2.2.2 — 2017-01-16
- 2.2.1 — 2015-12-19
- 2.2.0 — 2014-12-10
- 2.1.0 — 2014-08-22
- 2.0.0 — 2014-03-06
- 1.0.1 — 2013-11-08
- 1.0.0 — 2013-10-30
- 0.0.1 — 2013-10-30
- 0.0.0 — 2013-10-30

## README

# get-image-data
isomorphic image data extraction

[![ci](https://travis-ci.org/michaelrhodes/get-image-data.svg?branch=master)](https://travis-ci.org/michaelrhodes/get-image-data)

## install
``` sh
npm install michaelrhodes/get-image-data#5.0.0 [jimp] [sharp]
```

## use
``` js
// Extract data with canvas element or `jimp`
var image = require('get-image-data')

image('./image.jpg', function (err, info) {
  var data = info.data
  var height = info.height
  var width = info.width

  for (var i = 0, l = data.length; i < l; i += 4) {
    var red = data[i]
    var green = data[i + 1]
    var blue = data[i + 2]
    var alpha = data[i + 3]
  }
})

// Extract data with `sharp` (faster)
var image = require('get-image-data/native')
```

## obey
[CC0-1.0](https://creativecommons.org/publicdomain/zero/1.0/)

---
_Source: https://npm.io/package/get-image-data · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
