class for camera device handling
More...
#import <MasCameraDevice.h>
class for camera device handling
◆ MasFlipDirection
Video data flip direction @constant HORIZONTAL Flip video horizontally @constant VERTICAL Flip video vertically.
Enumerator |
---|
HORIZONTAL | |
VERTICAL | |
◆ MasFocusMode
Camera focus mode @constant FOCUS_MODE_CONTINUOUS_AUTO Continuous focus mode. This focus mode is proper for AR @constant FOCUS_MODE_AUTO Scingle auto focus mode.
Enumerator |
---|
FOCUS_MODE_CONTINUOUS_AUTO | |
FOCUS_MODE_AUTO | |
◆ MasResultCode
Camera Open State @constant Success @constant CameraPermissionIsNotResolved @constant CameraDevicedRestriced @constant CameraPermissionIsNotGranted @constant CameraAlreadyOpened @constant TrackerAlreadyStarted @constant UnknownError.
Enumerator |
---|
Success | |
CameraPermissionIsNotResolved | |
CameraDevicedRestriced | |
CameraPermissionIsNotGranted | |
CameraAlreadyOpened | |
TrackerAlreadyStarted | |
UnknownError | |
◆ flipVideo:toggle:
Flip video.
- Parameters
-
direction | Flip direction |
toggle | true for set, false for reset |
◆ getBackgroundPlaneInfo
- (float *) getBackgroundPlaneInfo |
|
|
|
Get background scale info for background plane rendering.
- Returns
- scale value.
◆ getBackgroundPlaneProjectionMatrix
- (matrix_float4x4) getBackgroundPlaneProjectionMatrix |
|
|
|
Get projection matrix for background plane rendering.
- Returns
- 4x4 matrix (Column major)
◆ getCameraIntrinsic
- (NSString *) getCameraIntrinsic |
|
|
|
Get Camera Intrinsic.
- Returns
- {"width":width,"height":height,"fx":fx,"fy":fy,"px":px,"py":py} fx = focal length x, fy =focal length y, px = principal point x, py = principal point y
◆ getHeight
Get Camera Height.
- Returns
- camera preview height
◆ getMaxZoomValue
Get Camera Device Max Zoom value.
- Returns
- Max Zoom value.
◆ getProjectionMatrix
- (matrix_float4x4) getProjectionMatrix |
|
|
|
Get projection matrix. This is used for augmented objects projection and background rendering.
- Returns
- 4x4 matrix (Column major)
◆ getWidth
Get Camera Width.
- Returns
- camera preview width
◆ isFlipHorizontal
- (bool) isFlipHorizontal |
|
|
|
Check Screen is Horizontal.
- Returns
- return Horizontal value.
◆ isFlipVertical
Check Screen is Vertical.
- Returns
- return Vertical value.
◆ setAutoWhiteBalanceLock:
- (bool) setAutoWhiteBalanceLock: |
|
(bool) |
toggle |
|
Turn on/off auto white balance lock.
◆ setCalibrationData:
- (void) setCalibrationData: |
|
(NSString *) |
filePath |
|
Set Parameter Value.
- Parameters
-
filePath | Parameter file Path. |
◆ setClippingPlane:far:
- (void) setClippingPlane: |
|
(float) |
near |
far: |
|
(float) |
far |
|
|
| |
Set near, far plane.
- Parameters
-
near | near plane value |
far | far plane value |
◆ setFlashLightMode:
- (bool) setFlashLightMode: |
|
(bool) |
toggle |
|
◆ setFocusMode:
Set Camera Focus.
- Returns
- true if focus setting success
◆ setFusionEnable
Set up the fusion camera.
◆ setNewFrame:length:width:height:format:
- (void) setNewFrame: |
|
(Byte *) |
data |
length: |
|
(int) |
length |
width: |
|
(int) |
width |
height: |
|
(int) |
height |
format: |
|
(MasColorFormat) |
format |
|
|
| |
Set new image data for tracking and background rendering (Free, Enterprise license key can activate this interface)
- Parameters
-
data | image data bytes. |
length | image length |
width | image width |
height | image height |
format | image format |
◆ setNewFrameAndTimestamp:length:width:height:format:timestamp:
- (void) setNewFrameAndTimestamp: |
|
(Byte *) |
data |
length: |
|
(int) |
length |
width: |
|
(int) |
width |
height: |
|
(int) |
height |
format: |
|
(MasColorFormat) |
format |
timestamp: |
|
(unsigned long long int) |
timestamp |
|
|
| |
Set new image data for tracking and background rendering (Free, Enterprise license key can activate this interface)
- Parameters
-
data | image data bytes. |
length | image length |
width | image width |
height | image height |
format | image format |
timestamp | image timestamp |
◆ setZoom:
- (bool) setZoom: |
|
(float) |
zoomScale |
|
Set Camera Zoom Scale.
- Parameters
-
- Returns
- result Zoom.
◆ start:
◆ start:width:height:
Start camera preview.
- Parameters
-
cameraId | 0 is rear camera, 1 is face camera. camera index may depends on device. |
width | prefer camera width |
height | prefer camera height |
- Returns
- MasResultCode
◆ stop
The documentation for this class was generated from the following file: