Archived:Camera viewfinder orientation (Known Issue)
Client applications using the Onboard Camera API (CCamera) may have wrong orientation for the viewfinder if there are several clients using the camera consecutively. This happens when a client application that has first initialized the camera is using a different orientation from other client(s).
Article Metadata
Tested with
Compatibility
Article
How to reproduce
Start the built-in camera application. The viewfinder will use landscape mode as default. Leave it running in the background and start a 3rd-party camera application in portrait mode, and then start the viewfinder. The viewfinder is still in landscape mode.
Solution
The camera in Nokia N80 and Nokia 3250 is designed to always work in landscape mode. Therefore, by forcing also the 3rd-party camera client to landscape mode, viewfinder orientation will be correct.
void CCameraAppAppUi::ConstructL()
{
BaseConstructL(EAknEnableSkin |
EAppOrientationLandscape);
...
The application can check the device model at startup, and enable landscape mode if MachineUID for Nokia 3250 (0x200005F8) or Nokia N80 (0x200005F9) is detected:
#include <hal.h> // link against hal.lib
TInt machineUid = 0;
HAL::Get(HALData::EMachineUid, machineUid);

