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/f263/mkv_f263_decoder.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/f263/mkv_f263_decoder.h')
-rw-r--r-- | Src/f263/mkv_f263_decoder.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/Src/f263/mkv_f263_decoder.h b/Src/f263/mkv_f263_decoder.h new file mode 100644 index 00000000..984ef6a3 --- /dev/null +++ b/Src/f263/mkv_f263_decoder.h @@ -0,0 +1,38 @@ +#pragma once +#include "../Plugins/Input/in_mkv/ifc_mkvvideodecoder.h" +#include "../Plugins/Input/in_mkv/svc_mkvdecoder.h" +#include "../winamp/wa_ipc.h" + +// {0071721C-7B4D-4766-B165-E42BC080DA74} +static const GUID mkv_flv1_guid = +{ 0x71721c, 0x7b4d, 0x4766, { 0xb1, 0x65, 0xe4, 0x2b, 0xc0, 0x80, 0xda, 0x74 } }; + + +class MKVDecoderCreator : public svc_mkvdecoder +{ +public: + static const char *getServiceName() { return "FLV1 MKV Decoder"; } + static GUID getServiceGuid() { return mkv_flv1_guid; } + int CreateVideoDecoder(const char *codec_id, const nsmkv::TrackEntryData *track_entry_data, const nsmkv::VideoData *video_data, ifc_mkvvideodecoder **decoder); +protected: + RECVS_DISPATCH; +}; + + +class MKVFLV1 : public ifc_mkvvideodecoder +{ + public: + MKVFLV1(void *decoder); + int GetOutputProperties(int *x, int *y, int *color_format, double *aspect_ratio); + int DecodeBlock(const void *inputBuffer, size_t inputBufferBytes, uint64_t timestamp); + void Flush(); + int GetPicture(void **data, void **decoder_data, uint64_t *timestamp); +private: + void *decoder; + YV12_PLANES yv12; + int32_t last_timestamp; + int width, height; + int decoded; +protected: + RECVS_DISPATCH; +};
\ No newline at end of file |