class for camera device handling
More...
#include <CameraDevice.h>
|
| | CameraDevice () |
| |
| virtual | ~CameraDevice () |
| |
| virtual ResultCode | start (int cameraId, int width, int height)=0 |
| | Start camera preview. More...
|
| |
| virtual void | stop ()=0 |
| | Stop camera preview. More...
|
| |
| virtual int | getWidth ()=0 |
| |
| virtual int | getHeight ()=0 |
| |
| virtual bool | setFocusMode (FocusMode mode)=0 |
| |
| virtual bool | setFlashLightMode (bool toggle)=0 |
| | Turn on/off flash light. More...
|
| |
| virtual bool | setAutoWhiteBalanceLock (bool toggle)=0 |
| | Turn on/off auto white balance lock. More...
|
| |
| virtual void | flipVideo (CameraDevice::FlipDirection direction, bool toggle)=0 |
| | Flip video. More...
|
| |
| virtual std::list< std::string > | getParamList ()=0 |
| | Get supported parameter key list. More...
|
| |
| virtual bool | setParam (std::string key, bool toggle)=0 |
| | Set camera parameter (Android only supported now) More...
|
| |
| virtual bool | setParam (std::string key, int value)=0 |
| | Set camera parameter (Android only supported now) More...
|
| |
| virtual bool | setParam (std::string key, int min, int max)=0 |
| | Set camera parameter (Android only supported now) More...
|
| |
| virtual bool | setParam (std::string key, std::string value)=0 |
| | Set camera parameter (Android only supported now) More...
|
| |
| virtual void | setNewFrame (Byte *data, int length, int width, int height, ColorFormat format)=0 |
| | Set new image data for tracking and background rendering (Only enterprise license key can activate this interface) More...
|
| |
| virtual float * | getProjectionMatrix ()=0 |
| | Get projection matrix. This is used for augmented objects projection and background rendering. More...
|
| |
| virtual const float * | getBackgroundPlaneProjectionMatrix ()=0 |
| | Get projection matrix for background plane rendering. More...
|
| |
class for camera device handling
◆ FlipDirection
Video data flip direction.
| Enumerator |
|---|
| HORIZONTAL | |
| VERTICAL | |
◆ FocusMode
Camera focus mode.
| Enumerator |
|---|
| FOCUS_MODE_CONTINUOUS_AUTO | |
| FOCUS_MODE_AUTO | |
◆ CameraDevice()
| maxstAR::CameraDevice::CameraDevice |
( |
| ) |
|
|
inline |
◆ ~CameraDevice()
| virtual maxstAR::CameraDevice::~CameraDevice |
( |
| ) |
|
|
inlinevirtual |
◆ flipVideo()
Flip video.
- Parameters
-
| direction | Flip direction |
| toggle | true for set, false for reset |
◆ getBackgroundPlaneProjectionMatrix()
| virtual const float* maxstAR::CameraDevice::getBackgroundPlaneProjectionMatrix |
( |
| ) |
|
|
pure virtual |
Get projection matrix for background plane rendering.
- Returns
- 4x4 gl matrix (Column major)
◆ getHeight()
| virtual int maxstAR::CameraDevice::getHeight |
( |
| ) |
|
|
pure virtual |
- Returns
- camera preview height
◆ getInstance()
◆ getParamList()
| virtual std::list<std::string> maxstAR::CameraDevice::getParamList |
( |
| ) |
|
|
pure virtual |
Get supported parameter key list.
- Returns
- Parameter key list
◆ getProjectionMatrix()
| virtual float* maxstAR::CameraDevice::getProjectionMatrix |
( |
| ) |
|
|
pure virtual |
Get projection matrix. This is used for augmented objects projection and background rendering.
- Returns
- 4x4 gl matrix (Column major)
◆ getWidth()
| virtual int maxstAR::CameraDevice::getWidth |
( |
| ) |
|
|
pure virtual |
- Returns
- camera preview width
◆ setAutoWhiteBalanceLock()
| virtual bool maxstAR::CameraDevice::setAutoWhiteBalanceLock |
( |
bool |
toggle | ) |
|
|
pure virtual |
Turn on/off auto white balance lock.
◆ setFlashLightMode()
| virtual bool maxstAR::CameraDevice::setFlashLightMode |
( |
bool |
toggle | ) |
|
|
pure virtual |
◆ setFocusMode()
| virtual bool maxstAR::CameraDevice::setFocusMode |
( |
FocusMode |
mode | ) |
|
|
pure virtual |
- Returns
- true if focus setting success
◆ setNewFrame()
| virtual void maxstAR::CameraDevice::setNewFrame |
( |
Byte * |
data, |
|
|
int |
length, |
|
|
int |
width, |
|
|
int |
height, |
|
|
ColorFormat |
format |
|
) |
| |
|
pure virtual |
Set new image data for tracking and background rendering (Only enterprise license key can activate this interface)
- Parameters
-
| data | image data bytes. |
| length | image length |
| width | image width |
| height | image height |
| format | image format |
◆ setParam() [1/4]
| virtual bool maxstAR::CameraDevice::setParam |
( |
std::string |
key, |
|
|
bool |
toggle |
|
) |
| |
|
pure virtual |
Set camera parameter (Android only supported now)
- Parameters
-
| key | Parameter key |
| toggle | Parameter value |
- Returns
- True if setting success
◆ setParam() [2/4]
| virtual bool maxstAR::CameraDevice::setParam |
( |
std::string |
key, |
|
|
int |
value |
|
) |
| |
|
pure virtual |
Set camera parameter (Android only supported now)
- Parameters
-
| key | Parameter key |
| value | Parameter value |
- Returns
- True if setting success
◆ setParam() [3/4]
| virtual bool maxstAR::CameraDevice::setParam |
( |
std::string |
key, |
|
|
int |
min, |
|
|
int |
max |
|
) |
| |
|
pure virtual |
Set camera parameter (Android only supported now)
- Parameters
-
| key | Parameter key |
| min | Parameter min value |
| max | Parameter max value |
- Returns
- True if setting success
◆ setParam() [4/4]
| virtual bool maxstAR::CameraDevice::setParam |
( |
std::string |
key, |
|
|
std::string |
value |
|
) |
| |
|
pure virtual |
Set camera parameter (Android only supported now)
- Parameters
-
| key | Parameter key |
| value | Parameter value |
- Returns
- True if setting success
◆ start()
| virtual ResultCode maxstAR::CameraDevice::start |
( |
int |
cameraId, |
|
|
int |
width, |
|
|
int |
height |
|
) |
| |
|
pure virtual |
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
- 0 : camera open success others : camera open fails
◆ stop()
| virtual void maxstAR::CameraDevice::stop |
( |
| ) |
|
|
pure virtual |
The documentation for this class was generated from the following file: