-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathrm.hbs
64 lines (45 loc) · 1.89 KB
/
rm.hbs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
[](https://www.npmjs.org/package/@uttori/image-png)
[](https://www.npmjs.org/package/@uttori/image-png)
[](https://travis-ci.com/uttori/uttori-image-png)
[](https://david-dm.org/uttori/uttori-image-png)
[](https://coveralls.io/github/uttori/uttori-image-png?branch=master)
[](https://bundlephobia.com/result?p=@uttori/image-png)
[](https://bundlephobia.com/result?p=@uttori/image-png)
[](https://bundlephobia.com/result?p=@uttori/image-png)
[](https://bundlephobia.com/result?p=@uttori/image-png)
# Uttori ImagePNG
A PNG Decoder and meta data reading utility.
## Install
```bash
npm install --save @uttori/image-png
```
# Config
```js
{
}
```
* * *
# Example
```js
const image_data = await FileUtility.readFile('./test/assets/PngSuite', 'oi1n0g16', 'png', null);
const image = ImagePNG.fromFile(image_data);
image.decodePixels();
const length = image.pixels.length;
➜ 6144
const pixel = image.getPixel(0, 0);
➜ [255, 255, 255, 255]
```
# API Reference
{{>main}}
* * *
## Tests
To run the test suite, first install the dependencies, then run `npm test`:
```bash
npm install
npm test
DEBUG=Uttori* npm test
```
## Contributors
* [Matthew Callis](https://github.com/MatthewCallis)
## License
* [MIT](LICENSE)