MaybeUnsetAdditionalVertexStream

From Multi Theft Auto: Wiki
Jump to navigation Jump to search

This C++ Function is found inside of CAdditionalVertexStreamManager.

It maybe unsets additional vertex stream.

It can be found in Client/Client Core/Sources/CAdditionalVertexStreamManager.cpp in Visual Studio.

Code

void CAdditionalVertexStreamManager::MaybeUnsetAdditionalVertexStream ( void )
{
    HRESULT hr;
    if ( m_pOldVertexDeclaration )
    {
        // Set prev declaration
        hr = g_pProxyDevice->SetVertexDeclaration ( m_pOldVertexDeclaration );
        SAFE_RELEASE( m_pOldVertexDeclaration );

        // Unset additional stream
        hr = m_pDevice->SetStreamSource ( 2, NULL, 0, 0 );
    }
}

See Also