Admdebian
Admdebian

Reputation: 660

NativeScript How can I redirect camera stream to HTML Canvas?

I know there are native scripts modules for camera capture and barcode scanning.

I'm looking for something different: I need to redirect camera input to an HTML canvas (live).

Google Chrome supports this feature but Apple products don't

Upvotes: 0

Views: 670

Answers (1)

Nick Iliev
Nick Iliev

Reputation: 9670

Currently, there is no developed NativeScript plugin for streaming from Android camera, However, you can develop your own plugin using an Android library like libstreaming

libstreaming is an API that allows you, with only a few lines of code, to stream the camera and/or microphone of an android powered device using RTP over UDP.

Android 4.0 or more recent is required. Supported encoders include H.264, H.263, AAC and AMR.

Nice API reference is available here

More about how to develop your plugin in NativeScript ca be found here Also, you might want to have some knowledge of marshalling (data conversion) in NativeScript

Upvotes: 1

Related Questions