SDL / openglでマルチサンプリングを実行しようとしていますが、SDLはSDL_MULTISAMPLEBUFFERSとSDL_MULTISAMPLESAMPLESの設定を受け入れません。代わりに、これらは0のままになり、SDL_SetVideoMode()は後で失敗します。私のハードウェアは4xマルチサンプリングでこのピクセルフォーマットを実行できることを知っています。Ubuntu10.10を実行しています。
コード:
SDL_Init( SDL_INIT_VIDEO );
SDL_GL_SetAttribute( SDL_GL_RED_SIZE, 8 );
SDL_GL_SetAttribute( SDL_GL_GREEN_SIZE, 8 );
SDL_GL_SetAttribute( SDL_GL_BLUE_SIZE, 8 );
SDL_GL_SetAttribute( SDL_GL_ALPHA_SIZE, 0 );
SDL_GL_SetAttribute( SDL_GL_DEPTH_SIZE, 16 );
SDL_GL_SetAttribute( SDL_GL_DOUBLEBUFFER, 1 );
SDL_GL_SetAttribute( SDL_GL_SWAP_CONTROL, 0 );
SDL_GL_SetAttribute( SDL_GL_ACCELERATED_VISUAL, 1 );
SDL_GL_SetAttribute( SDL_GL_MULTISAMPLEBUFFERS, 1 );
SDL_GL_SetAttribute( SDL_GL_MULTISAMPLESAMPLES, 4 );
Uint32 flags;
flags = SDL_OPENGL;
if( m_bFullscreen )
{
flags = flags | SDL_FULLSCREEN;
}
SDL_SetVideoMode( m_sizeX, m_sizeY, 0, flags );