Microsoft Windows CE 3.0  

Customizing Your DDHAL

Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.

Once you have implemented a basic display driver with DirectDraw support, you will most likely wish to customize it to take complete advantage of the hardware you're using. Before you try to extend your new DDHAL implementation, you should be familiar with the DirectDraw Hardware Abstraction Layer specification that is part of the DirectDraw DDK.

Below are possible additions you can make to your display driver to boost its performance and enhance its capabilities. The first section, Performance Enhancements, discusses options you have for hardware acceleration. The next section, Adding New Functionality, briefly describes what is necessary to add features to your DirectDraw HAL implementation.

Performance Enhancements

The basic DDHAL implementation has no internal hardware acceleration. All hardware acceleration is performed through extensions you have made to DDGPE. While acceleration accomplished in this way is acceptable, copying some or all of the acceleration into the DDHAL can make your driver even faster.

Once you have identified a function that you wish to accelerate, it is up to you to decide whether you want to implement acceleration in your DDGPE, your DDHAL, or both. The DDGPEimplementation and sample code allow you to perform your HAL acceleration in your DDGPE-based class. The DDGPEmodel also allows you to move many acceleration functions (excluding acceleration of some line drawing functions) into the DDHAL, and to use these DDHAL functions from within your DDGPEclass.

Adding New Functionality

You can add new functionality to your DDHAL implementation by modifying the device capabilities and callback structures, and by implementing new callbacks. You should consult the DirectDraw Hardware Abstraction Layer specification for more information on extending your DDHAL.



 Last updated on Tuesday, July 13, 2004

© 2004 Microsoft Corporation. All rights reserved.