Writing Video conference software for Windows

Discussion in 'Python' started by Paolo Pantaleo, Sep 19, 2006.

  1. Hi,

    I need to write a software that allow to see the desktop and hear the
    microphone capture of a remote PC across a network. I need to do that
    for a unviresity assignement. The software must run on Windows. Since
    I like Python very much I am thinking to write that software in
    Python. Do you thinkit is a good choice? Are there libraries for audio
    compression (OGG or MP3 or maybe GSM or something like realaudio) and
    video compression (btw what can be some good libraries to transmit
    images of a desktop in a bandwidth-efficent way?). What about capture
    of audio and screen? (Probably i will need some Win32 system call,
    there are bindings in Python, aren't they?)

    If I needed to write some Python modules in C, would it be difficult?

    Can some language like C# or C++ may be better?

    Thnx
    PAolo

    --
    if you have a minute to spend please visit my photogrphy site:
    http://mypic.co.nr
     
    Paolo Pantaleo, Sep 19, 2006
    #1
    1. Advertising

  2. Paolo Pantaleo

    Jordan Guest

    If you're going to need win32 system access use the win32all python
    extension (very, very good extension). Do you need single frame image
    capture, or constant video stream? PIL can be used for the first, it
    might also be usable for video, I'm not sure. For sound, python comes
    with some built in libraries, but you should also take a look at
    pysonic http://www.cs.unc.edu/Research/assist/developer.shtml. For the
    bandwidth efficiency issue, what type of connection are you using? The
    socket module is quite capable of transmiting whatever data you have,
    so unless you're thinking of implementing some mini bittorrent like
    network in an attempt to save bandwidth I don't know what you can do
    about that. There's an extension called IPqueue which might give you
    somewhere to start for packet/bandwidth manipulation. Check out The
    Vaults of Parnassus, which has a lot of stuff (including ogg/mp3
    converters last time a check). Big question, is this supposed to act
    like a remote desktop, or just show what's happening? Start by
    searching Google, it's very useful.

    Paolo Pantaleo wrote:
    > Hi,
    >
    > I need to write a software that allow to see the desktop and hear the
    > microphone capture of a remote PC across a network. I need to do that
    > for a unviresity assignement. The software must run on Windows. Since
    > I like Python very much I am thinking to write that software in
    > Python. Do you thinkit is a good choice? Are there libraries for audio
    > compression (OGG or MP3 or maybe GSM or something like realaudio) and
    > video compression (btw what can be some good libraries to transmit
    > images of a desktop in a bandwidth-efficent way?). What about capture
    > of audio and screen? (Probably i will need some Win32 system call,
    > there are bindings in Python, aren't they?)
    >
    > If I needed to write some Python modules in C, would it be difficult?
    >
    > Can some language like C# or C++ may be better?
    >
    > Thnx
    > PAolo
    >
    > --
    > if you have a minute to spend please visit my photogrphy site:
    > http://mypic.co.nr
     
    Jordan, Sep 19, 2006
    #2
    1. Advertising

  3. 19 Sep 2006 09:42:51 -0700, Jordan <>:
    > If you're going to need win32 system access use the win32all python
    > extension (very, very good extension). Do you need single frame image
    > capture, or constant video stream? PIL can be used for the first, it
    > might also be usable for video, I'm not sure.

    Well I need something like 5-10 fps. An issue is the comression
    method: MPEG and friends aren't good (I think) for compressing stuff
    with sharp borders. Maybe I could use A sequence of PNG images, but it
    isn't a great solution.

    For sound, python comes
    > with some built in libraries, but you should also take a look at
    > pysonic http://www.cs.unc.edu/Research/assist/developer.shtml. For the
    > bandwidth efficiency issue, what type of connection are you using? The
    > socket module is quite capable of transmiting whatever data you have,
    > so unless you're thinking of implementing some mini bittorrent like
    > network in an attempt to save bandwidth I don't know what you can do
    > about that. There's an extension called IPqueue which might give you
    > somewhere to start for packet/bandwidth manipulation. Check out The
    > Vaults of Parnassus, which has a lot of stuff (including ogg/mp3
    > converters last time a check). Big question, is this supposed to act
    > like a remote desktop, or just show what's happening? Start by
    > searching Google, it's very useful.

    Well the bandwidth issue is most of all related to video compression
    (see above). Well maybe 256 kbps would be nice.

    It should just show what's happening.


    PAolo
     
    Paolo Pantaleo, Sep 21, 2006
    #3
  4. Paolo Pantaleo

    sturlamolden Guest

    Paolo Pantaleo wrote:

    > Well I need something like 5-10 fps. An issue is the comression
    > method: MPEG and friends aren't good (I think) for compressing stuff
    > with sharp borders. Maybe I could use A sequence of PNG images, but it
    > isn't a great solution.


    You probably want to use is VideoCapture for capturing digital video
    from e.g. USB webcameras (videocapture.sourceforge.net), Twisted for
    asynchronous sockets (twistedmatrix.com), and PyMedia for video and
    audio codec (pymedia.org). For GUI and graphics there are a number of
    candidates, e.g. PyGTK or PyGame.

    Video conference is an I/O bound task (except for the audio/video
    codec), and you will consequently gain nothing by using C++ over
    Python. The only part that is CPU-bound part (where C++ could
    theoretically be better) is the media codec, but you can leave that to
    PyMedia's C extensions. Python will most likely not be the bottleneck!

    Sure, you could use C++ instead. However, you would quickly be
    frustrated with Windows' extremely complex native APIs. E.g. DirectShow
    for digital video capture, Winsock for asynchronous sockets,
    Microsoft's multimedia APIs for codec, and perhaps MFC for GUI. Using
    Python is a good advice!
     
    sturlamolden, Sep 21, 2006
    #4
  5. Paolo Pantaleo

    Ravi Teja Guest

    > I need to write a software that allow to see the desktop

    That would be the VNC protocol. Don't reinvent the wheel.

    VNC is relatively efficient in that it only updates the portions of the
    screen that changed.

    Maybe this project could be your starting point.
    PyVNC
    http://bdash.net.nz/blog/2005/07/17/pyvnc-the-beginnings-of-a-python-vnc-client/

    > and hear the
    > microphone capture of a remote PC across a network.
    > I need to do that
    > for a unviresity assignement. The software must run on Windows. Since
    > I like Python very much I am thinking to write that software in
    > Python. Do you thinkit is a good choice? Are there libraries for audio
    > compression (OGG or MP3 or maybe GSM or something like realaudio)


    PyMedia can record and it works for mp3 and oggs.

    > and video compression (btw what can be some good libraries to transmit
    > images of a desktop in a bandwidth-efficent way?).


    See above. You can lossy compress images in VNC.

    > (Probably i will need some Win32 system call,
    > there are bindings in Python, aren't they?)


    The above modules should take care of everything. BTW, PIL can take
    screen shots if you want to do this manually.

    You need to create a streaming server for audio. Take a look at Edna, a
    streaming MP3 server. http://edna.sourceforge.net/

    Also of interest ... Twisted and Shtoom.

    And finally... since you are on Windows - you can just try using the
    NetMeeting ActiveX control through Python. It already does everything
    you want.

    Disclaimer: While I tinkered with many of the above, I have not used
    most of the above projects recently. These are just leads for you to
    explore.
     
    Ravi Teja, Sep 22, 2006
    #5
  6. Thnx everybody for the precious help :)

    Someone said about VNC... I'll take a look, but since it is an
    exercise I need to do it, I can't just say someone else arelady did
    that :)

    Everything seems quite useful. I forgot two specifications:

    1. Screen should be split in small squares and only the changing
    squares must be transmitted (Ok it shouldn't be too difficult)

    2. The comunication must be in multicast

    I will spend some time testing the resources.

    PAolo
     
    Paolo Pantaleo, Sep 22, 2006
    #6
  7. 2006/9/22, Paolo Pantaleo <>:
    > Thnx everybody for the precious help :)
    >
    > Someone said about VNC... I'll take a look, but since it is an
    > exercise I need to do it, I can't just say someone else arelady did
    > that :)
    >
    > Everything seems quite useful. I forgot two specifications:
    >
    > 1. Screen should be split in small squares and only the changing
    > squares must be transmitted (Ok it shouldn't be too difficult)
    >
    > 2. The comunication must be in multicast


    Twisted supports multicast ( example
    http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/425975)

    >
    > I will spend some time testing the resources.
    >
    > PAolo
    >



    --
    if you have a minute to spend please visit my photogrphy site:
    http://mypic.co.nr
     
    Paolo Pantaleo, Sep 22, 2006
    #7
  8. Paolo Pantaleo

    Ravi Teja Guest

    > Someone said about VNC... I'll take a look, but since it is an
    > exercise I need to do it,


    Exercises typically need you to implement, not invent (leave that for a
    thesis or a dissertation). Rather than invent VNC, you could just
    implement it on your own from the specs.

    http://realvnc.com/docs/rfbproto.pdf

    > I can't just say someone else arelady did that :)


    No. But you can build upon it :). Few construct software from the
    scratch.
     
    Ravi Teja, Sep 22, 2006
    #8
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Sam Hwang

    A Java-based video conference

    Sam Hwang, Mar 26, 2005, in forum: Java
    Replies:
    2
    Views:
    7,240
  2. =?Utf-8?B?Q2hyeXNhbg==?=

    Web / Video conference application in asp.net

    =?Utf-8?B?Q2hyeXNhbg==?=, Apr 19, 2006, in forum: ASP .Net
    Replies:
    2
    Views:
    5,012
    =?Utf-8?B?Q2hyeXNhbg==?=
    Apr 20, 2006
  3. John
    Replies:
    0
    Views:
    1,150
  4. John
    Replies:
    0
    Views:
    1,113
  5. Replies:
    0
    Views:
    372
Loading...

Share This Page