• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1/*
2 * Copyright (C) 2019 The Android Open Source Project
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 *      http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17package android.frameworks.automotive.display@1.0;
18
19import android.hardware.graphics.bufferqueue@2.0::IGraphicBufferProducer;
20
21interface IAutomotiveDisplayProxyService {
22    /**
23     * Gets an IGraphicBufferProducer instance from the service.
24     *
25     * @param  id   Target's stable display identifier
26     *
27     * @return igbp Returns an IGraphicBufferProducer object, that can be
28     *              converted to an ANativeWindow object.
29     */
30    getIGraphicBufferProducer(uint64_t id) generates (IGraphicBufferProducer igbp);
31
32    /**
33     * Sets the ANativeWindow, which is associated with the
34     * IGraphicBufferProducer, to be visible and to take over the display.
35     *
36     * @param  id      Target display ID
37     *
38     * @return success Returns true on success.
39     */
40    showWindow(uint64_t id) generates (bool success);
41
42    /**
43     * Sets the ANativeWindow, which is associated with the
44     * IGraphicBufferProducer, to be invisible and to release the control
45     * over display.
46     *
47     * @param  id      Target display ID
48     *
49     * @return success Returns true on success.
50     */
51    hideWindow(uint64_t id) generates (bool success);
52
53    /**
54     * Returns the stable identifiers of all available displays.
55     *
56     * @return ids A list of stable display identifiers.
57     */
58    getDisplayIdList() generates (vec<uint64_t> ids);
59
60    /**
61     * Returns the descriptor of the target display.
62     *
63     * @param  id    Stable ID of a target display.
64     * @return cfg   DisplayConfig of the active display.
65     * @return state Current state of the active display.
66     */
67    getDisplayInfo(uint64_t id) generates (HwDisplayConfig cfg, HwDisplayState state);
68};
69