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.
@haseeamarathunga/face-detect
Advanced tools
[![npm (scoped)](https://img.shields.io/npm/v/@bamblehorse/tiny.svg)](https://www.npmjs.com/package/@haseeamarathunga/face-detect) [![npm bundle size (minified)](https://img.shields.io/bundlephobia/min/@bamblehorse/tiny.svg)](https://www.npmjs.com/package
Readme
Faces and Iris detection using web-cam
You must install ngx-webcam and ng-open-cv libraries.
^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0
^5.0.0 || ^6.0.0
npm install --save ngx-webcam
npm install ng-open-cv
npm install @haseeamarathunga/face-detect
FaceDetectModule
into your Angular module:import {FaceDetectModule} from '@haseeamarathunga/face-detect';
import {NgOpenCVModule, OpenCVOptions} from 'ng-open-cv';
import {WebcamModule} from 'ngx-webcam';
@NgModule({
imports: [
NgOpenCVModule,
WebcamModule,
FaceDetectModule,
...
],
...
})
export class AppModule { }
FaceDetectComponent
on your pages:In .html file
<face-detect [width]="500" [height]="380" [triggerFace]="triggerObservable"
(imageCapture)="viewChange($event)"></face-detect>
<button class="button" (click)="triggerSnapshot();">Detect Face</button>
In .ts file
private trigger: Subject<void> = new Subject<void>();
public triggerSnapshot(): void {
this.trigger.next();
}
public get triggerObservable(): Observable<void> {
return this.trigger.asObservable();
}
viewChange(event) {
console.log(event);
this.fullFace = event.fullImage;
this.face = event.face;
this.eyeRight = event.eyeRight;
this.eyeLeft = event.eyeLeft;
}
This section describes the basic inputs/outputs of the component. All inputs are optional.
triggerFace: Observable<void>
: An Observable
to trigger image capturing. When it fires, an image will be captured and emitted (see Outputs).width: number
: The maximal video width of the webcam live view.height: number
: The maximal video height of the webcam live view. The actual view will be placed within these boundaries, respecting the aspect ratio of the video stream.imageCapture: EventEmitter<any>
: Whenever an image is captured it return the event object that include fullImage, Face, eyeLeft and eyeRight. viewChange(event) {
console.log(event);
this.fullFace = event.fullImage;
this.face = event.face;
this.eyeRight = event.eyeRight;
this.eyeLeft = event.eyeLeft;
}
Here you can find instructions on how to start developing this library.
Run npm run packagr
to build the library. The build artifacts will be stored in the dist/
directory.
Run npm start
to build and run the surrounding webapp with the FaceDetectModule
. Essential for live-developing.
Run npm run docs
to generate the live-demo documentation pages in the docs/
directory.
Run npm run test
to run unit-tests.
FAQs
[![npm (scoped)](https://img.shields.io/npm/v/@bamblehorse/tiny.svg)](https://www.npmjs.com/package/@haseeamarathunga/face-detect) [![npm bundle size (minified)](https://img.shields.io/bundlephobia/min/@bamblehorse/tiny.svg)](https://www.npmjs.com/package
The npm package @haseeamarathunga/face-detect receives a total of 3 weekly downloads. As such, @haseeamarathunga/face-detect popularity was classified as not popular.
We found that @haseeamarathunga/face-detect demonstrated a not healthy version release cadence and project activity because the last version was released 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.