Table Of Contents

Previous topic

CameraDeviceType Enum

Next topic

CloudRecognizer Class

CameraFrameStreamer Class

Inherits: FrameStreamer

Description

FrameStreamer gets data from CameraDevice and generates frame to feed filters.

If you are looking for a customizable frame feeder to use your own video source, it is not available yet in the latest EasyAR SDK, but will be available as subclass of FrameStreamer in some later releases.

Constructor

C: void easyar_CameraFrameStreamer__ctor(easyar_CameraFrameStreamer** Return)
C++11: CameraFrameStreamer()
Traditional C++: CameraFrameStreamer()
Java: public CameraFrameStreamer()
Objective-C: + (easyar_CameraFrameStreamer *) create
Swift (since EasyAR SDK 2.1.0): public convenience init()

attachCamera

Attach CameraDevice to the streamer. Streamer will not start to streaming until a CameraDevice is attached.

Attach null object will detach previous attached CameraDevice from tracker.

C: bool easyar_CameraFrameStreamer_attachCamera(easyar_CameraFrameStreamer* This, easyar_CameraDevice* obj)
C++11: bool attachCamera(std::shared_ptr<CameraDevice> obj)
Traditional C++: bool attachCamera(CameraDevice* obj)
Java: public native boolean attachCamera(CameraDevice obj)
Objective-C: - (bool)attachCamera:(easyar_CameraDevice *)obj
Swift (since EasyAR SDK 2.1.0): public func attachCamera(_ obj: CameraDevice?) -> Bool

peek

Peek the latest frame from streamer.

C: void easyar_CameraFrameStreamer_peek(easyar_CameraFrameStreamer* This, easyar_Frame** Return)
C++11: std::shared_ptr<Frame> peek()
Traditional C++: void peek(Frame** Return)
Java: public native Frame peek()
Objective-C: - (easyar_Frame *)peek
Swift (since EasyAR SDK 2.1.0): public override func peek() -> Frame

start

Start to streaming frames.

C: bool easyar_CameraFrameStreamer_start(easyar_CameraFrameStreamer* This)
C++11: bool start()
Traditional C++: bool start()
Java: public native boolean start()
Objective-C: - (bool)start
Swift (since EasyAR SDK 2.1.0): public override func start() -> Bool

stop

Stop streaming.

C: bool easyar_CameraFrameStreamer_stop(easyar_CameraFrameStreamer* This)
C++11: bool stop()
Traditional C++: bool stop()
Java: public native boolean stop()
Objective-C: - (bool)stop
Swift (since EasyAR SDK 2.1.0): public override func stop() -> Bool