Initializes DXUT.
HRESULT DXUTInit( BOOL bParseCommandLine, BOOL bHandleDefaultHotkeys, BOOL bShowMsgBoxOnError );
Command-line Argument | Action |
---|---|
-adapter:# | Forces the application to use this adapter ordinal. Fails if the adapter ordinal does not exist. |
-fullscreen | Starts in full-screen mode. |
-windowed | Starts in windowed mode. |
-startx:# | For windowed mode, sets the x-coordinate of the window position to the value of #. |
-starty:# | For windowed mode, sets the y-coordinate of the window position to the value of #. |
-height:# | Sets the window height to the value of #. For full-screen mode, DXUT picks the closest possible supported mode. |
-width:# | Sets the window width to the value of #. For full-screen mode, DXUT picks the closest possible supported mode. |
-forcehal | Forces the application to use a hal device type, D3DDEVTYPE_HAL. Fails if a hal device does not exist. |
-forcehwvp | Forces the application to use hardware vertex processing. Fails if the device does not support this mode. |
-forcepurehwvp | Forces the application to use pure hardware vertex processing. Fails if the device does not support this mode. |
-forceref | Forces the application to use a reference device type, D3DDEVTYPE_REF. Fails if a reference device does not exist. |
-forceswvp | Forces the application to use software vertex processing. |
-constantframetime | Uses a constant frame time. |
-noerrormsgboxes | Prevents the display of message boxes generated by the framework, allowing the application to be run without user interaction. |
-quitafterframe:# | Forces the application to quit after frame #. |
-automation | Enables UI navigation with keyboard |
Key | Action |
---|---|
ALT+ENTER | Toggles between full-screen and windowed modes. |
ESC | Exits the application. |
F3 | Toggles between hal and reference devices. |
F8 | Toggles between wireframe and rendered views. |
PAUSE | Pauses the application. |
If the function succeeds, the return value is S_OK. If the function fails, the return value can be one of the error codes in DXUTERR.
If this function has not been called before DXUTCreateWindow or DXUTSetWindow, the framework will automatically call this function using the default parameter values.
Header: Declared in Dxut.h.
Initializing DXUT, Device Types, Processing Vertex Data, DXUTCreateWindow, DXUTSetWindow, DXUTSetWindow