AvTranscoder  0.9.4
C++APIforLibav/FFmpeg
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
IEncoder.hpp
Go to the documentation of this file.
1 #ifndef _AV_TRANSCODER_ESSENCE_STREAM_IENCODER_HPP_
2 #define _AV_TRANSCODER_ESSENCE_STREAM_IENCODER_HPP_
3 
8 
9 namespace avtranscoder
10 {
11 
12 class AvExport IEncoder
13 {
14 public:
15  virtual ~IEncoder() {}
16 
17  /**
18  * @brief Setup the encoder
19  * @param profile: set encoder parameters from the given profile
20  * @note Open the encoder.
21  */
22  virtual void setupEncoder(const ProfileLoader::Profile& profile = ProfileLoader::Profile()) = 0;
23 
24  /**
25  * @brief Encode a new frame, and get coded frame
26  * @param sourceFrame: frame that needs to be encoded
27  * @param codedFrame: output encoded coded data (first frames can be delayed)
28  * @return status of encoding
29  * @throw runtime_error if the encoded process failed.
30  */
31  virtual bool encodeFrame(const Frame& sourceFrame, CodedData& codedFrame) = 0;
32 
33  /**
34  * @brief Get the frames remaining into the encoder
35  * @param codedFrame: output encoded data
36  * @return status of encoding
37  * @throw runtime_error if the encoded process failed.
38  */
39  virtual bool encodeFrame(CodedData& codedFrame) = 0;
40 
41  /**
42  * @brief Get codec used for encoding.
43  * @return a reference to the codec
44  */
45  virtual ICodec& getCodec() = 0;
46 };
47 }
48 
49 #endif
std::map< std::string, std::string > Profile
This class describes decoded (raw) audio or video data.
Definition: Frame.hpp:16
This class describes coded data.
Definition: CodedData.hpp:18
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy