VBoxCrHgsmi.cpp revision ba6524ccac330688123403ddf0a83d702cd9e371
#include <VBox/VBoxCrHgsmi.h>
#include "VBoxUhgsmiKmt.h"
static int g_bVBoxKmtCallbacksInited = 0;
#ifdef VBOX_CRHGSMI_WITH_D3DDEV
static uint32_t g_cVBoxCrHgsmiProvider = 0;
typedef VBOXWDDMDISP_DECL(int) FNVBOXDISPCRHGSMI_TERM();
{
{
else
}
if (g_bVBoxKmtCallbacksInited < 0)
{
Assert(0);
return VERR_NOT_SUPPORTED;
}
if (!g_hVBoxCrHgsmiProvider)
{
{
}
{
g_pfnVBoxDispCrHgsmiInit = (PFNVBOXDISPCRHGSMI_INIT)GetProcAddress(g_hVBoxCrHgsmiProvider, "VBoxDispCrHgsmiInit");
{
}
g_pfnVBoxDispCrHgsmiTerm = (PFNVBOXDISPCRHGSMI_TERM)GetProcAddress(g_hVBoxCrHgsmiProvider, "VBoxDispCrHgsmiTerm");
g_pfnVBoxDispCrHgsmiQueryClient = (PFNVBOXDISPCRHGSMI_QUERY_CLIENT)GetProcAddress(g_hVBoxCrHgsmiProvider, "VBoxDispCrHgsmiQueryClient");
}
#ifdef DEBUG_misha
else
{
Assert(0);
}
#endif
}
{
{
}
return VINF_SUCCESS;
}
/* we're called from ogl ICD driver*/
Assert(0);
return VINF_SUCCESS;
}
{
{
//#ifdef DEBUG_misha
// Assert(hClient);
//#endif
if (hClient)
return hClient;
}
if (pHgsmiGL)
{
}
if (pHgsmiGL)
{
#if 0
#else
#endif
{
if (hClient)
{
return hClient;
}
}
}
return NULL;
}
#else
{
/*Assert(hr == S_OK);*/
{
/* check if we can create the hgsmi */
if (pHgsmi)
{
/* yes, we can, so this is wddm mode */
Log(("CrHgsmi: WDDM mode supported\n"));
return 1;
}
}
Log(("CrHgsmi: unsupported\n"));
return -1;
}
VBOXCRHGSMI_DECL(int) VBoxCrHgsmiInit()
{
{
}
}
{
if (pHgsmiGL)
{
#if 0
#else
#endif
{
}
}
return NULL;
}
{
{
}
}
#endif
VBOXCRHGSMI_DECL(int) VBoxCrHgsmiTerm()
{
#if 0
if (pHgsmiGL)
{
gt_pHgsmiGL = NULL;
}
#endif
if (g_bVBoxKmtCallbacksInited > 0)
{
}
return VINF_SUCCESS;
}
{
}