Click here to Skip to main content
15,903,594 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
AnswerRe: Unicode problem Pin
CPallini26-Oct-09 4:34
mveCPallini26-Oct-09 4:34 
GeneralRe: Unicode problem Pin
m_mun26-Oct-09 4:38
m_mun26-Oct-09 4:38 
Questionmodifystyle not working Pin
prithaa26-Oct-09 4:08
prithaa26-Oct-09 4:08 
AnswerRe: modifystyle not working Pin
KarstenK26-Oct-09 4:32
mveKarstenK26-Oct-09 4:32 
AnswerRe: modifystyle not working Pin
Covean26-Oct-09 4:37
Covean26-Oct-09 4:37 
QuestionRe: modifystyle not working Pin
David Crow26-Oct-09 4:39
David Crow26-Oct-09 4:39 
AnswerRe: modifystyle not working Pin
Kushagra Tiwari26-Oct-09 23:02
Kushagra Tiwari26-Oct-09 23:02 
QuestionDraw a FRAMERECT() on top of ONTIMER() image refresh! Pin
esc32126-Oct-09 4:07
esc32126-Oct-09 4:07 
Hey Guys,

I am in need of a method to keep my rectangle frame, drawn with OnMouseMove() and OnDraw() with coords specified from OnLButtonUp() and OnLButtonDown(), on the top of an image that is being updated with and OnTimer() function every some odd milliseconds. Here are a few code snippets:

Drawing the framerect:

void LiveFeed::OnMouseMove(UINT nFlags, CPoint point)
{
	if (GetCapture() == this)
	{
	m_ptEnd = point;
	Invalidate();
	}
	CRect r(m_ptStart, m_ptEnd);
	CPaintDC dc(this);
	dc.GetSafeHdc();
	dc.FrameRect(&r,0);
}
void LiveFeed::OnDraw(CDC* pDC)
{
	CRect r(m_ptStart, m_ptEnd);
pDC->FrameRect(&r,0);

}


Updating the image with OnTimer() The BlitX function just transfers an image to the specified window from a camera:

void LiveFeed::OnTimer(UINT nIDEvent) 
{
	XC_BlitX(cam->GetHandle(), m_hWnd, 0, 0, 640, 512, Window);
}


This setup causes my FrameRect to be drawn but then it gets covered by my image being updated. I need a way to draw on top of a refreshing image. I think I may need to use some sort of graphic control, but I am really unsure where to start to tackle this problem!

Any help would be appreciated and thanks in advance for taking the time to read my post!

-esc321
AnswerRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
CPallini26-Oct-09 4:29
mveCPallini26-Oct-09 4:29 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
KarstenK26-Oct-09 4:35
mveKarstenK26-Oct-09 4:35 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
CPallini26-Oct-09 4:47
mveCPallini26-Oct-09 4:47 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
esc32126-Oct-09 4:37
esc32126-Oct-09 4:37 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
CPallini26-Oct-09 4:54
mveCPallini26-Oct-09 4:54 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
Iain Clarke, Warrior Programmer26-Oct-09 5:13
Iain Clarke, Warrior Programmer26-Oct-09 5:13 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
CPallini26-Oct-09 5:27
mveCPallini26-Oct-09 5:27 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
Iain Clarke, Warrior Programmer26-Oct-09 5:12
Iain Clarke, Warrior Programmer26-Oct-09 5:12 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
esc32126-Oct-09 5:27
esc32126-Oct-09 5:27 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
esc32126-Oct-09 5:41
esc32126-Oct-09 5:41 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
Iain Clarke, Warrior Programmer26-Oct-09 5:55
Iain Clarke, Warrior Programmer26-Oct-09 5:55 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
esc32126-Oct-09 6:02
esc32126-Oct-09 6:02 
GeneralRe: Draw a FRAMERECT() on top of ONTIMER() image refresh! Pin
Iain Clarke, Warrior Programmer26-Oct-09 6:10
Iain Clarke, Warrior Programmer26-Oct-09 6:10 
QuestionIAccessible problem in Google Chrome.... Pin
onlyjaypatel26-Oct-09 3:19
onlyjaypatel26-Oct-09 3:19 
AnswerRe: IAccessible problem in Google Chrome.... Pin
Hans Dietrich26-Oct-09 12:58
mentorHans Dietrich26-Oct-09 12:58 
GeneralRe: IAccessible problem in Google Chrome.... Pin
onlyjaypatel26-Oct-09 22:52
onlyjaypatel26-Oct-09 22:52 
GeneralRe: IAccessible problem in Google Chrome.... Pin
Hans Dietrich27-Oct-09 4:32
mentorHans Dietrich27-Oct-09 4:32 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.