×

Loading...
Ad by
  • 推荐 OXIO 加拿大高速网络,最低月费仅$40. 使用推荐码 RCR37MB 可获得一个月的免费服务
Ad by
  • 推荐 OXIO 加拿大高速网络,最低月费仅$40. 使用推荐码 RCR37MB 可获得一个月的免费服务

transfering voice and text data(mixed) via one UDP link

Hi there:
I am writing a program to implement both voice and text chat(voice and text data are mixed) among several computers via one UDP link. Both the voice and text data are variable length. The problem is that package(voice or text data) maybe be segemented through network before reaching the destination, and the arriving sequences of segemented package from different sources are unpredictable. How should I design the message structure or communication model?

Just like yahoo messenger, people can talk using Microphone and speaker of computers and at the same time, they can chat by inputing something using keyboard. If I send a voice package about 2Kbytes, there is 2 fields in the header of the package(the TYPE is voice, the SIZE of this package is 2K). But in the destination, this package maybe be segemented into several packages.Except for the package with header, I don't know the other packages whether they are voice or text packages.

Thanks a lot.
Report

Replies, comments and Discussions:

  • 工作学习 / IT技术讨论 / transfering voice and text data(mixed) via one UDP link
    Hi there:
    I am writing a program to implement both voice and text chat(voice and text data are mixed) among several computers via one UDP link. Both the voice and text data are variable length. The problem is that package(voice or text data) maybe be segemented through network before reaching the destination, and the arriving sequences of segemented package from different sources are unpredictable. How should I design the message structure or communication model?

    Just like yahoo messenger, people can talk using Microphone and speaker of computers and at the same time, they can chat by inputing something using keyboard. If I send a voice package about 2Kbytes, there is 2 fields in the header of the package(the TYPE is voice, the SIZE of this package is 2K). But in the destination, this package maybe be segemented into several packages.Except for the package with header, I don't know the other packages whether they are voice or text packages.

    Thanks a lot.
    • Hi, guy. If you have interests to discuss with me, pls send me email: freenet945@yahoo.com