home *** CD-ROM | disk | FTP | other *** search
/ Visual Basic Game Programming for Teens / VBGPFT.cdr / DirectX8 / dx8a_sdk.exe / samples / multimedia / direct3d / envmapping / cubemap / readme.txt < prev    next >
Encoding:
Text File  |  2000-09-22  |  2.6 KB  |  60 lines

  1. //-----------------------------------------------------------------------------
  2. // Name: CubeMap Direct3D Sample
  3. // 
  4. // Copyright (c) 1998-2000 Microsoft Corporation. All rights reserved.
  5. //-----------------------------------------------------------------------------
  6.  
  7.  
  8. Description
  9. ===========
  10.    The CubeMap sample demonstrates an enviroment-mapping technique called 
  11.    cube-mapping. Environment-mapping is a technique in which the environment
  12.    surrounding a 3D object (such as the lights, etc.) are put into a texture
  13.    map, so that the object can have complex lighting effects without expensive
  14.    lighting calculations.
  15.  
  16.    Note that not all cards support all features for all the various environment
  17.    mapping techniques (such as cubemapping and projected textures). For more
  18.    information on environment mapping, cubemapping, and projected textures, 
  19.    refer to the DirectX SDK documentation. 
  20.  
  21.  
  22. Path
  23. ====
  24.    Source:     MSSDK\Samples\Multimedia\D3D\EnvMapping\CubeMap
  25.    Executable: MSSDK\Samples\Multimedia\D3D\Bin
  26.  
  27.  
  28. User's Guide
  29. ============
  30.    The following keys are implemented. The dropdown menus can be used for the
  31.    same controls.
  32.       <Enter>     Starts and stops the scene
  33.       <Space>     Advances the scene by a small increment
  34.       <F1>        Shows help or available commands.
  35.       <F2>        Prompts user to select a new rendering device or display mode
  36.       <Alt+Enter> Toggles between fullscreen and windowed modes
  37.       <Esc>       Exits the app.
  38.  
  39.  
  40. Programming Notes
  41. =================
  42.    Cube-mapping is a technique which employs a 6-sided texture. Think of the
  43.    being inside a wall-papered room, and having the wallpaper shrink-wrapped
  44.    around an object. Cube-mapping is superior to sphere-mapping because the
  45.    latter is inherently view-dependant (spheremaps are constructed for one
  46.    particular viewpoint in mind). Cubemaps also have no geometry
  47.    distortions, so they can be generated on the fly using SetRenderTarget()
  48.    for each of the 6 cubemap's faces.
  49.  
  50.    Cube-mapping works with Direct3D texture coordinate generation. By setting
  51.    D3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR, Direct3D will generate cubemap 
  52.    texture coordinates from the reflection vector for a vertex, thereby making
  53.    this technique easy for environment-mapping effects where the environment
  54.    is reflected in the object.
  55.    
  56.    This sample makes use of common DirectX code (consisting of helper functions,
  57.    etc.) that is shared with other samples on the DirectX SDK. All common
  58.    headers and source code can be found in the following directory:
  59.       Mssdk\Samples\Multimedia\Common
  60.