|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CameraControl
CameraControl
controls the features of the camera device.
A Player
that plays captured stream from a camera
may provide a CameraControl
via its
getControl
and getControls
methods.
Field Summary | ||
---|---|---|
static int |
ROTATE_LEFT
Counter-clockwise rotation by 90 degrees. |
|
static int |
ROTATE_NONE
No rotation. |
|
static int |
ROTATE_RIGHT
Clockwise rotation by 90 degrees. |
|
static int |
UNKNOWN
Unknown value. |
Method Summary | ||
---|---|---|
void |
enableShutterFeedback(boolean enable)
Toggles the native shutter sound and visual shutter feedback on and off. |
|
int |
getCameraRotation()
Returns the rotation of the camera device. |
|
String |
getExposureMode()
Returns the current exposure mode of the camera device. |
|
int |
getStillResolution()
Gets the current still image resolution. |
|
String[] |
getSupportedExposureModes()
Returns a list of exposure modes supported by the camera device. |
|
int[] |
getSupportedStillResolutions()
Returns supported still image resolutions. |
|
int[] |
getSupportedVideoResolutions()
Returns supported video resolutions. |
|
int |
getVideoResolution()
Gets the current video resolution. |
|
boolean |
isShutterFeedbackEnabled()
Gets the setting of the native shutter feedback. |
|
void |
setExposureMode(String mode)
Sets the exposure mode of the camera device. |
|
void |
setStillResolution(int index)
Sets the still image resolution. |
|
void |
setVideoResolution(int index)
Sets the video resolution. |
Field Detail |
---|
static final int ROTATE_LEFT
static final int ROTATE_RIGHT
static final int ROTATE_NONE
static final int UNKNOWN
Method Detail |
---|
int getCameraRotation()
Returns the rotation of the camera device. There might be a sensor in the device that can sense the actual rotation of the camera device. Rotation refers to the direction the specific camera is pointing to.
void enableShutterFeedback(boolean enable) throws MediaException
enable
- true
to enable the shutter feedback,
false
to disable it
MediaException
- if setting of the shutter feedback is not
possible
SecurityException
- if setting of the shutter feedback is not
allowedboolean isShutterFeedbackEnabled()
true
if the shutter feedback is enabled,
false
if the shutter feedback is disabledString[] getSupportedExposureModes()
Returns a list of exposure modes supported by the camera device. Available exposure modes might include:
auto
(full automatic exposure setting)landscape
(daylight landscape)snow
(high light situation)beach
(high light situation)
night
fireworks
portrait
(human face in the center is the target)backlight
(target in center is essentially darker than the background)spotlight
(target in center is essentially brighter than the background)sports
(fast moving targets)text
(for copying texts and drawings, and for bar code reading)
ExposureControl
void setExposureMode(String mode)
A more fine-grained control of the exposure might be available
via ExposureControl
.
In that case, setting the preset exposure mode
here will propably cause a change in
the settings of the ExposureControl.
mode
- new exposure mode
IllegalArgumentException
- @see ExposureControl
if the mode
is not
among the supported exposure modesString getExposureMode()
int[] getSupportedVideoResolutions()
int[] getSupportedStillResolutions()
void setVideoResolution(int index)
index
- the index of the video resolution to be set.
Index 0 refers to the first pair returned by
CameraControl.getSupportedVideoResolutions()
and index 1
refers to the second pair and so on.
IllegalArgumentException
- if the given resolution is
not supported.
IllegalStateException
- if changing resolution is not supported during recording or playback.void setStillResolution(int index)
index
- the index of the video resolution to be set.
Index 0 refers to the first pair returned by
CameraControl.getSupportedStillResolutions()
and index 1
refers to the second pair and so on.
IllegalArgumentException
- if the given resolution is
not supportedint getVideoResolution()
CameraControl.getSupportedVideoResolutions()
and index 1 refers to the second
pair and so on. Returns -1 if no video resolutions are supported.int getStillResolution()
CameraControl.getSupportedStillResolutions()
and index 1 refers to the second
pair and so on. Returns -1 if no still resolutions are supported.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Copyright 1999-2011 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Java is a trademark of Oracle America Inc. in the US and other countries.
Legal