Printing Bitmaps from a Frame Grabber (Re-post of earlier question)
-
Hi all: Thanks for the suggestions in my original post... I think I should have worded my question differently though. Thre original question: "I am working on an MFC application (Visual Studio/C++) that has to grab a screen shot from a frame grabber and send it to the default printer with landscape orientation. This has to be done with no operator intervention other than clicking on a "Print" button in the main dialog - no preview or print dialog. I'm able to grab the frame, but I'm having no success with the printing." What I really have is not a bitmap in the MFC sense, but a pointer to a big bunch of pixels. I can not seem to figure out how to get those pixels in a form that I can print - what comes out of the printer is just a black rectangle. Again, any help would be appreciated. Bob.
-
Hi all: Thanks for the suggestions in my original post... I think I should have worded my question differently though. Thre original question: "I am working on an MFC application (Visual Studio/C++) that has to grab a screen shot from a frame grabber and send it to the default printer with landscape orientation. This has to be done with no operator intervention other than clicking on a "Print" button in the main dialog - no preview or print dialog. I'm able to grab the frame, but I'm having no success with the printing." What I really have is not a bitmap in the MFC sense, but a pointer to a big bunch of pixels. I can not seem to figure out how to get those pixels in a form that I can print - what comes out of the printer is just a black rectangle. Again, any help would be appreciated. Bob.
Did you use CreateDIBitmap[^] to get a HBITMAP? How exactly are you passing your bitmap to the printer?
-
Hi all: Thanks for the suggestions in my original post... I think I should have worded my question differently though. Thre original question: "I am working on an MFC application (Visual Studio/C++) that has to grab a screen shot from a frame grabber and send it to the default printer with landscape orientation. This has to be done with no operator intervention other than clicking on a "Print" button in the main dialog - no preview or print dialog. I'm able to grab the frame, but I'm having no success with the printing." What I really have is not a bitmap in the MFC sense, but a pointer to a big bunch of pixels. I can not seem to figure out how to get those pixels in a form that I can print - what comes out of the printer is just a black rectangle. Again, any help would be appreciated. Bob.