1
0
mirror of https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git synced 2025-07-18 11:19:10 +00:00

Fill out bink stub

Max 2012 doesn't like getting a null from ClassDesc2::Create(). I can't
blame it.
This commit is contained in:
2013-01-18 19:37:43 -05:00
parent 33d26ce29f
commit a382752354

View File

@ -42,18 +42,43 @@ You can contact Cyan Worlds, Inc. by email legal@cyan.com
#include "HeadSpin.h"
#include "hsWindows.h"
#include <bmmlib.h>
#include <iparamb2.h>
#pragma hdrstop
/** Stubbed out BitmapIO instance for deprecated bink layers **/
class plBinkBitmapIO : public BitmapIO
{
public:
int ExtCount() { return 1; }
const TCHAR* Ext(int n) { return _T("bik"); }
const TCHAR* LongDesc() { return _T("DEAD: Bink File"); }
const TCHAR* ShortDesc() { return _T("Bink"); }
const TCHAR* AuthorName() { return _T("Colin Bonstead"); }
const TCHAR* CopyrightMessage() { return _T("Copyright 2004, Cyan Inc."); }
unsigned int Version() { return 100; }
int Capability() { return 0; }
DWORD EvaluateConfigure() { return 0; }
BOOL LoadConfigure(void* ptr) { return FALSE; }
BOOL SaveConfigure(void* ptr) { return FALSE; }
BMMRES GetImageInfo(BitmapInfo* fbi) { return BMMRES_INTERNALERROR; }
BitmapStorage* Load(BitmapInfo* fbi, Bitmap* map, BMMRES* status) { return nullptr; }
void ShowAbout(HWND hWnd)
{
hsMessageBoxWithOwner(hWnd, "Bink Layers removed due to license issues", "DEAD", hsMessageBoxNormal, MB_ICONEXCLAMATION);
}
};
class BinkClassDesc : public ClassDesc2
{
public:
int IsPublic() { return 1; }
void* Create(BOOL loading=FALSE)
{
hsAssert(false, "bink layers removed due to license issues");
return nil;
}
void* Create(BOOL loading=FALSE) { return static_cast<void*>(new plBinkBitmapIO); }
const TCHAR* ClassName() { return "Bink"; }
SClass_ID SuperClassID() { return BMM_IO_CLASS_ID; }