How to paint from a memory DC to another memory DC
-
I got the following problem: I got a DC in which I need to put an image comprised of more bitmaps. However, if I paint the bitmaps one by one, I get some flicker. So I need 1 memory DC to paint the bitmaps with. 1 memory DC to paint them in. And then this last memory DC will get bitblt-ed on the third and real DC. But the problem is that when I can't paint from the first DC to the second. I select the bitmaps in the first DC and bitblt them in the second. But when I do my stuff and bitblt the second DC upon the third, I get only white. Anybody got any clue what I'm messing up here? I didn't include code 'cause my routine is rather complicated and it's not written in C++ but here is something that may be of use: 1. I create both memory DCs using "CreateCompatibleDC(REALDC)". 2. I select bitmaps in the first DC using "SelectObject (hdcMemory, myBITMAP)". 3. I simply bitblt from first DC to second DC at the desired coordinates. 4. I repeat steps 2. and 3. for 4 images, bitblt-ed at various coordinates within the second DC. 5. Now I bitblt the second DC in the real DC, the third one, the visual source. All is white................ -= E C H Y S T T A S =- The Greater Mind Balance
-
I got the following problem: I got a DC in which I need to put an image comprised of more bitmaps. However, if I paint the bitmaps one by one, I get some flicker. So I need 1 memory DC to paint the bitmaps with. 1 memory DC to paint them in. And then this last memory DC will get bitblt-ed on the third and real DC. But the problem is that when I can't paint from the first DC to the second. I select the bitmaps in the first DC and bitblt them in the second. But when I do my stuff and bitblt the second DC upon the third, I get only white. Anybody got any clue what I'm messing up here? I didn't include code 'cause my routine is rather complicated and it's not written in C++ but here is something that may be of use: 1. I create both memory DCs using "CreateCompatibleDC(REALDC)". 2. I select bitmaps in the first DC using "SelectObject (hdcMemory, myBITMAP)". 3. I simply bitblt from first DC to second DC at the desired coordinates. 4. I repeat steps 2. and 3. for 4 images, bitblt-ed at various coordinates within the second DC. 5. Now I bitblt the second DC in the real DC, the third one, the visual source. All is white................ -= E C H Y S T T A S =- The Greater Mind Balance
can u BitBlt() first memory DC to real DC properly? default size of memory DC is 1x1 pixels. did u set suitable size for all other memory DCs?
A special image tool for C++ programmers, don't miss it! The world unique Software Label Maker is here for you and me ... A nice hyper tool for optimizing your MS html-help contents.
-
can u BitBlt() first memory DC to real DC properly? default size of memory DC is 1x1 pixels. did u set suitable size for all other memory DCs?
A special image tool for C++ programmers, don't miss it! The world unique Software Label Maker is here for you and me ... A nice hyper tool for optimizing your MS html-help contents.
I can't paint directly to the real DC 'cause I need to put more images. So I need an intermediate DC in which to dump the pictures piece by piece and then bitblt in the original DC. I set the size of the memory DC by selecting a bitmap of the desired size in it. Is that correct. -= E C H Y S T T A S =- The Greater Mind Balance
-
I got the following problem: I got a DC in which I need to put an image comprised of more bitmaps. However, if I paint the bitmaps one by one, I get some flicker. So I need 1 memory DC to paint the bitmaps with. 1 memory DC to paint them in. And then this last memory DC will get bitblt-ed on the third and real DC. But the problem is that when I can't paint from the first DC to the second. I select the bitmaps in the first DC and bitblt them in the second. But when I do my stuff and bitblt the second DC upon the third, I get only white. Anybody got any clue what I'm messing up here? I didn't include code 'cause my routine is rather complicated and it's not written in C++ but here is something that may be of use: 1. I create both memory DCs using "CreateCompatibleDC(REALDC)". 2. I select bitmaps in the first DC using "SelectObject (hdcMemory, myBITMAP)". 3. I simply bitblt from first DC to second DC at the desired coordinates. 4. I repeat steps 2. and 3. for 4 images, bitblt-ed at various coordinates within the second DC. 5. Now I bitblt the second DC in the real DC, the third one, the visual source. All is white................ -= E C H Y S T T A S =- The Greater Mind Balance
Not a direct reply, but you should look at Image Viewer Utility[^] by PJ Arends. It should help you a lot while debugging the problem. My guess is that you have incompatible bitmaps selected into your DCs.
-
I can't paint directly to the real DC 'cause I need to put more images. So I need an intermediate DC in which to dump the pictures piece by piece and then bitblt in the original DC. I set the size of the memory DC by selecting a bitmap of the desired size in it. Is that correct. -= E C H Y S T T A S =- The Greater Mind Balance
do u know the differece between testing and final program?
A special image tool for C++ programmers, don't miss it! The world unique Software Label Maker is here for you and me ... A nice hyper tool for optimizing your MS html-help contents.
-
do u know the differece between testing and final program?
A special image tool for C++ programmers, don't miss it! The world unique Software Label Maker is here for you and me ... A nice hyper tool for optimizing your MS html-help contents.
I don't know what you're trying to suggest here and I don't think I'm gonna like the sound of it. But please, give it a shot ::- ). -= E C H Y S T T A S =- The Greater Mind Balance