diff options
| author | Jean-Francois Mauguit <jfmauguit@mac.com> | 2024-09-24 09:03:25 -0400 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-09-24 09:03:25 -0400 |
| commit | bab614c421ed7ae329d26bf028c4a3b1d2450f5a (patch) | |
| tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/Plugins/Input/in_mkv/MKVInfo.h | |
| parent | 4bde6044fddf053f31795b9eaccdd2a5a527d21f (diff) | |
| parent | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (diff) | |
| download | winamp-bab614c421ed7ae329d26bf028c4a3b1d2450f5a.tar.gz | |
Merge pull request #5 from WinampDesktop/community
Merge to main
Diffstat (limited to 'Src/Plugins/Input/in_mkv/MKVInfo.h')
| -rw-r--r-- | Src/Plugins/Input/in_mkv/MKVInfo.h | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/Src/Plugins/Input/in_mkv/MKVInfo.h b/Src/Plugins/Input/in_mkv/MKVInfo.h new file mode 100644 index 00000000..bed2522f --- /dev/null +++ b/Src/Plugins/Input/in_mkv/MKVInfo.h @@ -0,0 +1,26 @@ +#pragma once +#include "../nsmkv/header.h" +#include "../nsmkv/segmentinfo.h" +#include "../nsmkv/tracks.h" +// parses only enough information to use in GetExtendedFileInfo + +class MKVInfo +{ +public: + MKVInfo(); + bool Open(const wchar_t *filename); + int GetLengthMilliseconds(); + const char *GetTitle(); + int GetBitrate(); + bool GetHeight(int &height); + bool GetWidth(int &width); + const nsmkv::Tracks *GetTracks(); +private: + uint64_t ReadSegment(nsmkv::MKVReader *reader, uint64_t size); + bool segment_info_found; + bool tracks_found; + nsmkv::Header header; + nsmkv::SegmentInfo segment_info; + nsmkv::Tracks tracks; + uint64_t content_length; +};
\ No newline at end of file |
