Direct3D Utilities

Collaboration diagram for Direct3D Utilities:

Classes

struct  tk11::Direct3D_Error
 A Direct3D API function failed. More...

Modules

 Buffers
 Input Layouts
 Shaders
 State
 Render Targets
 Textures

Defines

#define TK11_CHECK_RESULT(x, function)
 Check if Direct3D API function call was successful.

Typedefs

typedef boost::error_info
< detail::hresult_tag, HRESULT > 
tk11::errinfo_hresult
 Error information: Result code of a Direct3D function (HRESULT).

Detailed Description

Many helper functions and classes for easier and more robust use of Direct3D 11.

Includes Direct3D smart COM pointers and utilities for Direct3D error handling.


Define Documentation

#define TK11_CHECK_RESULT ( x,
function   ) 
Value:
{ \
    HRESULT hresult_123 = (x); \
    if(!SUCCEEDED(hresult_123)) { \
      BOOST_THROW_EXCEPTION(Direct3D_Error() \
        << boost::errinfo_api_function(function) \
        << errinfo_hresult(hresult_123)); \
    } \
  }

Check if Direct3D API function call was successful.

Checks the result of a Direct3D API function call. If the call was not successful, then Direct3D_Error is thrown with appropriate error information attached. The name of the API function is wrapped into a boost::errinfo_api_function object, and the result code is wrapped into an errinfo_hresult object.

Parameters:
x Result of function or function call expression (HRESULT)
function API function name (string)
See also:
Direct3D_Error, errinfo_hresult

Typedef Documentation

typedef boost::error_info<detail::hresult_tag, HRESULT> tk11::errinfo_hresult

Error information: Result code of a Direct3D function (HRESULT).

See also:
TK11_CHECK_RESULT, Direct3D_Error
Tk11 Direct3D 11 Toolkit version 0.2 (SourceForge)
Copyright Florian Winter 2010 - 2010. Distributed under the Boost Software License, Version 1.0.
(See accompanying file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
Generated on Sun Apr 11 20:23:00 2010 for Tk11 by  doxygen 1.6.3