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

Commit 88c2fb9a authored by Surajit Podder's avatar Surajit Podder Committed by Linux Build Service Account
Browse files

video: Add support for client extradata

Add support for client extradata by passing
client allocated buffer fd across process.

Change-Id: I775a5a7f273768ba401ea20e6ad7b51b16736b7a
parent 356678ae
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -47,6 +47,12 @@ struct AVMediaUtils {

    virtual bool AudioTrackIsTrackOffloaded(audio_io_handle_t /*output*/);

    virtual void writeCustomParamData(
        int , const void *, size_t, Parcel *) {}

    virtual void readCustomParamData(
        int , void *, size_t, const Parcel *) {}

    // ----- NO TRESSPASSING BEYOND THIS LINE ------
    DECLARE_LOADABLE_SINGLETON(AVMediaUtils);
};
+3 −0
Original line number Diff line number Diff line
@@ -26,6 +26,7 @@
#include <media/stagefright/foundation/ADebug.h>
#include <media/openmax/OMX_IndexExt.h>
#include <utils/NativeHandle.h>
#include <media/AVMediaExtensions.h>

namespace android {

@@ -176,6 +177,7 @@ public:
        data.writeInt32(index);
        data.writeInt64(size);
        data.write(params, size);
        AVMediaUtils::get()->writeCustomParamData(index, params, size, &data);
        remote()->transact(SET_PARAMETER, data, &reply);

        return reply.readInt32();
@@ -781,6 +783,7 @@ status_t BnOMX::onTransact(
                                    err = getParameter(node, index, params, size);
                                    break;
                                case SET_PARAMETER:
                                    AVMediaUtils::get()->readCustomParamData(index, params, size, &data);
                                    err = setParameter(node, index, params, size);
                                    break;
                                case GET_CONFIG: