Upcoming Events
Unite 2010
11/10 - 11/12 @ Montréal, Canada

GDC China
12/5 - 12/7 @ Shanghai, China

Asia Game Show 2010
12/24 - 12/27  

GDC 2011
2/28 - 3/4 @ San Francisco, CA

More events...
Quick Stats
113 people currently visiting GDNet.
2406 articles in the reference section.

Help us fight cancer!
Join SETI Team GDNet!
Link to us Events 4 Gamers
Intel sponsors gamedev.net search:

  Contents

 Introduction
 DirectX
 DirectDraw
 Direct3D
 Rendering Engine
 File Format
 DirectX and COM
 Summary and
 Appendix


 Printable version

 


Direct3D

After taking a brief look at the capabilities of DirectDraw, let us come to the overview of Direct3D.

Introduction

Direct3D, is part of DirectX and is the component that helps us integrate 3D into Windows applications. Direct3D is used to develop real-time, interactive, 3D applications.

For developing these applications, Direct3D provides the following features:

Device independence
- helps shield the applications from the vagaracies of the different hardware platforms. As a result of this, applications become independent of the hardware platform and hence become more protable
Common driver model to hardware
- guarantees to applications, that all the drivers supporting Direct3D will support a defined minimal set of features and capabilities. Due to this, applications developed using such features will work on all hardware platforms. Additionally, Direct3D provides a specification to all hardware developers, which help their cards support the various Direct3D features. Applications using these features will see a boost in performance
Eases addition of 3D to applications
- as Direct3D provides a standard mechanism and a standard set of algorithms for 3D graphics, applications requiring such features can be developed much faster. Additionally, the time spent in developing such well known and well defined techniques is saved, helping in developing applications faster
Transparent access to hardware acceleration
- is one of the very important features of Direct3D, which uses the hardware support, if available. In case a hardware platform does not support a certain feature, Direct3D provides an equivalent implementation in software. This choice of using the hardware features if available, is transparent to the user. The application, at runtime can detect the hardware capabilities and use them if present

In addition to these features, Direct3D provides a fast software based rendering of the full 3D rendering pipeline. Applications developed using Direct3D are scaleable as a part or whole of the 3D rendering pipeline can be in the hardware and Direct3D can make use of it, if it is detected.

A possible restriction on Direct3D is the tight restriction with DirectX and its different components.

The features of Direct3D are available to the user in two different ways. These are through the two modes of Direct3D, namely: the retained mode and the immediate mode. The retained mode is a high-level interface, while the immediate mode is a lower-level interface to the features of Direct3D. The two modes are discussed in details in separate tutorials. For detailed discussions of the retained mode and the immediate mode, refer [8] and [7] respectively.

Place

Figure 1 shows the different parts of Direct3D, in relation to the other modules of a Win32 system.

place
Figure 1: Place of Direct3D

From figure 1, it is clear that the retained mode uses the immediate mode, transparent to the developer using the retained mode. The developer is not made aware of this usage. From the figure, it is also clear that the retained mode also uses some features of DirectDraw. The retained mode, the immediate mode and the Direct3D HAL, together, constitute the Direct3D component of DirectX.

Though many of the existing programs for 3D graphics on the Windows platform talk to the different parts directly, it is envisaged that the DirectDraw and Direct3D components of DirectX will be incorporated into future versions of Win32 systems. Any system providing 3D, will have to use Direct3D to provide its own features.

Layers

Direct3D uses two layers, namely the Hardware Abstraction Layer (HAL) and the Hardware Emulation Layer (HEL).

All of the features of Direct3D are built on top of the HAL, which provides hardware independence and makes applications portable.

The HEL is a companion of Direct3D and provides software emulation for the features of the 3D rendering pipeline, not supported by the hardware. This layer is tightly integrated with the DirectDraw HAL and the Graphics Device Interface (GDI) driver of the Win32 system. This layer helps provide a unified driver model for accelerated 3D.


Next : Rendering Engine