I am trying to take pictures with the front camera using the camera wrapper.
I figured out that to access the front camera I have to construct the CCameraEngine object with:
iCameraWrapper = CCameraEngine::NewL(1, 0, this)
that triggers a call to MCameraEngineObserver's method MceoCameraReady(), which looks like follows in my current code:
I am trying this on a 6210, 6710 and 5800, which all have front camera. In all cases, PrepareL() leaves with -5 (KErrNotSupported). After leaving, the MCameraEngineObserver's method MceoHandleError() is also called with aErrorType = EErrAutoFocusMode and aError = -5 (KErrNotSupported).
if (iCameraWrapper->State() == CCameraEngine::EEngineIdle)
iCaptureSize = TSize(640, 480); // Captured picture size
TRAPD(err, iCameraWrapper->PrepareL(iCaptureSize)); // Prepare camera
iTimer = CSPTimer::NewL(this);
iTimer->StartL(CConfiguration::iConfiguration.iPictureTime * 1000);
Not sure why this is happening. I am not calling any autofocus function whatsoever yet. But the thing is that, since PrepareL() has failed, I can't actually take any picture with the front camera.
What am I doing wrong?, or is it not possible to take pictures with front camera?