Security News
tea.xyz Spam Plagues npm and RubyGems Package Registries
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
vision-camera-dynamsoft-barcode-reader
Advanced tools
Readme
React Native Vision Camera Frame Processor Plugin of Dynamsoft Barcode Reader.
For vision-camera v2, use versions 0.x.
For vision-camera v3, use versions 1.x.
For vision-camera v4, use versions >= 2.0.0.
yarn add vision-camera-dynamsoft-barcode-reader
cd ios && pod install
Add the plugin to your babel.config.js
:
module.exports = {
plugins: [['react-native-worklets-core/plugin']],
// ...
Note: You have to restart metro-bundler for changes in the
babel.config.js
file to take effect.
Scan barcodes with vision camera.
import { decode } from 'vision-camera-dynamsoft-barcode-reader';
// ...
const frameProcessor = useFrameProcessor((frame) => {
'worklet';
const barcodes = decode(frame);
}, []);
Scan barcodes from a base64-encoded static image.
let results = await decodeBase64(base64);
License initialization (apply for a trial license).
await initLicense("your license");
TextResult:
TextResult{
barcodeText:string;
barcodeFormat:string;
barcodeBytesBase64:string;
x1:number;
x2:number;
x3:number;
x4:number;
y1:number;
y2:number;
y3:number;
y4:number;
}
Configuration:
DBRConfig{
template?:string;
license?:string;
isFront?:boolean;
rotateImage?:boolean;
}
isFront
and rotateImage
are Android-only. Since the natural camera sensor's orientation in Android is landscape, the camera image may be rotated for preview while the raw image we get is still not rotated. If we enable rotateImage
, the plugin will rotate the image automatically to match the camera preview. If it is disabled, the plugin will rotate the returned coordinates instead of the image which may have a slight performance gain. isFront
is needed for rotating the coordinates since the image of front camera is mirrored.
See the contributing guide to learn how to contribute to the repository and the development workflow.
MIT
FAQs
React Native Vision Camera Frame Processor Plugin of Dynamsoft Barcode Reader
The npm package vision-camera-dynamsoft-barcode-reader receives a total of 84 weekly downloads. As such, vision-camera-dynamsoft-barcode-reader popularity was classified as not popular.
We found that vision-camera-dynamsoft-barcode-reader demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Tea.xyz, a crypto project aimed at rewarding open source contributions, is once again facing backlash due to an influx of spam packages flooding public package registries.
Security News
As cyber threats become more autonomous, AI-powered defenses are crucial for businesses to stay ahead of attackers who can exploit software vulnerabilities at scale.
Security News
UnitedHealth Group disclosed that the ransomware attack on Change Healthcare compromised protected health information for millions in the U.S., with estimated costs to the company expected to reach $1 billion.