diff options
author | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
---|---|---|
committer | Jef <jef@targetspot.com> | 2024-09-24 08:54:57 -0400 |
commit | 20d28e80a5c861a9d5f449ea911ab75b4f37ad0d (patch) | |
tree | 12f17f78986871dd2cfb0a56e5e93b545c1ae0d0 /Src/omBrowser/pngLoader.h | |
parent | 537bcbc86291b32fc04ae4133ce4d7cac8ebe9a7 (diff) | |
download | winamp-20d28e80a5c861a9d5f449ea911ab75b4f37ad0d.tar.gz |
Initial community commit
Diffstat (limited to 'Src/omBrowser/pngLoader.h')
-rw-r--r-- | Src/omBrowser/pngLoader.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/Src/omBrowser/pngLoader.h b/Src/omBrowser/pngLoader.h new file mode 100644 index 00000000..d03797bc --- /dev/null +++ b/Src/omBrowser/pngLoader.h @@ -0,0 +1,46 @@ +#ifndef NULLSOFT_WINAMP_OMIMAGELOADER_PNG_HEADER +#define NULLSOFT_WINAMP_OMIMAGELOADER_PNG_HEADER + +#if defined(_MSC_VER) && (_MSC_VER >= 1020) +#pragma once +#endif + +#include "./ifc_imageloader.h" + +class ifc_wasabihelper; + +class PngLoader : public ifc_omimageloader +{ +protected: + PngLoader(HINSTANCE hInstance, LPCWSTR pszName, BOOL fPremultiply); + ~PngLoader(); + +public: + static HRESULT CreateInstance(HINSTANCE hInstance, LPCWSTR pszName, BOOL fPremultiply, ifc_omimageloader **imageLoader); + +public: + size_t AddRef(); + size_t Release(); + int QueryInterface(GUID interface_guid, void **object); + + HRESULT (LoadData)(int *widthOut, int *heightOut, void **dataOut); + HRESULT (FreeData)(void *data); + HRESULT (LoadBitmapEx)(HBITMAP *bitmapOut, BITMAPINFOHEADER *headerInfo, void **dataOut); + HRESULT (LoadBitmap)(HBITMAP *bitmapOut, int *widthOut, int *heightOut); + +protected: + RECVS_DISPATCH; + + typedef enum + { + flagPremultiply = 0x0001, + } Flags; + +protected: + ULONG ref; + HINSTANCE instance; + LPWSTR name; + UINT flags; +}; + +#endif //NULLSOFT_WINAMP_OMIMAGELOADER_PNG_HEADER
\ No newline at end of file |