1
0

avi_tscc_decoder.h 828 B

123456789101112131415161718192021222324252627
  1. #pragma once
  2. #include "../Plugins/Input/in_avi/ifc_avivideodecoder.h"
  3. #include "../nsavi/avi_header.h"
  4. #include "zlib.h"
  5. class AVITSCC : public ifc_avivideodecoder
  6. {
  7. public:
  8. AVITSCC(void *video_frame, size_t video_frame_size, void *data, size_t data_len, nsavi::video_format *stream_format);
  9. static AVITSCC *CreateDecoder(nsavi::video_format *stream_format);
  10. int GetOutputProperties(int *x, int *y, int *color_format, double *aspect_ratio, int *flip);
  11. int DecodeChunk(uint16_t type, const void *inputBuffer, size_t inputBufferBytes);
  12. void Flush();
  13. void Close();
  14. int GetPicture(void **data, void **decoder_data);
  15. private:
  16. nsavi::video_format *stream_format;
  17. uint8_t *video_frame;
  18. bool video_outputted;
  19. z_stream zlib_stream;
  20. uint8_t *data;
  21. size_t data_len;
  22. size_t video_frame_size;
  23. protected:
  24. RECVS_DISPATCH;
  25. };