Click here to Skip to main content
15,893,266 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi all,

I want to built a transparent dialog over the pixture box,where display CCD video.
I use:
C++
SetLayeredWindowAttributes(this->GetSafeHwnd(),RGB(255,255,255),128,1) //function,
//and on 
paint()
{
CPaintDC dc(this);
CRect rect;
GetClientRect(&rect); 
dc.fillsolidrect(rect,RGB(255,255,255))  }

So I can draw red/Green line or rectangle on transparent dialog, but I want to draw line by mouse's leftbuttondown/up/move.
I find only narrow region can response not whole client region.
How can i do ?
I want to draw lines/rectangle on dynamic video.
Posted
Updated 30-Jul-10 21:12pm
v2

1 solution

One workaround to solve this issue.

Create transparent window in alpha transparency method, with very small alpha value.
SetLayeredWindowAttributes(0,1,LWA_ALPHA);
Now you will get transparent look and Mouse move messages.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900