本文整理汇总了C++中GHOST_ISystem类的典型用法代码示例。如果您正苦于以下问题:C++ GHOST_ISystem类的具体用法?C++ GHOST_ISystem怎么用?C++ GHOST_ISystem使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
在下文中一共展示了GHOST_ISystem类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: GHOST_DisposeWindow
GHOST_TSuccess GHOST_DisposeWindow(GHOST_SystemHandle systemhandle,
GHOST_WindowHandle windowhandle)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
GHOST_IWindow *window = (GHOST_IWindow *) windowhandle;
return system->disposeWindow(window);
}
示例2: GHOST_ValidWindow
int GHOST_ValidWindow(GHOST_SystemHandle systemhandle,
GHOST_WindowHandle windowhandle)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
GHOST_IWindow *window = (GHOST_IWindow *) windowhandle;
return (int) system->validWindow(window);
}
示例3: GHOST_RemoveTimer
GHOST_TSuccess GHOST_RemoveTimer(GHOST_SystemHandle systemhandle,
GHOST_TimerTaskHandle timertaskhandle)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
GHOST_ITimerTask *timertask = (GHOST_ITimerTask *) timertaskhandle;
return system->removeTimer(timertask);
}
示例4: GHOST_GetAllDisplayDimensions
void GHOST_GetAllDisplayDimensions(GHOST_SystemHandle systemhandle,
GHOST_TUns32 *width,
GHOST_TUns32 *height)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
system->getAllDisplayDimensions(*width, *height);
}
示例5: GHOST_SetCursorPosition
GHOST_TSuccess GHOST_SetCursorPosition(GHOST_SystemHandle systemhandle,
GHOST_TInt32 x,
GHOST_TInt32 y)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
return system->setCursorPosition(x, y);
}
示例6: GHOST_GetCursorPosition
GHOST_TSuccess GHOST_GetCursorPosition(GHOST_SystemHandle systemhandle,
GHOST_TInt32 *x,
GHOST_TInt32 *y)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
return system->getCursorPosition(*x, *y);
}
示例7: GHOST_InstallTimer
GHOST_TimerTaskHandle GHOST_InstallTimer(GHOST_SystemHandle systemhandle,
GHOST_TUns64 delay,
GHOST_TUns64 interval,
GHOST_TimerProcPtr timerproc,
GHOST_TUserDataPtr userdata)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
return (GHOST_TimerTaskHandle) system->installTimer(delay, interval, timerproc, userdata);
}
示例8: GetDisplayDimensions
void GPG_Canvas::GetDisplayDimensions(int &width, int &height)
{
unsigned int uiwidth;
unsigned int uiheight;
GHOST_ISystem *system = GHOST_ISystem::getSystem();
system->getMainDisplayDimensions(uiwidth, uiheight);
width = uiwidth;
height = uiheight;
}
示例9: GHOST_GetModifierKeyState
GHOST_TSuccess GHOST_GetModifierKeyState(GHOST_SystemHandle systemhandle,
GHOST_TModifierKeyMask mask,
int* isDown)
{
GHOST_ISystem* system = (GHOST_ISystem*) systemhandle;
GHOST_TSuccess result;
bool isdown;
result = system->getModifierKeyState(mask, isdown);
*isDown = (int) isdown;
return result;
}
示例10: SetMousePosition
void GPG_Canvas::SetMousePosition(int x, int y)
{
GHOST_ISystem* system = GHOST_ISystem::getSystem();
if (system && m_window)
{
GHOST_TInt32 gx = (GHOST_TInt32)x;
GHOST_TInt32 gy = (GHOST_TInt32)y;
GHOST_TInt32 cx;
GHOST_TInt32 cy;
m_window->clientToScreen(gx, gy, cx, cy);
system->setCursorPosition(cx, cy);
}
}
示例11: GHOST_GetButtonState
GHOST_TSuccess GHOST_GetButtonState(GHOST_SystemHandle systemhandle,
GHOST_TButtonMask mask,
int *isDown)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
GHOST_TSuccess result;
bool isdown = false;
result = system->getButtonState(mask, isdown);
*isDown = (int) isdown;
return result;
}
示例12: GHOST_OpenNDOF
int GHOST_OpenNDOF(GHOST_SystemHandle systemhandle, GHOST_WindowHandle windowhandle,
GHOST_NDOFLibraryInit_fp setNdofLibraryInit,
GHOST_NDOFLibraryShutdown_fp setNdofLibraryShutdown,
GHOST_NDOFDeviceOpen_fp setNdofDeviceOpen)
//original patch only
/* GHOST_NDOFEventHandler_fp setNdofEventHandler)*/
{
GHOST_ISystem* system = (GHOST_ISystem*) systemhandle;
return system->openNDOF((GHOST_IWindow*) windowhandle,
setNdofLibraryInit, setNdofLibraryShutdown, setNdofDeviceOpen);
// original patch
// setNdofLibraryInit, setNdofLibraryShutdown, setNdofDeviceOpen, setNdofEventHandler);
}
示例13: GHOST_CreateWindow
GHOST_WindowHandle GHOST_CreateWindow(GHOST_SystemHandle systemhandle,
const char *title,
GHOST_TInt32 left,
GHOST_TInt32 top,
GHOST_TUns32 width,
GHOST_TUns32 height,
GHOST_TWindowState state,
GHOST_TDrawingContextType type,
GHOST_GLSettings glSettings)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
return (GHOST_WindowHandle) system->createWindow(title, left, top, width, height,
state, type, glSettings, false);
}
示例14: GHOST_BeginFullScreen
GHOST_WindowHandle GHOST_BeginFullScreen(GHOST_SystemHandle systemhandle,
GHOST_DisplaySetting *setting,
const int stereoVisual)
{
GHOST_ISystem *system = (GHOST_ISystem *) systemhandle;
GHOST_IWindow *window = NULL;
bool bstereoVisual;
if (stereoVisual)
bstereoVisual = true;
else
bstereoVisual = false;
system->beginFullScreen(*setting, &window, bstereoVisual);
return (GHOST_WindowHandle)window;
}
示例15: ResizeWindow
void GPG_Canvas::ResizeWindow(int width, int height)
{
if (m_window->getState() == GHOST_kWindowStateFullScreen)
{
GHOST_ISystem* system = GHOST_ISystem::getSystem();
GHOST_DisplaySetting setting;
setting.xPixels = width;
setting.yPixels = height;
//XXX allow these to be changed or kept from previous state
setting.bpp = 32;
setting.frequency = 60;
system->updateFullScreen(setting, &m_window);
}
m_window->setClientSize(width, height);
Resize(width, height);
}