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. |
This section describes the steps required to implement minimal DirectDraw HAL functionality in your display driver. This section assumes that you do not wish to move an existing DirectDraw HAL from desktop Windows to Windows CE. For information on doing that, please see the chapter, Porting your DDHAL from the Desktop.
Before you continue, you will need the following items to implement a simple DDHAL in your display driver:
TARGETNAME=BINARYNAME
section of your sources file, and
ends with the .def extension).
First, modify the file used to export functions from your compiled binary. It should export the HALInitfunction. You can consult the sample driver source code file DDI.def to see how this is done. The HALInitfunction is part of the ddgpe.lib, which you should have already linked to your project.
Next, modify your include path to include drive:\wince212\public\directX\oak\inc. This should be the path to the following file:
This is a public header file that can be used by any display driver and should not be modified.
Copy the following header file from the basic HAL source code into an appropriate location inside your display driver's build directory:
This header file is private to your display driver, and can be modified to contain whatever you like. You must customize this file to implement the IN_VBLANKand IS_BUSYmacros, since they are required by the sample DDHAL implementation.
Now copy the following source code files from the basic HAL source code from the sample display drivers into your display driver's build directory, and add them to the appropriate build files:
Finally, compile and build your display driver and ensure that it continues to work properly. Once you have verified that it is still functional, your driver is ready to be tested with DirectDraw programs. Keep in mind that the code is not in an optimized state, and will require some customization to improve performance. See Taking Advantage of DDGPE, and Customizing Your DDHAL, for more information.
Last updated on Tuesday, July 13, 2004