1/* 2 * Copyright (c) 2024 Huawei Device Co., Ltd. 3 * Licensed under the Apache License, Version 2.0 (the "License"); 4 * you may not use this file except in compliance with the License. 5 * You may obtain a copy of the License at 6 * 7 * http://www.apache.org/licenses/LICENSE-2.0 8 * 9 * Unless required by applicable law or agreed to in writing, software 10 * distributed under the License is distributed on an "AS IS" BASIS, 11 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12 * See the License for the specific language governing permissions and 13 * limitations under the License. 14 */ 15 16/** 17 * @file istream_operator_callback.h 18 * 19 * @brief Declares callbacks related to {@link IStreamOperator}. The caller needs to implement these callbacks. 20 * 21 * @since 5.0 22 * @version 1.3 23 */ 24 25package ohos.hdi.camera.v1_3; 26 27import ohos.hdi.camera.v1_3.Types; 28 29[callback] interface IStreamOperatorCallback extends ohos.hdi.camera.v1_2.IStreamOperatorCallback { 30 /** 31 * @brief Called when the next capture get ready. 32 * 33 * @param captureId Indicates the ID of the capture request corresponding to the callback. 34 * @param streamIds Indicates the IDs of the streams corresponding to the callback. 35 * @Param timestamp Indicates the timestamp when the callback is invoked. 36 * 37 * @since 5.0 38 * @version 1.3 39 */ 40 OnCaptureReady([in] int captureId, [in] int[] streamIds, [in] unsigned long timestamp); 41 42 /** 43 * @brief Called when the frameShutter ends. 44 * 45 * @param captureId Indicates the ID of the capture request corresponding to the callback. 46 * @param streamIds Indicates the IDs of the streams corresponding to the callback. 47 * @Param timestamp Indicates the timestamp when the callback is invoked. 48 * 49 * @since 5.0 50 * @version 1.3 51 */ 52 OnFrameShutterEnd([in] int captureId, [in] int[] streamIds, [in] unsigned long timestamp); 53 54 /** 55 * @brief Called when the capture ends. 56 * 57 * @param captureId Indicates the ID of the capture request corresponding to the callback. 58 * @param infos Indicates information related to the capture when it ends. 59 * 60 * @since 5.0 61 * @version 1.0 62 */ 63 OnCaptureEndedExt([in] int captureId, [in] struct CaptureEndedInfoExt[] infos); 64 65 /** 66 * @brief Called to report metadata and other information related to the stream. 67 * For details about the reporting mode, see {@link SetResultMode}. 68 * 69 * @param streamId Indicates the ID of the stream related to metadata is reported. 70 * @param result Indicates the metadata and other information reported. 71 * The reported metadata and other information are specified by {@link EnableResult}. 72 * You can call {@link DisableResult} to disable metadata and other information reporting. 73 * 74 * @since 5.0 75 * @version 1.0 76 */ 77 OnResult([in] int streamId, [in] unsigned char[] result); 78}