mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-01-10 16:19:28 +01:00
Merge pull request #191 from Jezze/for-dolphin
Some cleanups for OGL/Vertexmanager.cpp
This commit is contained in:
commit
51fdf8a9b2
@ -143,19 +143,11 @@ void VertexManager::vFlush(bool useDstAlpha)
|
|||||||
// Makes sure we can actually do Dual source blending
|
// Makes sure we can actually do Dual source blending
|
||||||
bool dualSourcePossible = g_ActiveConfig.backend_info.bSupportsDualSourceBlend;
|
bool dualSourcePossible = g_ActiveConfig.backend_info.bSupportsDualSourceBlend;
|
||||||
|
|
||||||
// finally bind
|
// If host supports GL_ARB_blend_func_extended, we can do dst alpha in
|
||||||
if (dualSourcePossible)
|
// the same pass as regular rendering.
|
||||||
|
if (useDstAlpha && dualSourcePossible)
|
||||||
{
|
{
|
||||||
if (useDstAlpha)
|
ProgramShaderCache::SetShader(DSTALPHA_DUAL_SOURCE_BLEND, g_nativeVertexFmt->m_components);
|
||||||
{
|
|
||||||
// If host supports GL_ARB_blend_func_extended, we can do dst alpha in
|
|
||||||
// the same pass as regular rendering.
|
|
||||||
ProgramShaderCache::SetShader(DSTALPHA_DUAL_SOURCE_BLEND, g_nativeVertexFmt->m_components);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
ProgramShaderCache::SetShader(DSTALPHA_NONE,g_nativeVertexFmt->m_components);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@ -166,8 +158,7 @@ void VertexManager::vFlush(bool useDstAlpha)
|
|||||||
ProgramShaderCache::UploadConstants();
|
ProgramShaderCache::UploadConstants();
|
||||||
|
|
||||||
// setup the pointers
|
// setup the pointers
|
||||||
if (g_nativeVertexFmt)
|
g_nativeVertexFmt->SetupVertexPointers();
|
||||||
g_nativeVertexFmt->SetupVertexPointers();
|
|
||||||
GL_REPORT_ERRORD();
|
GL_REPORT_ERRORD();
|
||||||
|
|
||||||
Draw(stride);
|
Draw(stride);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user