blob: e5693b26d1a78fde231a47ca0abe9417110ecc32 [file] [log] [blame]
Emilian Peeve18057b2017-11-13 16:03:44 +00001/*
2 * Copyright (C) 2017 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.hardware.camera.device@3.4;
18
19import android.hardware.camera.common@1.0::Status;
20import @3.3::ICameraDeviceSession;
21import @3.3::HalStreamConfiguration;
22
23/**
24 * Camera device active session interface.
25 *
26 * Obtained via ICameraDevice::open(), this interface contains the methods to
27 * configure and request captures from an active camera device.
28 */
29interface ICameraDeviceSession extends @3.3::ICameraDeviceSession {
30
31 /**
32 * configureStreams_3_4:
33 *
34 * Identical to @3.3::ICameraDeviceSession.configureStreams, except that:
35 *
36 * - The requested configuration includes session parameters.
37 *
38 * @return Status Status code for the operation, one of:
39 * OK:
40 * On successful stream configuration.
41 * INTERNAL_ERROR:
42 * If there has been a fatal error and the device is no longer
43 * operational. Only close() can be called successfully by the
44 * framework after this error is returned.
45 * ILLEGAL_ARGUMENT:
46 * If the requested stream configuration is invalid. Some examples
47 * of invalid stream configurations include:
48 * - Including more than 1 INPUT stream
49 * - Not including any OUTPUT streams
50 * - Including streams with unsupported formats, or an unsupported
51 * size for that format.
52 * - Including too many output streams of a certain format.
53 * - Unsupported rotation configuration
54 * - Stream sizes/formats don't satisfy the
55 * camera3_stream_configuration_t->operation_mode requirements
56 * for non-NORMAL mode, or the requested operation_mode is not
57 * supported by the HAL.
58 * - Unsupported usage flag
59 * The camera service cannot filter out all possible illegal stream
60 * configurations, since some devices may support more simultaneous
61 * streams or larger stream resolutions than the minimum required
62 * for a given camera device hardware level. The HAL must return an
63 * ILLEGAL_ARGUMENT for any unsupported stream set, and then be
64 * ready to accept a future valid stream configuration in a later
65 * configureStreams call.
66 * @return halConfiguration The stream parameters desired by the HAL for
67 * each stream, including maximum buffers, the usage flags, and the
68 * override format.
69 */
70 configureStreams_3_4(@3.4::StreamConfiguration requestedConfiguration)
71 generates (Status status,
72 @3.3::HalStreamConfiguration halConfiguration);
73
74};