2016-10-07 04:01:51 +02:00
|
|
|
/*
|
|
|
|
* Copyright (C) 2016 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.
|
|
|
|
*/
|
|
|
|
|
|
|
|
package android.hardware.media.omx@1.0;
|
|
|
|
|
2017-03-07 00:09:19 +01:00
|
|
|
import android.hardware.graphics.bufferqueue@1.0::IGraphicBufferProducer;
|
2016-10-07 04:01:51 +02:00
|
|
|
import android.hardware.media@1.0::types;
|
|
|
|
|
|
|
|
import IOmxNode;
|
|
|
|
import IOmxObserver;
|
2016-12-19 08:49:56 +01:00
|
|
|
import IGraphicBufferSource;
|
2016-10-07 04:01:51 +02:00
|
|
|
|
|
|
|
/**
|
|
|
|
* Ref: frameworks/av/include/media/IOMX.h: IOMX
|
|
|
|
*
|
|
|
|
* IOmx is the main entry point for communicating with OMX components.
|
|
|
|
*/
|
|
|
|
interface IOmx {
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Information for an IOmxNode component.
|
|
|
|
*/
|
|
|
|
struct ComponentInfo {
|
2016-12-19 08:49:56 +01:00
|
|
|
string mName;
|
|
|
|
vec<string> mRoles;
|
2016-10-07 04:01:51 +02:00
|
|
|
};
|
|
|
|
|
|
|
|
/**
|
|
|
|
* List available components.
|
|
|
|
*
|
2016-12-19 08:49:56 +01:00
|
|
|
* @param[out] status The status of the call.
|
|
|
|
* @param[out] nodeList The list of ComponentInfo.
|
2016-10-07 04:01:51 +02:00
|
|
|
*/
|
|
|
|
listNodes(
|
|
|
|
) generates (
|
|
|
|
Status status,
|
|
|
|
vec<ComponentInfo> nodeList
|
|
|
|
);
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Allocate an IOmxNode instance with the specified component name.
|
|
|
|
*
|
2016-12-19 08:49:56 +01:00
|
|
|
* @param[in] name The name of the component to create.
|
|
|
|
* @param[in] observer An observer object that will receive messages from
|
2016-10-07 04:01:51 +02:00
|
|
|
* the created instance.
|
2016-12-19 08:49:56 +01:00
|
|
|
* @param[out] status The status of the call.
|
|
|
|
* @param[out] omxNode The allocated instance of IOmxNode.
|
2016-10-07 04:01:51 +02:00
|
|
|
*/
|
|
|
|
allocateNode(
|
|
|
|
string name,
|
|
|
|
IOmxObserver observer
|
|
|
|
) generates (
|
|
|
|
Status status,
|
|
|
|
IOmxNode omxNode
|
|
|
|
);
|
|
|
|
|
2016-12-19 08:49:56 +01:00
|
|
|
/**
|
|
|
|
* Create an input surface for recording.
|
|
|
|
*
|
|
|
|
* @param[out] producer The associated producer end of the buffer queue.
|
|
|
|
* @param[out] source The associated `IGraphicBufferSource`.
|
|
|
|
*/
|
|
|
|
createInputSurface(
|
|
|
|
) generates (
|
|
|
|
Status status,
|
2017-03-07 00:09:19 +01:00
|
|
|
IGraphicBufferProducer producer,
|
2016-12-19 08:49:56 +01:00
|
|
|
IGraphicBufferSource source
|
|
|
|
);
|
2016-10-07 04:01:51 +02:00
|
|
|
};
|
|
|
|
|