Skip to main content.
January 4th, 2006

Quick update about DSharingu

dsharingu/dsharingu_06_01_04.png
It’s past 5 AM. Today I dedicated quite a bit of time to DSharingu (still old release). I finally got some interaction going. The screenshot shows the view that I have of the home server on the PC in my bedroom. I launched Firefox remotely and browsed around.
It took me some time to get to the right function.. SendInput(). Once I found out about it, it wasn’t too hard to use it. However there is still a problem: when interacting with the remote DSharingu window, the remote instance locks !
I think that it’s probably due to the fact that the main loop receives input event remote messages synchronously. So, I tried to relocate the network message input system from the synchronous main loop, into a separate thread. That should solve it, but I’m still not done. I really want to use multi-thread only for those messages that need it, the simulated input messages.
Compression needs more work. I have some interesting ideas, but right now, I want to focus on basic features… optimizations can wait.

I also modified my windowing system. I no longer simulate sub-windows (like the translucent shell frame form the previous version). Every sub-window is now an actual Windows’ child window. This saves me a lot of work… I like to do some basic wrapping, but it’s too easy to fall into the trap of wanting to write a whole sub-OS. Right now, I just need to get things done !

Thanks to my friends in Italy (Jag and Rasty !), my family is getting back to wireless Internet use. Now, more than ever, I need this remote administration thing. Once all features are up (no self-locking and keyboard input), and once things are optimized for the right bandwidth, I should be able to remotely show and fix things !

The program as it is now, will allow me to accept connections, because I have full access to network ports at home.. however, this may not work in the office, where I’ll be firewalled like my parents are.. both can call out, but neither can accept a call 8(
For cases like that one, I plan (hopefully with some help !) to convert DSharingu to work as a Skype plug-in. Skype is very flexible, making it easy to transfer data without having to worry about firewalls.

We’ll see !
zzzzzzzzzzzzzzzzz

Posted by Davide Pasca in Image-processing, Programming

This entry was posted on Wednesday, January 4th, 2006 at 5:44 am and is filed under Image-processing, Programming. You can follow any responses to this entry through the comments RSS 2.0 feed. You can leave a response, or trackback from your own site.

11 Responses to “Quick update about DSharingu”

  1. rince says:

    Ehhh maybe it locks because of some simpler reason! Can you debug the lock?

  2. Davide Pasca says:

    The remote machine is somehow stuck in the WindowProc. For example if I press the minimize button, the WindowProc seems stuck in the WM_NCCLIENTsomething. I should try debug more. But I figured that it’s a generic problem because it happens either if i try to move the window or press one of the buttons. So, it’s basically about intereacting with it.

  3. rasty says:

    The skype plugin stuff is very interesting as Skype has some excellent networking you can use for your stuff! I’m currently looking forward to this http://www.automatetechnology.com/html/com/tunesup/

    moo!

  4. Davide Pasca says:

    I dunno about the background tune thing. Seems a bit silly.
    However there are times when one wants to share a part of a track.. for example mentioning a new CD or something.
    It could become succesful, but definitely not when used for elevator music !

  5. rince says:

    Do you mean that it keeps getting the same message very frequently and doesnt have time to process anything else or it gets
    stuck trying to process that WM_NCCLIENT message?

  6. Davide Pasca says:

    Stuck in the DefWindowProc() ..never leaves ! ..strange

  7. rince says:

    Hhhmmmmmmmm and if you dont call DefWindowProc for that message and just return then what happens?

  8. Davide Pasca says:

    I wouldn’t suggest trying that. DefWindowProc() needs to be calle dif one wants to be able to move the window etc.
    Also I don’t have a direct connection between SendInput() and DefWindowProc(). I mean, I send out in the wild events with SendInput(), but the resulting messages passing through DefWindowProc() are only byproducts which I have no direct connection to.
    Anyhow we are close to be able to issue SendInput() on a separate thread as soon as the remote data comes. That should allow me to truly disconnect SendInput() from the main loop. In fact, SendInput() is a system-wide thing, and there is no need for it to be synchronized to the issuing application loop.

  9. rince says:

    No, DefWindowProc doesnt always have to be called, sometimes you override processing for certain messages. You said that it
    gets stuck in a case of a specific message, so I was wondering if you needed some custom processing for that message.

  10. Davide Pasca says:

    Right, not all messages need to be passed, but passing every message shouldn’t lead to such problems anyway.
    Yesterday night (this morning 8), I completed the multi-thread thing.. but it didn’t seem to solve the problem 8(
    I had to rewrite the MT code for the socket I/O anyway, so it wasn’t a waste of time… but would have been nice if that solved the the problem !

  11. Davide Pasca says:

    Ahhh.. nevermind.. I wasn’t handling correctly the callback in the thread to get the input message data. It’s fixed now.. cool 8)

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <code> <em> <i> <strike> <strong>