2 // Open Service Platform
3 // Copyright (c) 2012 Samsung Electronics Co., Ltd.
5 // Licensed under the Apache License, Version 2.0 (the License);
6 // you may not use this file except in compliance with the License.
7 // You may obtain a copy of the License at
9 // http://www.apache.org/licenses/LICENSE-2.0
11 // Unless required by applicable law or agreed to in writing, software
12 // distributed under the License is distributed on an "AS IS" BASIS,
13 // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 // See the License for the specific language governing permissions and
15 // limitations under the License.
19 * @file FMedia_VideoFrameExtractorImpl.h
20 * @brief This is the header file for the %_VideoFrameExtractorImpl Implementation class.
22 * This header file contains the declarations of the %_VideoFrameExtractorImpl implementation class.
25 #ifndef _FMEDIA_VIDEO_FRAME_EXTRACTOR_IMPL_H_
26 #define _FMEDIA_VIDEO_FRAME_EXTRACTOR_IMPL_H_
28 #include <FBaseObject.h>
29 #include <FMediaImageBuffer.h>
30 #include <FMediaVideoFrameExtractor.h>
31 #include <FMediaRecorderTypes.h>
33 namespace Tizen { namespace Media {
35 class _VideoFrameExtractorImpl
36 : public Tizen::Base::Object
40 * @see VideoFrameExtractor::VideoFrameExtractor()
43 _VideoFrameExtractorImpl(void);
46 * @see VideoFrameExtractor::~VideoFrameExtractor()
48 virtual ~_VideoFrameExtractorImpl(void);
51 * @see VideoFrameExtractor::Construct()
53 result Construct(const Tizen::Base::String &filePath, MediaPixelFormat pixelFormat);
56 * @see VideoFrameExtractor::GetWidth()
58 int GetWidth(void) const;
61 * @see VideoFrameExtractor::GetHeight()
63 int GetHeight(void) const;
66 * @see VideoFrameExtractor::GetDuration()
68 long GetDuration(void) const;
71 * @see VideoFrameExtractor::GetRecordingRotation()
73 RecordingRotation GetRecordingRotation(void) const;
76 * @see VideoFrameExtractor::GetFrameN()
78 ImageBuffer* GetFrameN(long timestamp);
81 * @see VideoFrameExtractor::GetFrameN()
83 static ImageBuffer* GetFrameN(const Tizen::Base::String& path, MediaPixelFormat pixelFormat, long timestamp);
85 static _VideoFrameExtractorImpl* GetInstance(VideoFrameExtractor *pVideoFrameExtractor);
86 static const _VideoFrameExtractorImpl* GetInstance(const VideoFrameExtractor *pVideoFrameExtractor);
88 static result ToResult(int ret);
90 static result GetMetaDataValue(struct metadata_extractor_s*& extractor,int key, int &value);
94 struct metadata_extractor_s* __extractor;
95 MediaPixelFormat __pixelFormat;
96 RecordingRotation __rotation;
105 #endif //_FMEDIA_VIDEO_FRAME_EXTRACTOR_IMPL_H_