react-native-pixel-bmp
v1.0.3
Published
Parse Bitmap to ImageData for React Native
Downloads
48
Maintainers
Readme
react-native-pixel-bmp
Parse Bitmap to ImageData for React Native.
Installation
$ npm install react-native-pixel-bmp
For RN >= 0.65, run npm install react-native-blob-util
.
For RN < 0.65, run npm install [email protected]
, and patch manually to fix: with react-native-web product build will export 'URIUtil' (reexported as 'URIUtil') was not found.
var pixelBitmap = require('react-native-pixel-bmp');
console.log(pixelBitmap); // object
API
pixelBitmap.parse(file
) -> promise.then(images
)
return images
is Array contains one ImageData
.
var file = 'https://59naga.github.io/fixtures/still.BMP';
pixelBitmap.parse(file).then(function(images){
console.log(images[0]);
});
// {width: 128, height: 128, bitPP: 24, bottomUp: true, compression: 0, headerSize: 40, data: <Uint8Array ..>}
Related projects
- react-native-pixel-image
- react-native-pixel-util
- react-native-pixel-gif
- react-native-pixel-png
- react-native-pixel-jpg
- react-native-pixel-bmp
- react-native-pixel-webp
- pixel-to-ansi
- pixel-to-svg