2 * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
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
8 * http://www.apache.org/licenses/LICENSE-2.0
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.
17 * @author Grzegorz Krawczyk (g.krawczyk@samsung.com)
22 #ifndef WRT_PLUGINS_WRT_CAMERA_H_
23 #define WRT_PLUGINS_WRT_CAMERA_H_
26 #include <dpl/shared_ptr.h>
27 #include <wrt_plugin_export.h>
28 #include "IWrtCamera.h"
29 //#include <API/Camera/ICamera.h>
31 namespace WrtDeviceApis {
34 class WrtCamera : public IWrtCamera
38 typedef void* CameraInstance;
41 WrtCamera(int widgetId,
42 const engine_interface_t* interface,
43 CameraInstance camera,
46 virtual void createPreviewNode(CameraPreviewSuccessCb successCallback,
47 CameraErrorCb errorCallback,
48 SetPendingOperationCb setPendingOperationCb,
51 virtual void captureImage(const std::string& filename,
53 CameraCaptureSuccessCb successCallback,
54 CameraErrorCb errorCallback,
55 SetPendingOperationCb setPendingOperationCb,
58 virtual void startVideoCapture(const std::string& filename,
60 CameraCaptureSuccessCb successCallback,
61 CameraErrorCb errorCallback,
62 SetPendingOperationCb setPendingOperationCb,
65 virtual void stopVideoCapture();
67 virtual void cancelAsyncOperation(const CameraPendingOperation& operation);
77 const engine_interface_t* m_wrt;
79 CameraInstance m_camera;
82 typedef DPL::SharedPtr<WrtCamera> WrtCameraPtr;
85 } // WrtDeviceApisCommon