Camera: HAL: Add support for camframetimeout callback API.

The mm-camera layer issues a camframe_timeout callback
when it doesnt receive preview frames from camera driver
(in the timeout period). Add receive_camframetimeout API
in HAL which ensures that additional IOCTL calls are not
issued in such scenario.
Also remove compilation warnings by reordering the
initialization of some variables in the class constructor.
Camera: Adding multiple picture sizes support

Multiple Picture Sizes option supported
Supported picture sizes  filtered based on sensor type
Default Preview Size set to WVGA
Camera: disable setting prameters that are not supported for yuv sensor

2 mp yuv sensor doesn't support a few parameters. Add a check to not
call the set parameter ioctl call for the parameters that are not
supported.
Camera: Enabling 1280x720 Preview size

Enabled 1280x720 Preview Size for Camcorder
Camera: Setting Thumbnail dimensions based on picture aspect ratio

Thumbnail dimensions are set based on picture aspect ratio such
that the thumbnail aspect ratio matches picture aspect ratio

CRs-Fixed: 220698
Camera: Setting cbcr offset to frame size in picture buffer

In 7x27, buffer size is calculated by taking ceiling value of
width and height for jpeg encoder. Cbcr offset was initially
calculated based on this size based on ceiling values. Setting
cbcr offset to frame size calculated based on exact width
and height.
Camera: Invoking Enable AFD call for Auto Anti Banding option

Invoking Enable AFD call for Auto Anti Banding option instead
of looking up anti banding value based on country code

CRs-Fixed: 222020
Camera: Add support for 4x zoom and to pass maximum zoom value to upper
layers.

Add support for 4X zoom by calling setCrop of overlay or mdp blit with crop
information. Also, get the maximum zoom value from driver and pass the
same in camera parameters. Changed the zoom step size from 6 to 1 for
smooth zoom.

CRs-Fixed: 222381, 222382
Camera: HAL: Send postview for display using overlay for 7x30.

The last preview frame is displayed as postview for 7x30.
Copy the last preview frame into the buffer mPostViewHeap.
Once the snapshot is taken, queue this buffer for display
using overlay.

CRs-Fixed: 221602
Camera: HAL: Add a workaround to ensure that the file
descriptor returned in open call is non-zero

Sometimes open call to camera driver returns 0, which is
not expected. When it happens, the behaviour is
undeterministic. Hence add the workaround till the issue
is resolved.
Camera: HAL: Enable setting jpeg rotation mode and
setting thumbnail image quality APIs.

Enable the following APIs:
jpeg_encoder_setRotation: Sets the current orientation
mode (one among 0, 90, 180 or 270) to Jpeg encoder.
jpeg_encoder_setThumbnailQuality: Sets the thumbnail
image quality.

CRs-Fixed: 221182
Camera: Adding Sharpness, Contrast and Saturation features

Enabling Sharpness, Contrast and Saturation features in HAL
layer
CRs-Fixed: 215214
Camera: Add FPS logging to calculate and display camera fps

Add support to calculate and display the FPS when the user requests this
value by setting the system property.

CRs-Fixed: 222383
Camera: HAL: Initialize camera parameters to their
default values.

Some camera parameters are not initialized to their default values.
Set them to their default values in initDefaultParameters().
Check for mPostViewHeap only if the target is 7630, since mPostViewHeap
is used only for 7630.
Camera: HAL: Terminate camframe thread when
camframe_timeout_callback is issued from mm-camera.

1. When the camframe thread issues camframe_timeout_callback,
camframe_terminate should be invoked which ensures that the
camframe thread is terminated.
2. release_cam_conf_thread should be invoked even if
the timeout_callback is received, otherwise the config
thread is not terminated and resources wont be freed.
Camera: Disabling 4x zoom feature for 7x27 and 8k temporarily.

Disabling the 4x zoom feature till Gerrit# 16029 is merged in.
Without the above gerrit change 5mp snapshot functionality is
broken on Karura.
Camera: Setting sharpness, contrast and saturation values in HAL Parameters

Setting sharpness, contrast and saturation values in CameraParameters
object contained in HAL.
Revert the temporary workaround added at HAL layer.

Remove the workaround for the issue where the fd returned was
0. This issue is fixed now, hence removing the workaround.
This reverts commit 65138e3c35aacde6eeb4de20ef21d4f9c678f8b9.
Camera: Ensure that the mdp blit is not invoked when there is no crop
information

MDP blit shouldn't be called when there is no crop information present
in the frame. Fixed this by having all the source and destination
buffers moving into a single FD and registering this FD with surface
flinger, so that the actual frame data will be controlled by setting
offset to correct value depending on whether MDP blit is done or not.
Camera : Enable VFE output 2 for video recording

HAL changes required for handling VFE output 2 frames for video recording