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>
32 namespace Tizen { namespace Media {
34 class _VideoFrameExtractorImpl
35 : public Tizen::Base::Object
39 * @see VideoFrameExtractor::VideoFrameExtractor()
42 _VideoFrameExtractorImpl(void);
45 * @see VideoFrameExtractor::~VideoFrameExtractor()
47 virtual ~_VideoFrameExtractorImpl(void);
50 * @see VideoFrameExtractor::Construct()
52 result Construct(const Tizen::Base::String &filePath, MediaPixelFormat pixelFormat);
55 * @see VideoFrameExtractor::GetWidth()
57 int GetWidth(void) const;
60 * @see VideoFrameExtractor::GetHeight()
62 int GetHeight(void) const;
65 * @see VideoFrameExtractor::GetDuration()
67 long GetDuration(void) const;
70 * @see VideoFrameExtractor::GetFrameN()
72 ImageBuffer* GetFrameN(long timestamp);
75 * @see VideoFrameExtractor::GetFrameN()
77 static ImageBuffer* GetFrameN(const Tizen::Base::String& path, MediaPixelFormat pixelFormat, long timestamp);
79 static _VideoFrameExtractorImpl* GetInstance(VideoFrameExtractor *pVideoFrameExtractor);
80 static const _VideoFrameExtractorImpl* GetInstance(const VideoFrameExtractor *pVideoFrameExtractor);
82 static result ToResult(int ret);
83 static result GetMetaDataValue(struct metadata_extractor_s*& extractor,int key, int &value);
87 struct metadata_extractor_s* __extractor;
88 MediaPixelFormat __pixelFormat;
97 #endif //_FMEDIA_VIDEO_FRAME_EXTRACTOR_IMPL_H_