blob: 6bf30cff7598490d30a18aa6e1aba1c524905113 [file] [log] [blame]
Jiyoung Shinc15a6b02012-06-05 01:08:14 -07001/*
2**
3** Copyright 2008, The Android Open Source Project
4** Copyright 2012, Samsung Electronics Co. LTD
5**
6** Licensed under the Apache License, Version 2.0 (the "License");
7** you may not use this file except in compliance with the License.
8** You may obtain a copy of the License at
9**
10** http://www.apache.org/licenses/LICENSE-2.0
11**
12** Unless required by applicable law or agreed to in writing, software
13** distributed under the License is distributed on an "AS IS" BASIS,
14** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15** See the License for the specific language governing permissions and
16** limitations under the License.
17*/
18
19/*!
20 * \file MetadataConverter.h
21 * \brief header file for Metadata converter ( for camera hal2 implementation )
22 * \author Sungjoong Kang(sj3.kang@samsung.com)
23 * \date 2012/05/31
24 *
25 * <b>Revision History: </b>
26 * - 2012/05/31 : Sungjoong Kang(sj3.kang@samsung.com) \n
27 * Initial Release
28 */
29
30#ifndef METADATA_CONVERTER_H
31#define METADATA_CONVERTER_H
32
33#include <hardware/camera2.h>
34#include <camera/Camera.h>
35#include <camera/CameraParameters.h>
36
37#include "system/camera_metadata.h"
Sungjoong Kangbe494d12012-08-04 15:36:56 -070038#include "fimc-is-metadata.h"
Jiyoung Shinc15a6b02012-06-05 01:08:14 -070039
40
41namespace android {
42
43
44class MetadataConverter {
45public:
46 MetadataConverter();
47 ~MetadataConverter();
48
Sungjoong Kangbe494d12012-08-04 15:36:56 -070049 status_t ToInternalShot(camera_metadata_t * request, struct camera2_shot_ext * dst_ext);
50 status_t ToDynamicMetadata(struct camera2_shot_ext * metadata_ext, camera_metadata_t * dst);
Jiyoung Shinc15a6b02012-06-05 01:08:14 -070051
52private:
53 status_t CheckEntryTypeMismatch(camera_metadata_entry_t * entry, uint8_t type);
54 status_t CheckEntryTypeMismatch(camera_metadata_entry_t * entry, uint8_t type, size_t count);
55
56};
57
58}; // namespace android
59
60#endif
61