forked from mikrosimage/avTranscoder
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathIInputStream.hpp
More file actions
48 lines (39 loc) · 1.2 KB
/
Copy pathIInputStream.hpp
File metadata and controls
48 lines (39 loc) · 1.2 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
#ifndef _AV_TRANSCODER_CODED_STREAM_I_INPUT_STREAM_HPP_
#define _AV_TRANSCODER_CODED_STREAM_I_INPUT_STREAM_HPP_
#include <AvTranscoder/codec/AudioCodec.hpp>
#include <AvTranscoder/codec/VideoCodec.hpp>
#include <AvTranscoder/codec/DataCodec.hpp>
#include <AvTranscoder/frame/Frame.hpp>
namespace avtranscoder
{
class AvExport IInputStream
{
public:
virtual ~IInputStream() {};
/**
* @brief Read the next packet of the stream
* @param data: data of next packet read
* @return if next packet was read succefully
**/
virtual bool readNextPacket( CodedData& data ) = 0;
virtual size_t getStreamIndex() const = 0;
virtual double getDuration() const = 0;
virtual AVMediaType getStreamType() const = 0;
//@{
/**
* Return the codec informations of the stream
* @exception Raise a runtime error if the stream is not of the corresponding type
*/
virtual VideoCodec& getVideoCodec() = 0;
virtual AudioCodec& getAudioCodec() = 0;
virtual DataCodec& getDataCodec() = 0;
//@}
/**
* @brief Activate the stream will buffered its data when read packets.
**/
virtual void activate( const bool activate = true ) = 0;
virtual bool isActivated() const = 0;
virtual void clearBuffering() = 0;
};
}
#endif