class CCamera::CCameraOverlay : public CBase |
This class provides support for image overlays. The client can use it to overlay an image onto the viewfinder, snapshots, still images and video. A client can create multiple overlays, where each overlay can be in a different format. The properties of an overlay can be changed after it has been created.
This class provides a standardised client interface for the camera overlay. Classes cannot be derived from it.
If the class methods leave, the output type parameter value is not guaranteed to be valid.
Public Member Functions | |
---|---|
~CCameraOverlay() | |
IMPORT_C TUint | CreateOverlayL(const TOverlayParameters &, CFbsBitmap *) |
IMPORT_C void | GetAllOverlaysInZOrderL(RArray< TUint > &) |
IMPORT_C void | GetAllOverlaysInZOrderL(TOverlayCameraMode, TInt, RArray< TUint > &) |
IMPORT_C void | GetOverlayBitmapL(TUint, CFbsBitmap *) |
IMPORT_C void | GetOverlayParametersL(TUint, TOverlayParameters &) |
IMPORT_C void | GetOverlaySupport(TOverlaySupportInfo &) |
IMPORT_C CCameraOverlay * | NewL(CCamera &) |
IMPORT_C void | ReleaseOverlay(TUint) |
IMPORT_C void | SetAllOverlaysInZOrderL(const RArray< TUint > &) |
IMPORT_C void | SetAllOverlaysInZOrderL(TOverlayCameraMode, TInt, const RArray< TUint > &) |
IMPORT_C void | SetModifiableOverlayBitmapL(TUint, CFbsBitmap *) |
IMPORT_C void | SetOverlayBitmapL(TUint, const CFbsBitmap *) |
IMPORT_C void | SetOverlayParametersL(TUint, const TOverlayParameters &) |
Private Member Functions | |
---|---|
CCameraOverlay(CCamera &) | |
void | ConstructL() |
Public Member Enumerations | |
---|---|
enum | TBlendingType { EBlendNone, EBinary, EFullRange, EBinaryDynamic, EFullRangeDynamic } |
enum | TOverlayCameraMode { EModeNone = 0x00, EModeStillImage = 0x01, EModeSnapshot = 0x02, EModeViewfinder = 0x04, EModeVideo = 0x08, EModeDirectViewfinder = 0x00010, EModeClientViewfinder = 0x00020, EModeStillImageContinuous = 0x00080, EModeStillImageBracket = 0x00100, EModeStillImageBracketMerge = 0x00200, EModeStillImageTimed = 0x00400, EModeStillImageTimeLapse = 0x00800, EModeStillImageBurst = 0x01000 } |
enum | TOverlayType { EOverlayNone = 0x00, EPerPixel = 0x01, EPerPlane = 0x02 } |
Private Attributes | |
---|---|
MCameraOverlay * | iImpl |
MCameraOverlay2 * | iImpl2 |
CCamera & | iOwner |
IMPORT_C TUint | CreateOverlayL | ( | const TOverlayParameters & | aParameters, |
CFbsBitmap * | aBitmap | |||
) |
const TOverlayParameters & aParameters | |
CFbsBitmap * aBitmap |
IMPORT_C void | GetAllOverlaysInZOrderL | ( | RArray< TUint > & | aOverlayHandles | ) |
IMPORT_C void | GetAllOverlaysInZOrderL | ( | TOverlayCameraMode | aOverlayCameraMode, |
TInt | aViewFinderHandle, | |||
RArray< TUint > & | aOverlayHandles | |||
) | const |
TOverlayCameraMode aOverlayCameraMode | |
TInt aViewFinderHandle | |
RArray< TUint > & aOverlayHandles |
IMPORT_C void | GetOverlayBitmapL | ( | TUint | aOverlayHandle, |
CFbsBitmap * | aBitmap | |||
) |
TUint aOverlayHandle | |
CFbsBitmap * aBitmap |
IMPORT_C void | GetOverlayParametersL | ( | TUint | aOverlayHandle, |
TOverlayParameters & | aInfo | |||
) |
TUint aOverlayHandle | |
TOverlayParameters & aInfo |
IMPORT_C void | GetOverlaySupport | ( | TOverlaySupportInfo & | aInfo | ) |
TOverlaySupportInfo & aInfo |
IMPORT_C void | ReleaseOverlay | ( | TUint | aOverlayHandle | ) |
TUint aOverlayHandle |
IMPORT_C void | SetAllOverlaysInZOrderL | ( | const RArray< TUint > & | aOverlayHandles | ) |
IMPORT_C void | SetAllOverlaysInZOrderL | ( | TOverlayCameraMode | aOverlayCameraMode, |
TInt | aViewFinderHandle, | |||
const RArray< TUint > & | aOverlayHandles | |||
) |
TOverlayCameraMode aOverlayCameraMode | |
TInt aViewFinderHandle | |
const RArray< TUint > & aOverlayHandles |
IMPORT_C void | SetModifiableOverlayBitmapL | ( | TUint | aOverlayHandle, |
CFbsBitmap * | aBitmap | |||
) |
TUint aOverlayHandle | |
CFbsBitmap * aBitmap |
IMPORT_C void | SetOverlayBitmapL | ( | TUint | aOverlayHandle, |
const CFbsBitmap * | aBitmap | |||
) |
TUint aOverlayHandle | |
const CFbsBitmap * aBitmap |
IMPORT_C void | SetOverlayParametersL | ( | TUint | aOverlayHandle, |
const TOverlayParameters & | aParameters | |||
) |
TUint aOverlayHandle | |
const TOverlayParameters & aParameters |
Blending types
Type of supported blending.
EBlendNone |
Does not support blending. |
EBinary |
Supports only binary blending. If alpha value is 0xFF, it is opaque, otherwise transparent. |
EFullRange |
Full support for blending - all values in the range [0:255]. |
EBinaryDynamic |
Supports only dynamic binary blending - allows values to be changed when overlay is being displayed. If alpha value is 0xFF, it is opaque, otherwise transparent. Since the blending is dynamic, SetModifiableOverlayBitmapL shall be used such that the bitmap could be changed by the implementation. |
EFullRangeDynamic |
Full support for dynamic blending - all values in the range [0:255]
|
Overlay camera mode types
Represents the possible camera modes in which the overlay could be used. Several types can be combined when returning ECam implementation support for various modes.
EModeNone = 0x00 |
Overlays are not supported for any camera mode. |
EModeStillImage = 0x01 |
The image can be overlaid on captured images. The camera is in still image mode. This effectively means all the still image drive modes and its interpretation may be implementation-specific. Explicit definition of drive modes is recommended instead. |
EModeSnapshot = 0x02 |
The image can be overlaid on a snapshot. The camera has snapshot functionality set on. |
EModeViewfinder = 0x04 |
The image can be overlaid on a viewfinder. The camera is displaying directly to viewfinder. This mode shall not be used if any of the viewfinder submodes is specified.
Note:
Overlay visibility for different viewfinder modes (direct/client-based) is implementation-specific; viewfinder modes should be explicitly specified by clients instead. |
EModeVideo = 0x08 |
The image can be overlaid on a video frame. The camera is in video mode. |
EModeDirectViewfinder = 0x00010 |
The image is to be overlaid on direct viewfinder
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeClientViewfinder = 0x00020 |
The image is to be overlaid on client-based viewfinder
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageContinuous = 0x00080 |
The image is to be overlaid when Continuous Still Image driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageBracket = 0x00100 |
The image is to be overlaid when Still Image Bracketing driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageBracketMerge = 0x00200 |
The image is to be overlaid when Still Image Bracketing with Merge option driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageTimed = 0x00400 |
The image is to be overlaid when Timed Still Image driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageTimeLapse = 0x00800 |
The image is to be overlaid when Timed Still Image with Lapse option driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
EModeStillImageBurst = 0x01000 |
The image is to be overlaid when Still Image Burst driving mode is active.
Note:
This value is available only to the API clients using CCamera::New2L() or CCamera::NewDuplicate2L() |
Overlay types
Type in which alpha value will be provided.
EOverlayNone = 0x00 |
Does not support overlays. |
EPerPixel = 0x01 |
Blending is on a per pixel basis, where the alpha value information is provided in the overlay bitmap itself. The alpha value is specified in each pixel of the bitmap (it is the alpha componenet of the TRgb object). The display mode of the bitmap should be such that alpha value is supported. TOverlayParameters::iAlphaValue is neglected in this case. |
EPerPlane = 0x02 |
Blending is on a per plane basis, where all pixels are affected by the same alpha value. The alpha value is provided through TOverlayParameters::iAlphaValue. |