This reverts commit 1a8b6c29aaa5a1591097daca0876808cc029cbda
Reason for revert: utf8_length handles a slightly different range than the checkjni code, so it's possible for a given string to pass the utf8_length check, but then fail the jni check.
Change-Id: I81e15c95edd8f89782d8ad9025e68502b9340f22
There may be cases where queryNumberEffects fails leading
to the usage of the uninitialized numEffects.
Change-Id: If6d46987021ff6f0c9a2123d8714ff5fdf9ced45
This saves the caller from manually iterating through the
MediaCodecList for finding the right codec.
This adds new public API.
Change-Id: I8462f040573427542d86d1b957a5aef53dd55e8e
Currently, when the codec was opened by createDecoder/EncoderByType,
the caller does not know what codec actually was chosen, and
(for encoders) thus cannot know what color formats it supports.
This adds new public API.
Change-Id: Ie471f40f8104b37d27ced3dba5a54facc6504b1b
Many media files and source code files were marked as executable in Git.
Remove those.
Also a shell script and python script were not marked as executable.
Change-Id: Ieb51bafb46c895a21d2e83696f5a901ba752b2c5
Fixes problems with file transfer from device to host that can occur
if the database size value is wrong.
Bug: 6954446
Change-Id: I03c3dd4b75267d1f4613f0b588c8899ded9a70be
Signed-off-by: Mike Lockwood <lockwood@google.com>
Cleaned up the implementation of Surface and SurfaceSession
to use more consistent naming and structure.
Added JNI for all of the new surface flinger display API calls.
Enforced the requirement that all Surfaces created by
the window manager be named.
Updated the display manager service to use the new methods.
Change-Id: I2a658f1bfd0437e1c6f9d22df8d4ffcce7284ca2
Adds android.media.DataSource, which is modeled after its native namesake,
and a new method on MediaExtractor that lets apps specify their implementation
of a DataSource as the source of data for the extractor.
Change-Id: If1b169bd18d2691ebc4f8996494dfc8ee0894b6c
There is a protential memory leak in video editor JNI codes.
When importing so many video clips, the number of local reference
will exceed 512, which will cause the Dalvik virtual machine
crash. The patch will free each local reference when it's no
longer used to avoid memory leaks.
Change-Id: Iecd986c83f05a1103641746d6d43eef0a9c5ee40
Author: Wei Feng <wei.feng@intel.com>
Signed-off-by: Wei Feng <wei.feng@intel.com>
Singed-off-by: Shuo Gao <shuo.gao@intel.com>
Signed-off-by: Bruce Beare <bruce.j.beare@intel.com>
Signed-off-by: Jack Ren <jack.ren@intel.com>
Author-tracking-BZ: 40786
The allocated array has one byte less than the required length. Allocating the size one byte larger fixes the issue.
contribution was originally from teng.hong@nxp.com
Change-Id: I3aa2e6b995fd18e30649a34f201646082aab44ee
related-to-bug: 6347465
o Removes mParcel from TimedText class.
o Converts native parcel into java parcel object directly without
copying to an intermediate byte array.
o JNIMediaPlayerListener::notify checks for Java exceptions, logs them,
and clears the exception state.
related-to-bug: 6405934
Change-Id: I8b82d3cd5b9b3ef8cad27e805202a0e445a88a45
New API on MediaExtractor to retrieve a CryptoInfo structure where applicable.
Change-Id: I18edfc9ac56a4544c8f17cba24401b96dacbff7d
related-to-bug: 6275919
utf8_length() from libutils returns -1 when source not contains
valid sequence for UTF-8. Fixed to use it and removed the local
function isValidUtf8().
Change-Id: If2834ce1d1ae07fd8526ce8bc5df3fd3f44e85c8
Signed-off-by: Homin Lee <suapapa@insignal.co.kr>
o the failure was because the mediaserver does not have read permission to sdcard
o related-to-bug: 6325960,6322913
Change-Id: I4feec01b8165c78563eee8aab69cb24df3244d03
o Change the impl of MediaMetadataRetriever.setDataSource(String).
It opens and passes an fd to the media framework
rather than pass the file path directly to the media server. The change is needed since media
server does not have read permission to sdcard
o Remove the unnecessary jni method
Change-Id: I5a2f47dde804523d264b588f855ba2575a99c179