libstagefright: support for disabling buffer metadata

- Metada mode video recording is enabled by default.
- use setprop debug.camcorder.disablemeta 1 to disable metadata mode recording.

Change-Id: I8ce90e633b262c5b2d1c9d7e367b7b5487b6d1b4
libstagefright: Fix for media server crash when seeking during pause

-Media server crash when clip is in pause and seek is done.
-There is mismatch in pause state in LPAPlayer and driver.
-Remove AudioSink flush

Change-Id: I0ea51bc576c4680c94648cc39a62524433d9fa06
libstagefright: Fix for failure in LPA clip playback

-When non-LPA clip follows an LPA clip in Music App,
 playback of LPA clip fails.
-setNextPlayer causes the loading of decoder omx component
 and acquires the DSP resources for non-LPA clip, even before
 LPA clip acquires DSP resources.
-Move mp3 and aac to sw decoders.

Change-Id: Ie04e8ffe5a5822245301a52b3fc8613fb1dab1ef
libstagefright: LPA playback fails when non-LPA clip is next clip

-When non-LPA clip follows an LPA clip in Music App,
 playback of LPA clip fails.
-setNextPlayer causes the loading of decoder omx component
 and acquires the DSP resources for non-LPA clip, even before
 LPA clip acquires DSP resources.
-Add property to check if hardware decoder needs to be overridden.
 If LPA is in progress, the select software decoder for next
 clip.

Change-Id: I0e40fa9859faf84f241e721cdbcb88302c698b8b
libstagefright: TCXO shutdown support and Misc fixes for LPA

- Add support for onPauseTimeout. This runs a 3s timer and then
  closes the Audio path. This allows TCXO shudown to happen.
- Fix the crash for pause and next song.

Change-Id: If68f53345c67d330390e2d9ecec5b8ceff3f9340
(cherry picked from commit 0dffdd9a679b32674f328bd6c6002778f61e07f0)
(cherry picked from commit 688ccbe244cc997cd4da451deaa8e8cdc60a1b55)
camera: allow proper preview window updates to be disabled

This causes issues with various video chat apps for devices such as
Sensation and possibly others using HTC MSM8660 camera HAL.

This is needed in Jellybean too.
See: https://github.com/CyanogenMod/android_frameworks_base/commit/795b92632696bcb307332ce32d682664b8c21d94

Change-Id: Ib4ae37df214b774e521b5bfad55f9b4558da148f
AudioFlinger: Fix compile with enabled debug flag.

Change-Id: Ibba48dce4fed6101af6b8f0c1519c3a4779eb40f
Merge "AudioFlinger: Fix compile with enabled debug flag." into jellybean
libstagefright: LPA: Fix for delay in stopping LPA playback

- Start MP3/AAC clip with duration > 1min.
  Go to settings --> apps --> Running --> Music and stop
  MediaplaybackService. The audio playback does not stop
  immediately but continues for next couple of seconds.
- While trying to tear down the LPA playback path, if the
  decoder thread is blocked on write to audio HAL, it is
  unable to stop audio playback until the decode thread
  gets unblocked.
- Fixed by issuing flush() before killing the decoder thread
  while LPA playback tear down.

Change-Id: I9d7a0c583f870db243c76fe4f38e2ae751176ab8
CRs-Fixed: 399499
framework/av: port change for vocoders support

- For EVRC, AMR vocoder support change missed
to port from ICS. Added the changes required.

Change-Id: Iab619ce435233d83943335574a104ecf88725c7b
(cherry picked from commit d40680a88ec0a209d3108bbdd0d360fc90a93a3a)

Conflicts:

	services/audioflinger/AudioFlinger.cpp
libstagefright: Fix for LPA playback not resuming after pause

-LPA clips playback fails after pause and resume.
-After onPauseTimeOut, LPA driver is closed.
-Do not trigger call of onPauseTimeOut.

Change-Id: Id5ae4fecc40dea8ab4431ab01bc7dafc56ffc63c
libmedia: Add ICS audiotrack constructor

Change-Id: I5c1a3d1093cbf16111638a37601093c5eb977dd4
Camera Service: Change max number of cameras to 3

Maximum number of cameras increased to 3 in order to support Stereo camera
in addition to the existing ones.

Change-Id: I63279daa17723669a8f116798b2687b73ddb5516
Signed-off-by: Dejan Ivanovski <x0162121@ti.com>
CameraService: Add compatibility for OMAP ICS blobs

Workaround the conflict created by usage of the 0x800 enum
in JB (focus move) vs its OMAP usage in ICS (burst jpeg)

Originally:
CameraService: Adds support for burst compressed images

Signed-off-by: Emilian Peev <epeev@mm-sol.com>

Moved the changes under OMAP_ENHANCEMENT

Signed-off-by: Solaiyappan Saravanan <saravanan.s@ti.com>
Change-Id: I1f17675b2854793de83c2b7cdecafc039c46f355

Conflicts:

	services/camera/libcameraservice/CameraService.cpp
camera: added weather key for samsung cameras

Change-Id: I1c6dc38f548fb3087abbdf7d7f83c39afaa217a1
stagefright: OMXCodec: Re-enable OMX.TI.Video.encoder's quirks

These have been around since early stagefright, and were dropped for
JB. Unfortunately, they're still necessary with for this encoder to
work.

Change-Id: I8a251bf195a24b166db7464a90a822d6e69b644d
Merge remote branch 'upstream/jellybean' into jellybean

Conflicts:
	media/libstagefright/OMXCodec.cpp

Change-Id: I61276a3e751f5651f088e89f9dafd7fd5f77c19f