KenE Posted August 27, 2009 Share Posted August 27, 2009 I'm using L|M|TER's Webcam UDF (see this thread) and I'm trying to overlay a GUI graphic object on top of that, but the video preview always blocks the graphic I create. (Graphics are stuck behind.) I've also tried drawing it using GDI+, but whatever I draw is immediately erased by the next video frame. Anyone have any ideas?For those who want to know why, read on...I need to be able to take ID photos from a standard webcam. The software I need to get the captured images into only supports portrait oriented photos. The preview image cannot be rotated, so my thought is to just crop off equally from the left and right sides (of a landscape image) to create the correct aspect ratio. The people that will be taking the photos are for the most part non-computer users, so I need to make this really easy for them. Getting them to visually center someone within a frame would not work out, so I need the preview image to accurately reflect what the final saved image will be. From my 640 x 480 image, I need to trim about 140 pixels of the left and right of the preview image. My intent was to just draw over that portion of the screen with a GUI graphic. I also need to leave room in that gui for some button controls. Maybe there is a better way that I haven't thought of yet. Hopefully someone can point me in the right direction! Link to comment Share on other sites More sharing options...
dantay9 Posted August 28, 2009 Share Posted August 28, 2009 If you don't have a window already, I would suggest making a child window on top of the media player. Then set the extended style to $WS_EX_TOPMOST. Use WinSetTrans to set the overlay transparency. There are examples of hooking the time when the media player moves so the overlay will move too on the forum. By the way, I have never tried something like this with videos, so I don't know exactly what is going to happen. Hope this puts you on your way. Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now