Viewfinder

This tutorial introduces you to the Viewfinder functionality of the Ecam component.

Purpose

This document describes the various APIs used with Viewfinder.

Introduction

The viewfinder classes provides the support for multiple direct and client viewfinder. The image adjustment features such as histograms, image processing and direct snapshot can be used specifically for a given direct viewfinder. Client can get specific histogram or image processing object for client viewfinder.

The viewfinder can directly transfer frames from a camera to the display memory. If supported, the client can also implement viewfinder functionality by itself using image data returned in call-backs.

Enabling mirroring flips the image horizontally. Devices that allow the user to view themself can then be used as a virtual mirror. The viewfinder should be able to run simultaneously with video or image capture.

Setup and Configuration Requirements

If video or image capture preparation puts the camera into a mode that has an effect on the viewfinder aspect ratio and size, then the recent successful prepare should determine the context for viewfinder operation.

It is expected that the viewfinder aspect and size follow the settings in the last image or video prepare call. Multiple viewfinders may run at the same time by the use of new extension classes: CcameraV2DirectViewFinder and CcameraClientViewFinder .

A new instance of these classes needs to be created for every new viewfinder. Dedicated observers: MdirectViewFinderObserver and MclientViewFinderObserver provide viewfinder related call-backs to the client. Client should implement these observers.

Types of Viewfinder

The client starts a viewfinder, when the camera is powered-on. There are two types of viewfinder.

See also

Overview of Viewfinder API

The Direct Viewfinder Tutorial

The Client Viewfinder Tutorial