remote monitoring application
CodeGuru Home VC++ / MFC / C++ .NET / C# Visual Basic VB Forums Developer.com
Results 1 to 7 of 7

Thread: remote monitoring application

  1. #1
    Join Date
    Jan 2012
    Location
    Cochin, India
    Posts
    8

    Post remote monitoring application

    Hi all
    I'm developing an employee monitoring software in C++. It uses TCP connections for client-server interaction. I've define some commands for remote controlling like SHUTDOWN, PRINTSCR, MESSAGE GETINFO etc. Everything works fine except the remote screen previews. In thName:  1.png
Views: 103
Size:  61.8 KBName:  2.jpg
Views: 75
Size:  15.5 KBName:  3.jpg
Views: 85
Size:  13.6 KBName:  4.png
Views: 72
Size:  87.7 KBe server app. it should be possible to view multiple remote screens at a time. The server sends periodic requests to clients to send its screenshots back. The request includes the required picture size also so that the server need not resize the full size image, and also it reduce network overheads.

    The client application captures, resizes, convert to png format and sends it over tcp connection to server. The server converts it back to BMP and assigns to the bitmap control in a dialog.

    This works fine in localhost. But in vmware the preview becomes corrupted. The bitmap loads fine in the picture control. But the image is corrupted. Anyone please suggest me a solution. Is tcp connection reliable?

    I've attatched 4 files, the screenshots of server application.

  2. #2
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    3,643

    Re: remote monitoring application

    looks like you'll ave to implement some form of flow control to make sure all packets arrive before you try to display the bitmap.

  3. #3
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    3,643

    Re: remote monitoring application

    TCP should be reliable yes, but are you sure you're using TCP and not UDP (which isn't).

    ALso, TCP only guarantees delivery and ordering for an entire packet.
    If you split the transmition in multiple TCP packets, there is no guarantee those packets will arrive in order (only that packets themselves are complete).

  4. #4
    Join Date
    Feb 2014
    Posts
    14

    Re: remote monitoring application

    Here, this may help out.

    Last edited by CoriNEIT; February 12th, 2014 at 08:50 AM.

  5. #5
    Join Date
    Jan 2012
    Location
    Cochin, India
    Posts
    8

    Re: remote monitoring application

    thanks all for your replies.

    I'm sending the whole data as such. Its around some 60kB to 100kB of data. Also I increased the send and receive buffer to 128kB, using setsockopt function.

    In the server side, instead of setting it to the picture control, i saved the image to file. And I did this in client side also. When I did a file compare of these two files, the file size were same. But there were some mismatches on compare. I used comp command to compare.

  6. #6
    Join Date
    Jan 2012
    Location
    Cochin, India
    Posts
    8

    Re: remote monitoring application

    Anybody please suggest

    Which is more efficient?

    1. Using Windows Terminal services
    OR
    2. Manually taking screenshots, converting it to PNG and sending?

    My requirement is that it should be possible to show multiple screens at a time on server application.

  7. #7
    Join Date
    Apr 2000
    Location
    Belgium (Europe)
    Posts
    3,643

    Re: remote monitoring application

    RDP is more efficient, since it doesn't need to send everything, it's optimized to only send the parts that have changed, and can do this at the GDI primitives level.

    also

    what you're doing and terminal services is not the same thing. Remote management/remote assistance comes close, but it's still not the same, you can't just "spy" over RDP without remote approval.

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  


Azure Activities Information Page

Windows Mobile Development Center


Click Here to Expand Forum to Full Width

This is a CodeGuru survey question.


Featured


HTML5 Development Center