Problem with hooking painting calls, are there alternative painting procedures to Win API?

Problem with hooking painting calls, are there alternative painting procedures to Win API?

Post by aetdat » Sat, 25 Jun 2005 01:12:23


Hi all,
I have run into a (for me) quite strange problem. I have this 3:rd
party app. That I want to draw a couple of strings in The actual
drawing goes just fine (using TexOut()), but the 3:rd party app.
Updates quite often when it draws its own animations. I have my own
drawing set to a timer interval (i.e every 50 ms) but it gets too
flickery.

I decided to investigate how and why this app. Redraws the complete
window every (even several times) time it draws a string or bitblt an
bitmap in the window. Maybe I could do my own painting just before
EndPaint was called.

I used a API hook and hooked UpdadteWindow, RedrawWindow, BitBlt,
TextOutA/W, BeginPaint, EndPaint, InvalidateRgn and InvalidateRect.

BitBlt and TextOutW was used by the 3:rd party app. To draw in it's
window.
UpdateWindow and RedrawWindow was never used?!
InvalidateRect, BeginPaint, EndPaint was only used when I resized/moved
the window and not any other time... (I guess this is Windows standard
to use this when window is resized etc.?)

Now finally to my questions:
Can anybody tell me why I can not see any UpdateWindow, BeginPaint,
InvalidateRect etc.? Does anybody have any suggestion on how I could do
what I want with any other method? Are there any WinAPI calls I have
forgot to hook?

Any help would be greatly appreciated!

Best Regards
AET