[Study Notes] I started learning directx.

Source: Internet
Author: User
I read several chapters in the book and repeatedly talked about the directdraw principle. Here I will use my own understanding to talk about this principle, which will facilitate future review. Now there may be many errors and vulnerabilities, later discovery is an improvement.
First, you need to understand the drawing and animation production principles of directdraw. First look at the figure below:

Here, DX divides our plotting process into three planes. First, we assemble the plot elements in the C plane into an image and then put them in the B plane, the B plane is exchanged with the plane, and the B plane is pushed to the screen for display. At the same time, the C plane re-assembles the next image, and then puts the assembled finished image into the plane, after switching between A and B, the image is changed, and the animation is realized by repeating the action.
The elements assembled on C include backgrounds, characters, and animations. Of course, sometimes they can be directly moved to the plane behind the scenes for assembly, thus saving the C plane.

This is generally the case. We need to continue learning and find a problem in the routine we see,
The following error occurs during running.
DDERR_NOCOOPERATIVELEVELSET
(Error code 0x887600D4)
Find only one webpage that does not know what text it is, as shown below:
DDERR_NOCOOPERATIVELEVELSET
(00000000000000000x887600d4)
Please refer to the following link for more information: zookeeper has been added when SetCooperativeLevel.
After painstaking efforts, we found that before applying the directdraw object, in addition to instantiation, we had to set the SetCooperativeLevel and tie the sentence of its draw carrier to the object.
TMD spent money to buy a book, and the routine actually saves this step, not to mention.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.