• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 // Copyright (c) 2010 The WebM project authors. All Rights Reserved.
2 //
3 // Use of this source code is governed by a BSD-style license
4 // that can be found in the LICENSE file in the root of the source
5 // tree. An additional intellectual property rights grant can be found
6 // in the file PATENTS.  All contributing project authors may
7 // be found in the AUTHORS file in the root of the source tree.
8 
9 #ifndef MKVREADER_HPP
10 #define MKVREADER_HPP
11 
12 #include "mkvparser.hpp"
13 #include <cstdio>
14 
15 namespace mkvparser
16 {
17 
18 class MkvReader : public IMkvReader
19 {
20     MkvReader(const MkvReader&);
21     MkvReader& operator=(const MkvReader&);
22 public:
23     MkvReader();
24     virtual ~MkvReader();
25 
26     int Open(const char*);
27     void Close();
28 
29     virtual int Read(long long position, long length, unsigned char* buffer);
30     virtual int Length(long long* total, long long* available);
31 private:
32     long long m_length;
33     FILE* m_file;
34 };
35 
36 }  //end namespace mkvparser
37 
38 #endif //MKVREADER_HPP
39