blob: 041fa65454462b4f93f9f61ca1d3313cc209994c [file] [log] [blame]
Igor Murashkine7ee7632013-06-11 18:10:18 -07001/*
2 * Copyright (C) 2013 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
17#ifndef ANDROID_HARDWARE_PHOTOGRAPHY_CALLBACKS_H
18#define ANDROID_HARDWARE_PHOTOGRAPHY_CALLBACKS_H
19
20#include <utils/RefBase.h>
21#include <binder/IInterface.h>
22#include <binder/Parcel.h>
23#include <binder/IMemory.h>
24#include <utils/Timers.h>
25#include <system/camera.h>
26
27namespace android {
28class CameraMetadata;
29
30class ICameraDeviceCallbacks : public IInterface
31{
32 /**
33 * Keep up-to-date with ICameraDeviceCallbacks.aidl in frameworks/base
34 */
35public:
36 DECLARE_META_INTERFACE(CameraDeviceCallbacks);
37
38 // One way
39 virtual void notifyCallback(int32_t msgType,
40 int32_t ext1,
41 int32_t ext2) = 0;
42
43 // One way
44 virtual void onResultReceived(int32_t frameId,
45 const CameraMetadata& result) = 0;
46};
47
48// ----------------------------------------------------------------------------
49
50class BnCameraDeviceCallbacks : public BnInterface<ICameraDeviceCallbacks>
51{
52public:
53 virtual status_t onTransact( uint32_t code,
54 const Parcel& data,
55 Parcel* reply,
56 uint32_t flags = 0);
57};
58
59}; // namespace android
60
61#endif