Added FrameBuffer::about(), so we can actually see if hardware acceleration

is being used.


git-svn-id: svn://svn.code.sf.net/p/stella/code/trunk@2863 8b62c5a3-ac7e-4cc8-8f21-d9a121418aba
This commit is contained in:
stephena 2014-03-06 22:36:31 +00:00
parent fdf9ed708a
commit 2a0da329f2
1 changed files with 13 additions and 12 deletions

View File

@ -230,20 +230,21 @@ bool FrameBufferSDL2::setVideoMode(const string& title, VideoMode& mode, bool fu
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
string FrameBufferSDL2::about() const
{
#if 0
ostringstream out;
out << "Video rendering: OpenGL mode" << endl
<< " Vendor: " << p_gl.GetString(GL_VENDOR) << endl
<< " Renderer: " << p_gl.GetString(GL_RENDERER) << endl
<< " Version: " << p_gl.GetString(GL_VERSION) << endl
<< " Color: " << myDepth << " bit, " << myRGB[0] << "-"
<< myRGB[1] << "-" << myRGB[2] << "-" << myRGB[3] << ", "
<< "GL_BGRA" << endl
<< " Extensions: VBO " << (myVBOAvailable ? "enabled" : "disabled")
<< endl;
out << "Video system: " << SDL_GetCurrentVideoDriver() << endl;
SDL_RendererInfo info;
if(SDL_GetRendererInfo(myRenderer, &info) >= 0)
{
out << " Renderer: " << info.name << endl;
if(info.max_texture_width > 0 && info.max_texture_height > 0)
out << " Max texture: " << info.max_texture_width << "x"
<< info.max_texture_height << endl;
out << " Flags: "
<< ((info.flags & SDL_RENDERER_PRESENTVSYNC) ? "+" : "-") << "vsync, "
<< ((info.flags & SDL_RENDERER_ACCELERATED) ? "+" : "-") << "accel"
<< endl;
}
return out.str();
#endif
return EmptyString;
}
// - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -