Page 1 of 2

A few things I need

Posted: Fri Jan 28, 2005 3:02 am
by Dreglor
i doing a remote computer program so i can get to my computer when im not there.
and i wondering how i would do some of the things like
right now i just know how to know the sever side (computer being controled)
how would you capture the mouse so it can be moved and click from the client
same for the keyboard
i thinking about sound (low priority)
video i remeber that there was a source some were were it would capture screens

and i need opinion on this, would it be faster (overall) to pack one loop with all the keyboard mouse video and sound data into pack memory then send it over the line or would it be faster to send it raw becasue the packer is kinda slow compressing even at lowend compression

Posted: Fri Jan 28, 2005 9:08 am
by dmoc
Why not use VNC?

Posted: Fri Jan 28, 2005 9:12 am
by blueznl
because vnc is no fun? :-)

hey, i'm game for an application like this! willing to share the code?

Posted: Fri Jan 28, 2005 10:13 am
by freedimension
Some thoughts about compression:

I think you should write some kind of Alpha-Compression, so that you don't have to send all data each loop, but only the data that has effectively changed. That would bring two advantages:
a) your refresh rate is lower and adapts to the changes on the screen automatically (i.e. if you watch a movie it will get laggy, but for office work it will just do fine)
b) your traffic is lower

You could reduce the number of colors used (i.e. use 16bit color depth)

Also you could catch all redraw events/messages windows is sending. Then only update the region indicated (that is especially good for the performance on the "server")

Combine all of the above, think something up.

If you succeed, I would be interested in the result as my experience is of theoretical nature only ;)

Posted: Fri Jan 28, 2005 3:36 pm
by Dreglor
blueznl wrote:because vnc is no fun? :-)

hey, i'm game for an application like this! willing to share the code?
most likly :)
right now i writing the base up for the server
but i'll stop when i get to the part were i need the capturing of i/o

Posted: Fri Jan 28, 2005 6:58 pm
by Rings
dreglor got my private message ?

Posted: Sat Jan 29, 2005 3:01 pm
by blueznl
u think i've figured out some of the problems, my major challenge was twofold:

1. is there a way to read the screen directly from memory, instead of 'grabbing' it, this to speed up things

2. euh... what was the other thing... euh.... :-)

Posted: Sat Jan 29, 2005 4:43 pm
by Inner
no, here is what you do though...

Take the first picture of the screen in total, every screen there after you calculate the diferents between the previous screen taken and only send the diferents.

Posted: Sun Jan 30, 2005 4:12 pm
by Kale
VNC Rocks! i have it on a server here at home. I love the way you can admin the server remotly through a web browser. very small, fast and simple! :)

Posted: Sun Jan 30, 2005 4:13 pm
by thefool
and free!

Posted: Sun Jan 30, 2005 5:09 pm
by blueznl
yeah well go and discourage me...

Posted: Sun Jan 30, 2005 5:43 pm
by kake26
freedimension wrote:Some thoughts about compression:

I think you should write some kind of Alpha-Compression, so that you don't have to send all data each loop, but only the data that has effectively changed. That would bring two advantages:
a) your refresh rate is lower and adapts to the changes on the screen automatically (i.e. if you watch a movie it will get laggy, but for office work it will just do fine)
b) your traffic is lower

You could reduce the number of colors used (i.e. use 16bit color depth)

Also you could catch all redraw events/messages windows is sending. Then only update the region indicated (that is especially good for the performance on the "server")

Combine all of the above, think something up.

If you succeed, I would be interested in the result as my experience is of theoretical nature only ;)
Forgive me I'm a bit of a code monkey. Compression is best done with zlib. zlib is a good library can do gzip compression. The good thing about gzip is the balance of speed and the achieved compression ratio. Zip is a possibility too, however you wouldn't as good compression and I'm not sure how it compares speed wise.

Posted: Sun Jan 30, 2005 5:49 pm
by thefool
well the included PB packer is also good enough. But Alpha-Compression is where the server ONLY sends changed data, wich is definently very important. I will even say that you cant make this working good enough if you dont have the difference-sender...

Posted: Sun Jan 30, 2005 6:43 pm
by freedimension
yep, of course you can gzip the alpha-data in a second step.

Posted: Sun Jan 30, 2005 11:30 pm
by Dreglor
well i got the compression pretty much figured out (at least what i want to do with it)Edit3: nothing wrong with my code :oops: