aboutsummaryrefslogtreecommitdiff
path: root/Src/bmp/avi_rgb_decoder.h
diff options
context:
space:
mode:
authorJef <jef@targetspot.com>2024-09-24 08:54:57 -0400
committerJef <jef@targetspot.com>2024-09-24 08:54:57 -0400
commit20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch)
tree12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/bmp/avi_rgb_decoder.h
parent537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff)
downloadwinamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz
Initial community commit
Diffstat (limited to 'Src/bmp/avi_rgb_decoder.h')
-rw-r--r--Src/bmp/avi_rgb_decoder.h27
1 files changed, 27 insertions, 0 deletions
diff --git a/Src/bmp/avi_rgb_decoder.h b/Src/bmp/avi_rgb_decoder.h
new file mode 100644
index 00000000..08294462
--- /dev/null
+++ b/Src/bmp/avi_rgb_decoder.h
@@ -0,0 +1,27 @@
+#pragma once
+#include "../Plugins/Input/in_avi/ifc_avivideodecoder.h"
+#include "../nsavi/avi_header.h"
+
+class AVIRGB : public ifc_avivideodecoder
+{
+public:
+ AVIRGB(nsavi::video_format *stream_format);
+ ~AVIRGB();
+ int Initialize();
+ static AVIRGB *CreateDecoder(nsavi::video_format *stream_format);
+ int GetOutputProperties(int *x, int *y, int *color_format, double *aspect_ratio, int *flip);
+ int DecodeChunk(uint16_t type, const void *inputBuffer, size_t inputBufferBytes);
+ void Flush();
+ void Close();
+ int GetPicture(void **data, void **decoder_data);
+ int GetPalette(RGB32 **palette);
+private:
+ nsavi::video_format *stream_format;
+ void *video_frame;
+ size_t video_frame_size_bytes;
+ bool o;
+ RGBQUAD palette[256];
+ bool palette_retrieved;
+protected:
+ RECVS_DISPATCH;
+}; \ No newline at end of file