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

Commit f4726a22 authored by Andreas Huber's avatar Andreas Huber Committed by Android (Google) Code Review
Browse files

Merge "Remove all traces of legacy renderer support in stagefright."

parents c5f99f39 c23dabfb
Loading
Loading
Loading
Loading
+0 −1
Original line number Diff line number Diff line
@@ -34,7 +34,6 @@ public:

    virtual void            disconnect() = 0;

    virtual status_t        setVideoISurface(const sp<ISurface>& surface) = 0;
    virtual status_t        setVideoSurface(const sp<Surface>& surface) = 0;
    virtual status_t        prepareAsync() = 0;
    virtual status_t        start() = 0;
+0 −38
Original line number Diff line number Diff line
@@ -120,30 +120,6 @@ public:
            node_id node,
            const char *parameter_name,
            OMX_INDEXTYPE *index) = 0;

    virtual sp<IOMXRenderer> createRenderer(
            const sp<ISurface> &surface,
            const char *componentName,
            OMX_COLOR_FORMATTYPE colorFormat,
            size_t encodedWidth, size_t encodedHeight,
            size_t displayWidth, size_t displayHeight) = 0;

    // Note: These methods are _not_ virtual, it exists as a wrapper around
    // the virtual "createRenderer" method above facilitating extraction
    // of the ISurface from a regular Surface or a java Surface object.
    sp<IOMXRenderer> createRenderer(
            const sp<Surface> &surface,
            const char *componentName,
            OMX_COLOR_FORMATTYPE colorFormat,
            size_t encodedWidth, size_t encodedHeight,
            size_t displayWidth, size_t displayHeight);

    sp<IOMXRenderer> createRendererFromJavaSurface(
            JNIEnv *env, jobject javaSurface,
            const char *componentName,
            OMX_COLOR_FORMATTYPE colorFormat,
            size_t encodedWidth, size_t encodedHeight,
            size_t displayWidth, size_t displayHeight);
};

struct omx_message {
@@ -190,13 +166,6 @@ public:
    virtual void onMessage(const omx_message &msg) = 0;
};

class IOMXRenderer : public IInterface {
public:
    DECLARE_META_INTERFACE(OMXRenderer);

    virtual void render(IOMX::buffer_id buffer) = 0;
};

////////////////////////////////////////////////////////////////////////////////

class BnOMX : public BnInterface<IOMX> {
@@ -213,13 +182,6 @@ public:
            uint32_t flags = 0);
};

class BnOMXRenderer : public BnInterface<IOMXRenderer> {
public:
    virtual status_t onTransact(
            uint32_t code, const Parcel &data, Parcel *reply,
            uint32_t flags = 0);
};

}  // namespace android

#endif  // ANDROID_IOMX_H_
+0 −1
Original line number Diff line number Diff line
@@ -106,7 +106,6 @@ public:
            const KeyedVector<String8, String8> *headers = NULL) = 0;

    virtual status_t    setDataSource(int fd, int64_t offset, int64_t length) = 0;
    virtual status_t    setVideoISurface(const sp<ISurface>& surface) = 0;
    virtual status_t    setVideoSurface(const sp<Surface>& surface) = 0;
    virtual status_t    prepare() = 0;
    virtual status_t    prepareAsync() = 0;
+0 −9
Original line number Diff line number Diff line
@@ -19,8 +19,6 @@
#define HARDWARE_API_H_

#include <media/stagefright/OMXPluginBase.h>
#include <media/stagefright/VideoRenderer.h>
#include <surfaceflinger/ISurface.h>
#include <ui/android_native_buffer.h>
#include <utils/RefBase.h>

@@ -91,13 +89,6 @@ struct UseAndroidNativeBufferParams {

}  // namespace android

extern android::VideoRenderer *createRenderer(
        const android::sp<android::ISurface> &surface,
        const char *componentName,
        OMX_COLOR_FORMATTYPE colorFormat,
        size_t displayWidth, size_t displayHeight,
        size_t decodedWidth, size_t decodedHeight);

extern android::OMXPluginBase *createOMXPlugin();

#endif  // HARDWARE_API_H_
+0 −41
Original line number Diff line number Diff line
/*
 * Copyright (C) 2009 The Android Open Source Project
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *      http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

#ifndef VIDEO_RENDERER_H_

#define VIDEO_RENDERER_H_

#include <sys/types.h>

namespace android {

class VideoRenderer {
public:
    virtual ~VideoRenderer() {}

    virtual void render(
            const void *data, size_t size, void *platformPrivate) = 0;

protected:
    VideoRenderer() {}

    VideoRenderer(const VideoRenderer &);
    VideoRenderer &operator=(const VideoRenderer &);
};

}  // namespace android

#endif  // VIDEO_RENDERER_H_
Loading