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

Commit 1e2c4152 authored by Andreas Huber's avatar Andreas Huber Committed by Android Git Automerger
Browse files

am 26f70db9: Merge "Remove surface legacy APIs and code." into ics-mr1

* commit '26f70db99f483be36caa7a4c84fec5de50bec034':
  Remove surface legacy APIs and code.
parents 0f31bfac 936a981b
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -360,7 +360,7 @@ int main(int argc, char **argv) {
        service->create(getpid(), client, 0);

    if (player != NULL && player->setDataSource(source) == NO_ERROR) {
        player->setVideoSurface(surface);
        player->setVideoSurfaceTexture(surface->getSurfaceTexture());
        player->start();

        client->waitForEOS();
+0 −1
Original line number Diff line number Diff line
@@ -40,7 +40,6 @@ public:
                                    const KeyedVector<String8, String8>* headers) = 0;
    virtual status_t        setDataSource(int fd, int64_t offset, int64_t length) = 0;
    virtual status_t        setDataSource(const sp<IStreamSource>& source) = 0;
    virtual status_t        setVideoSurface(const sp<Surface>& surface) = 0;
    virtual status_t        setVideoSurfaceTexture(
                                    const sp<ISurfaceTexture>& surfaceTexture) = 0;
    virtual status_t        prepareAsync() = 0;
+0 −3
Original line number Diff line number Diff line
@@ -120,9 +120,6 @@ public:
        return INVALID_OPERATION;
    }

    // pass the buffered Surface to the media player service
    virtual status_t    setVideoSurface(const sp<Surface>& surface) = 0;

    // pass the buffered ISurfaceTexture to the media player service
    virtual status_t    setVideoSurfaceTexture(
                                const sp<ISurfaceTexture>& surfaceTexture) = 0;
+0 −1
Original line number Diff line number Diff line
@@ -170,7 +170,6 @@ public:

            status_t        setDataSource(int fd, int64_t offset, int64_t length);
            status_t        setDataSource(const sp<IStreamSource> &source);
            status_t        setVideoSurface(const sp<Surface>& surface);
            status_t        setVideoSurfaceTexture(
                                    const sp<ISurfaceTexture>& surfaceTexture);
            status_t        setListener(const sp<MediaPlayerListener>& listener);
+0 −17
Original line number Diff line number Diff line
@@ -35,7 +35,6 @@ enum {
    SET_DATA_SOURCE_URL,
    SET_DATA_SOURCE_FD,
    SET_DATA_SOURCE_STREAM,
    SET_VIDEO_SURFACE,
    PREPARE_ASYNC,
    START,
    STOP,
@@ -112,16 +111,6 @@ public:
        return reply.readInt32();
    }

    // pass the buffered Surface to the media player service
    status_t setVideoSurface(const sp<Surface>& surface)
    {
        Parcel data, reply;
        data.writeInterfaceToken(IMediaPlayer::getInterfaceDescriptor());
        Surface::writeToParcel(surface, &data);
        remote()->transact(SET_VIDEO_SURFACE, data, &reply);
        return reply.readInt32();
    }

    // pass the buffered ISurfaceTexture to the media player service
    status_t setVideoSurfaceTexture(const sp<ISurfaceTexture>& surfaceTexture)
    {
@@ -345,12 +334,6 @@ status_t BnMediaPlayer::onTransact(
            reply->writeInt32(setDataSource(source));
            return NO_ERROR;
        }
        case SET_VIDEO_SURFACE: {
            CHECK_INTERFACE(IMediaPlayer, data, reply);
            sp<Surface> surface = Surface::readFromParcel(data);
            reply->writeInt32(setVideoSurface(surface));
            return NO_ERROR;
        } break;
        case SET_VIDEO_SURFACETEXTURE: {
            CHECK_INTERFACE(IMediaPlayer, data, reply);
            sp<ISurfaceTexture> surfaceTexture =
Loading