Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 8f80fadb authored by Marco Nelissen's avatar Marco Nelissen Committed by Android (Google) Code Review
Browse files

Merge changes I42d7cbc5,I6eda8458

* changes:
  Add mp2 container and codec support
  Use header file for namespace functions
parents 559a766d 6a69e114
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -708,6 +708,7 @@ static CreatorFunc Sniff(
}

static const char *extensions[] = {
    "mp2",
    "mp3",
    "mpeg",
    "mpg",
+2 −1
Original line number Diff line number Diff line
@@ -2092,7 +2092,8 @@ status_t ACodec::configureCodec(
        if (usingSwRenderer) {
            outputFormat->setInt32("using-sw-renderer", 1);
        }
    } else if (!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_MPEG)) {
    } else if (!strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_MPEG) ||
        !strcasecmp(mime, MEDIA_MIMETYPE_AUDIO_MPEG_LAYER_II)) {
        int32_t numChannels, sampleRate;
        if (!msg->findInt32("channel-count", &numChannels)
                || !msg->findInt32("sample-rate", &sampleRate)) {
+1 −0
Original line number Diff line number Diff line
@@ -220,6 +220,7 @@ cc_library {
    ],

    header_libs:[
        "libnativeloader-dummy-headers",
        "libstagefright_xmlparser_headers",
        "media_ndk_headers",
    ],
+1 −17
Original line number Diff line number Diff line
@@ -30,6 +30,7 @@
#include <media/stagefright/MediaExtractorFactory.h>
#include <media/IMediaExtractor.h>
#include <media/IMediaExtractorService.h>
#include <nativeloader/dlext_namespaces.h>
#include <private/android_filesystem_config.h>
#include <cutils/properties.h>
#include <utils/String8.h>
@@ -38,23 +39,6 @@
#include <dirent.h>
#include <dlfcn.h>

// Copied from GraphicsEnv.cpp
// TODO(b/37049319) Get this from a header once one exists
extern "C" {
  android_namespace_t* android_create_namespace(const char* name,
                                                const char* ld_library_path,
                                                const char* default_library_path,
                                                uint64_t type,
                                                const char* permitted_when_isolated_path,
                                                android_namespace_t* parent);
  bool android_link_namespaces(android_namespace_t* from,
                               android_namespace_t* to,
                               const char* shared_libs_sonames);
  enum {
     ANDROID_NAMESPACE_TYPE_ISOLATED = 1,
  };
}

namespace android {

// static