init centering matrix with identity by default; reinit other stacks, too, so
we're consistent if DISPLAY is recreated
This commit is contained in:
@@ -407,6 +407,16 @@ static MatrixStack g_ViewStack;
|
||||
static MatrixStack g_WorldStack;
|
||||
static MatrixStack g_TextureStack;
|
||||
|
||||
|
||||
RageDisplay::RageDisplay()
|
||||
{
|
||||
RageMatrixIdentity( &g_CenteringMatrix );
|
||||
g_ProjectionStack = MatrixStack();
|
||||
g_ViewStack = MatrixStack();
|
||||
g_WorldStack = MatrixStack();
|
||||
g_TextureStack = MatrixStack();
|
||||
}
|
||||
|
||||
const RageMatrix* RageDisplay::GetCentering() const
|
||||
{
|
||||
return &g_CenteringMatrix;
|
||||
|
||||
@@ -152,7 +152,7 @@ public:
|
||||
|
||||
virtual const PixelFormatDesc *GetPixelFormatDesc( PixelFormat pf ) const = 0;
|
||||
|
||||
/* This is needed or the overridden classes' dtors will not be called. */
|
||||
RageDisplay();
|
||||
virtual ~RageDisplay() { }
|
||||
|
||||
virtual RString Init( const VideoModeParams &p, bool bAllowUnacceleratedRenderer ) = 0;
|
||||
|
||||
Reference in New Issue
Block a user