Пример #1
0
void GLGSRender::OnInitThread()
{
	m_context = new wxGLContext(m_frame->GetCanvas());

	m_frame->GetCanvas()->SetCurrent(*m_context);
	InitProcTable();

	glEnable(GL_TEXTURE_2D);
	glEnable(GL_SCISSOR_TEST);
	glSwapInterval(Ini.GSVSyncEnable.GetValue() ? 1 : 0);
}
Пример #2
0
void GLGSRender::OnInitThread()
{
	m_context = m_frame->GetNewContext();

	m_frame->SetCurrent(m_context);

	InitProcTable();

	glEnable(GL_TEXTURE_2D);
	glEnable(GL_VERTEX_PROGRAM_POINT_SIZE);
	glGenTextures(1, &g_depth_tex);
	glGenTextures(1, &g_flip_tex);
	
#ifdef _WIN32
	glSwapInterval(Ini.GSVSyncEnable.GetValue() ? 1 : 0);
// Undefined reference: glXSwapIntervalEXT
/*#else
	if (GLXDrawable drawable = glXGetCurrentDrawable()){
		glXSwapIntervalEXT(glXGetCurrentDisplay(), drawable, Ini.GSVSyncEnable.GetValue() ? 1 : 0);
	}*/
#endif

}