Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 23 results for
getupdaterect()
- Page 1
Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
…[100]=""; //hDesktop is desktop windown handler - GetDC(GetDesktopWindow());
GetUpdateRect
(hDesktop, &rectUpd, FALSE); c++; sprintf(s,"Top:%d…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
…'s poor code again... I don't need to use
GetUpdateRect
()? I knew it should be called before BeginPaint(). When I…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
I just looked at MSDN for
GetUpdateRect
(). It doesn't say anything about the window having to …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
Just one more thought. Assumming
GetUpdateRect
() works, the only context in which I can see it …
Changing background color of sstab
Programming
Software Development
12 Years Ago
by tendaimare
… Long, ByVal lpRect As Long) As Long Private Declare Function
GetUpdateRect
Lib "user32" (ByVal Hwnd As Long, lpRect As… On Error Resume Next If wMsg = &HF Then 'WM_PAINT
GetUpdateRect
sstHwnd, updateRect, False With updateRect Debug.Print "(" &…
Re: Good Day
Hardware and Software
Information Security
15 Years Ago
by Tedain
…, GetSysColorBrush, GetSystemMenu, GetSystemMetrics, GetTabbedTextExtentA, GetTabbedTextExtentW, GetTaskmanWindow, GetThreadDesktop, GetTitleBarInfo, GetTopWindow,
GetUpdateRect
, GetUpdateRgn, GetUserObjectInformationA, GetUserObjectInformationW, GetUserObjectSecurity, GetWinStationInfo, GetWindow, GetWindowContextHelpId, GetWindowDC, GetWindowInfo…
Re: Detecting image update changes (pixel changes)? to send over TCP/IP
Programming
Software Development
14 Years Ago
by Clawsy
… paint region -> why the coords are always 0 ??? PlatformInvokeUSER32.
GetUpdateRect
(handle, ref rect, false); lbl_region.Text = "x1=" + …quot;GetWindowDC", CharSet = CharSet.Auto)] public static extern int
GetUpdateRect
(IntPtr hwnd, ref RECT rect, bool erase); #endregion #region Public…
Re: Detecting image update changes (pixel changes)? to send over TCP/IP
Programming
Software Development
14 Years Ago
by Clawsy
… will be repainted. So I need to call in fact
GetUpdateRect
() function from C# but I don't know how. This… found... [DllImport("user32.dll")] public static extern int
GetUpdateRect
(int hwnd, [MarshalAs(UnmanagedType.Struct)] ref RECT lpRect, int bErase…
Re: Find the differences between two images and the locations of the differences
Programming
Software Development
14 Years Ago
by Clawsy
… which I use API to het the desktop and use
GetUpdateRect
() to get the rectangle chat changed in WM_PAINT event but…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
The invalid region is contained within the RECT member (.rcPaint) of the PAINTSTRUCT you used as an output parameter in the BeginPaint() call. It can be easily retrieved from there. I wrote the above without looking at your code. All your code is totally bad. You are using BeginPaint() incorrectly. You need to declare a PAINTSTRUCT variable…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
Usually in my WM_PAINT handlers I just declare a... PAINTSTRUCT ps; ...instead of a LPPAINTSTRUCT. However, that might be just me. When you do declare a LPPAINTSTRUCT though, this... hDC=BeginPaint(hwnd,&lpPS); won't work. I'd just do this... PAINTSTRUCT ps; HDC hDC; hDC=BeginPaint(hwnd,&ps); Here's a little …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
Nice program... (MFC isn't it?). Thats nice :). But I must get the painted region from the screen... and that's tricky cause the handler of the desktop from GetDesktopWindow() doesn't really work because it's hidden by all other top windows. Now I try to use GetDCEx(). If you have an idea I would be glad to help me... [CODE] hDesktop = GetDCEx(…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
No, that's my own style Win32 program. I don't use MFC. I've no experience with what you are trying to do, but I can say for absolute certainty that you can't use the WM_PAINT message of one window to draw into another. Just recently there was a post about this in the PowerBASIC forums. While I realize you are doing C++, discussions of this …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
Well, I'm not trying to paint on the screen; I'm trying to detect if something, anything new changed on the screen, anything that was painted. I wanted to do this in C# but I should understand winAPI first, in C++. For example the clock just changed. So I should get the rectangle coordonated of that part of the screen that was painted at that …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
I've never tried it with the desktop window, but what I'm going to say might work with the desktop window, unless its some special case and is disallowed there. If you can get the hwnd of any window (and you can get the hwnd of the desktop), you can 'hook' the internal window procedure of the window by setting an address of a WNDPROC you've …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
Sure I'm interested, that's what I search for a long time. On some forums others wanted to do something similar like me but it was said that Desktop Window is hidden behind everything (top windows). I actually don't even care about desktop... what I need is to detect the coordonates of "what changed in the image that I see on the screen".…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
Well, I took a shot at it and failed. However, I'll post the code I got. What seems to be happening is that Windows isn't allowing me to subclass the desktop window. When I call GetLastError() after the call to SetWindowLong() that would set the subclass proc - here MyDesktopHook(), I'm getting the error #5 which is "ACCESS DENIED". …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
I will try it. Sorry for delay... I have to study for university exams.. :|. I have a question. Let us say we can solve this issue with the desktop. If I have a window above the desktop, it will be detected. But if I have a window above that window... no changed rectangle of the desktop will be detected? cause it's not directly drawn to desktop, it…
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
I'm glad you're off the DESKTOP Window theme. That made me uneasy. I kind of figgured it was a 'special' window where speciial rules might apply, and my tests seemed to bear that out. What other coders do I'm not sure, but I never mess with the desktop. In terms of getting handles to other windows, the various Enum functions are useful for …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
So your answer is.... I any window above another window and not directly to the desktop will not trigger the desktop window paint window? (will not be detected?). If so... is there any solution? any idea? thank you.
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
In fact I am working at a desktop remote application and I need to optimize the transfer of the images from server to client and I thought the applications like TeamViewer just send the invalidated regions to the client so thats the key of high refresh rate and speed. That's why I need this. I tested your program and see the desktop and child …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Frederick2
I expect what you are attempting to do does not involve a process created by your program, so my idea about subclassing won't work. I found this as the 1st line in the remarks for SetWindowLong()... [QUOTE] Remarks The SetWindowLong function fails if the window specified by the hWnd parameter does not belong to the same process as the …
Re: Get the update (painted) rectangle using GetUpdateRect() in WM_PAINT (win32 api)
Programming
Software Development
14 Years Ago
by Clawsy
Basically I need the coordonates of the region that Windows paints on screen because I'm going to screenshot that area, make an image of it then send at the client. Let us say I would like to see your screen in my application. The server sends me your screen by taking screenshots and transfer them over a socket connection. Instead of sending a lot …
Search
Search
Forum Categories
Hardware/Software
Programming
Digital Media
Community Center
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Meet People
Forums
Top Members
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2024 DaniWeb® LLC