(svn r22999) -Codechange: Allow changing the blitter during the running game.

This commit is contained in:
michi_cc
2011-10-04 21:35:40 +00:00
parent 12e28de818
commit 6dbb050a32
12 changed files with 97 additions and 46 deletions

View File

@@ -400,7 +400,7 @@ bool VideoDriver_Cocoa::ChangeResolution(int w, int h)
{
assert(_cocoa_subdriver != NULL);
bool ret = _cocoa_subdriver->ChangeResolution(w, h);
bool ret = _cocoa_subdriver->ChangeResolution(w, h, BlitterFactoryBase::GetCurrentBlitter()->GetScreenDepth());
QZ_GameSizeChanged();
QZ_UpdateVideoModes();
@@ -443,6 +443,16 @@ bool VideoDriver_Cocoa::ToggleFullscreen(bool full_screen)
return _cocoa_subdriver->IsFullscreen() == full_screen;
}
/**
* Callback invoked after the blitter was changed.
*
* @return True if no error.
*/
bool VideoDriver_Cocoa::AfterBlitterChange()
{
return this->ChangeResolution(_screen.width, _screen.height);
}
/**
* Catch asserts prior to initialization of the videodriver.
*