![]() | By Sebastien St-Laurent |
![]() | ![]() | ![]() | ![]() | ![]() |
Page 157 Of course, all these approaches can be tedious and time consuming. If you use Visual Studio .NET as your development environment, you may be able to take advantage of the DirectX extensions to ef.ciently debug your shaders. | Page 49 ... Considering the sun can be treated as a point light and that it is located million of miles away from earth, rays that hit the surface of the 3UN earth are almost parallel and considered directional light. This concept is Figure 4.1: Light rays from the sun can be consideredshown in Figure 4.1. par... | Page 41 ...a complete reference on the built-in HLSL functions, please refer to Appendix A, which contains a complete reference on them. This reference contains a full de.nition of the functions along with supported shader version, description of its use and even performance considerations when using each of t... | Page 193 The vertex shader 1.x model offers a wide range of instructions. Below, in Table A-1, you will .nd a complete listing of shader instructions along with a quick description of their functionality and the number of instruction slots taken by the instruction. | Page 50 ...is means that any object in any position relative to the light will get affected in the same way. Since the intensity of light on a surface is determined by the relationship between the light rays and the surface normal, the only extra step to take is to discover the direction of the rays Figure 4.3... |
Returns the name associated with an error code. This method is designed to handle error codes from all the DirectX components and Win32 functions.
TCHAR * DXGetErrorString( HRESULT
hr );If successful, this function returns a pointer to a string that contains the name of the error code. If Unicode is set, DXGetErrorString will return a Unicode string. Otherwise, it will return an ANSI string.
This function is designed to retrieve the text equivalent of a DirectX error message from an XACT, Direct3D 10, D3DX10, Direct3D9, D3DX9, Direct3D 8, D3DX8, DirectDraw, DirectPlay, DirectInput, DirectMusic, DirectSound, or DirectShow method. For example, if you set hr to 0x88760686, XGetErrorString returns D3DERR_DEVICELOST.
If an error code maps to more than one text string, DXGetErrorString returns a generic string. For example, there are several DirectX error codes, such as D3DERR_OUTOFVIDEOMEMORY, that indicate that you are out of memory, and all map to the same value. If you set hr to any of these codes, DXGetErrorString will return E_OUTOFMEMORY.
This method handles all DirectX components including: XACT, Direct3D 10, D3DX10, Direct3D9, D3DX9, Direct3D 8, D3DX8, DirectDraw, DirectPlay, DirectInput, DirectMusic, DirectSound, DirectShow, and standard Win32 errors.
This function supports Unicode and ANSI strings.
This function supports Win32 Winerror.h error codes.
Header: Declared in Dxerr.h.