home *** CD-ROM | disk | FTP | other *** search
/ Tricks of the Windows Gam…ming Gurus (2nd Edition) / Disc2.iso / msdn_vcb / samples / vc98 / atl / direct3d / d3datl.cpp next >
C/C++ Source or Header  |  1998-03-26  |  872b  |  35 lines

  1. // D3D.cpp : Implementation of CDirect3D
  2. //
  3. // This is a part of the Active Template Library.
  4. // Copyright (C) 1996-1998 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Active Template Library Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Active Template Library product.
  12.  
  13. #include "stdafx.h"
  14. #include "Direct3D.h"
  15. #include "D3DAtl.h"
  16.  
  17. /////////////////////////////////////////////////////////////////////////////
  18. // CDirect3D
  19.  
  20. STDMETHODIMP CDirect3D::InterfaceSupportsErrorInfo(REFIID riid)
  21. {
  22.     static const IID* arr[] =
  23.     {
  24.         &IID_IDirect3D,
  25.     };
  26.  
  27.     for (int i=0; i < sizeof(arr)/sizeof(arr[0]); i++)
  28.     {
  29.         if (InlineIsEqualGUID(*arr[i],riid))
  30.             return S_OK;
  31.     }
  32.  
  33.     return S_FALSE;
  34. }
  35.