Surfaceflinger: Modify setFormat() API to set 3D format.

setFormat() API is modified to accept 3D formats from applications.
This change is required for 3D game usecase so each layer can be
marked as 3D and can be sent to overlay for rendering.

Change-Id: I9266d9ab367c5eccb8fb182f3f517234415a9897
MediaRecorder: Remove creation of new thread when voting for io_is_busy

Change-Id: I682b91be2a001f19eb4b8c90a4d0e450bbbe1f71
CRs-Fixed: 339691
SurfaceTexture: Initialize S3D format member variable to 0

Without initialization mS3DFormat may hold garbage value, and
may corrupt the format calculations in libQcomUI.

This change is done to fix UI corruption.

Change-Id: I55491ce82a49f69eb290bc4a078f7995589335f3
Surfaceflinger: Compose UI in S3D format

The new member of LayerBase takes care of identifying layer for 3d
composition. When 3D composition is required the Layer takes care
of drawing in 3D format

Change-Id: I55c99a3cb612c6dd7a22d346a5b9a88c056c835d
SurfaceFlinger: Return error on invalid buffer creation

When a buffer is re-allocated on reconfiguration, return NULL
if there is an error in re-allocation.

Also, remove warnings during compilation.

Change-Id: Ie01bfcfbb469a106ef99bf1725376e2753206708
CRs-Fixed: 337660
SurfaceFlinger: Skip composition when rotation is not completed

When rotating, each layer's buffer is already changed to
new orientation before SurfaceFlinger gets the signal from
Window Manager. If the orientations of all the buffers are
changed to new orientation, then that's fine. But, sometimes,
only one buffer is changed and others remain the same.
In this case, skip composition.

Change-Id: I850fe8ee6d806e21833e6811f95878fcfb6f7c40
CRs-fixed: 338034
SurfaceFlinger: Prevent screencap command from failure

For secure windows, screen capture fails, and the screencap command
falls back to reading from the framebuffer directly.

Instead, draw a black screen on the framebuffer object if there is a
secure session, so that secure layers cannot be captured.

Change-Id: Ic14ee3f119f622b41f1af3861237204805fb3ca2
CRs-Fixed: 338570
SurfaceFlinger: notify HWC when layer is in asynchronous mode

When the layer is in asynchronous mode the HWC may choose a
different composition method.

CRs-Fixed: 335498
Change-Id: Ifa4658338e98e80e9a673bdf10ae388f0ad3ae9f
Remove 'Bypass Texture Creation' hack in frameworks

Graphics driver (ADRENO) was updated to convert the texture on
first use. Hence this change is no longer required.

CRs-fixed: 338153
Profiles: UI/UX consistency and cleanup (Part 2 of 2)

This commit contains the frameworks support for the modified Profiles
and Application Groups settings functionality, ensuring consistency between
the two.

1) Add ability to rename Application groups
2) Add duplicate name checking for app groups

Change-Id: Ifcf2eb5f6aa26e0d4778b32c1a35bfb88fac318b
libRS: Correct the screen freezing issue

This fixes a timing issue where it could calculate a delay of 0
(indicating wait forever) when it has no pending commands to actually
execute. In such cases, it should just break out of the playback loop.
This also fixes a small issue with returning whether or not to redraw.
(Provided by Stephen Hines <srhines@google.com>)

CRs-Fixed: 330352

Change-Id: If3c880e1546105279d286ae76cc41e8b8f193ec1
SurfaceTextureClient: Add support for external only usage flags.

Add support for GRALLOC_USAGE_EXTERNAL_ONLY and
GRALLOC_USAGE_EXTERNAL_BLOCK to be set as a part of usage flags.
These flags if present will be cached by SurfaceTextureClient.
Incoming usage flags will be ORed with these, if present.

(cherry picked from commit dcbd475319bae2f5d0613bf62d8324169e6ab79d)

Change-Id: I366f6a664805e8944663600dc3b1f82530275873
performance: Add Performance class

New Performance class to allow system CPU control

Change-Id: Ie476aefcec7fc20cab8d747ef7c3994b26fcbb62
Add cpuSetOptions API to org.codeaurora.Performance class

Change-Id: I66f7e910f4fee0a9d443356b00b452872628d3f0
QCOM-related cleanups

* Hide qcom-specific methods from the API
* Disable service classes
* Fix media-recorder start/stop for non-qcoms

Change-Id: I42b1acb5c732182663fea89039f57e775afb3ebe
omx: support for samsungs opensource vp8 and fp avc decoders

Change-Id: Ifa2c516029650ddc76f659cd0101d6debf9252bc
Merge branch 'ics' into github/ics

Change-Id: Id94bf36465511fdaf3b7500987e7ab2697c72c0e
Merge remote-tracking branch 'cyanogen/ics' into ics