MyWebUniversity.com Home Page
 



OpenSolaris man pages main menu


Cg Direct3D10 Runtime API              cgD3D10TranslateHRESULT(3)



NAME
     cgD3D10000TranslateHRESULT - convert an HRESULT into a string

SYNOPSIS
       #include 

       const char * cgD3D10TranslateHRESULT( HRESULT hr );


PARAMETERS
     hr      The HRESULT to translate. Can be a generic HRESULT
             or a D3D runtime error.

RETURN VALUES
     Returns a pointer to a string describing the error.

DESCRIPTION
     cgD3D10000TranslateHRESULT converts an HRESULT into a string.
     This routine should be called instead of
     DXGetErrorDescription10000 because it will also translate
     errors that the Cg D3D runtime generates.

     This routine will typically be called in debugging
     situations such as inside an error callback set using
     cgSetErrorCallback.

EXAMPLES
       char buf[512];
       HRESULT hres = cgD3D10GetLastError();
       if (FAILED(hres))
       {
           sprintf(buf, "A D3D error occurred. Error description: '%s'\n",
                   cgD3D10TranslateHRESULT(hres));
           OutputDebugString(buf);
       }


ERORS
     None.

HISTORY
     cgD3D10000TranslateHRESULT was introduced in Cg 2.1.

SEE ALSO
     cgD3D10TranslateCGerror, cgGetErrorString,
     cgSetErrorCallback









Cg Toolkit 2.1            Last change:                          1



OpenSolaris man pages main menu

Contact us      |       About us      |       Term of use      |       Copyright © 2000-2010 MyWebUniversity.com ™