Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve RTPBuffer #24

Open
doe300 opened this issue Jun 10, 2015 · 8 comments
Open

Improve RTPBuffer #24

doe300 opened this issue Jun 10, 2015 · 8 comments

Comments

@doe300
Copy link
Owner

doe300 commented Jun 10, 2015

add minimum number of buffered package before playing audio

@doe300 doe300 self-assigned this Jun 10, 2015
@doe300 doe300 added this to the Meeting 5 milestone Jun 10, 2015
doe300 added a commit that referenced this issue Jun 17, 2015
@doe300 doe300 closed this as completed Jun 17, 2015
@Kaayy-J
Copy link
Collaborator

Kaayy-J commented Aug 22, 2015

Improve the buffer:

  • Write a super class for the buffer to make it replaceable
  • Develop an alternative / improved buffer
  • Measure the performance
  • Test the behaviour of the buffers on crictical situations
  • every second or third package gets lost on transmitting
  • a big block of packages gets lost on on transmitting
  • all packages gets lost (and then it receives again)
  • less packages gets read (buffer overflow behavior)
  • Stability test (test the buffers for a longer period) (Test for memory leak)

@Kaayy-J Kaayy-J reopened this Aug 22, 2015
@Kaayy-J Kaayy-J assigned Kaayy-J and unassigned doe300 Aug 22, 2015
@Kaayy-J
Copy link
Collaborator

Kaayy-J commented Aug 23, 2015

Problems to solve:

  • Problem / Example 1: Buffer receives packages with sequence numbers 50, 51, 52, 53.
    Afterwards these packages are read. Now the buffer receives the packages with the sequence numbers 54, 48, 49, 55. Since the buffer is on the read position 54 now, the packages 48 and 49 should not be saved anymore.
  • Problem / Example 2: How to safe a read position? Read position is the highest sequence number. Sequence number is a 16 bit unsigned int, which is being incremented (by the sender). When the maximum number is reached the sequence number will start at zero again. How to detect this?
  • Problem / Example 3: A way to stop reading from the buffer in order to fill it with minimum count of packages (doe300 already has implemented this feature: "minimum number of buffered package before playing audio"). This action is required at the begin of the communication. It can also be required in the middle of the communication when a lot of packages gets lost. Then the playback/reading from the buffer should pause. After the buffer has reached a certain fill stage it can continue.

@doe300
Copy link
Owner Author

doe300 commented Aug 23, 2015

We need to write test-cases for the three examples from the post above.
Also @Kaayy-J, the new RTPBufferPackage leaks memory (doesn't destroy header-buffer)

@doe300 doe300 removed this from the Meeting 5 milestone Aug 23, 2015
@Kaayy-J
Copy link
Collaborator

Kaayy-J commented Aug 24, 2015

The std::rand generator works terrible. It even should not have the name random number generator.

Anyway, I have tested both buffers (RTPBuffer and RTPBufferAlternative) with an another random generator with 50% percent package lost. The RTPBufferAlternative buffer works quite good compared to RTPBuffer.

@Kaayy-J
Copy link
Collaborator

Kaayy-J commented Sep 16, 2015

AlternativeBuffer does not work on real enviroment (test with J0n8s).

@Kaayy-J Kaayy-J added the bug label Sep 16, 2015
@doe300
Copy link
Owner Author

doe300 commented Sep 17, 2015

@Kaayy-J , How did the original RTPBuffer-implementation do in your test?

@doe300 doe300 added this to the Meeting 7 / Version 0.6 milestone Sep 17, 2015
@Kaayy-J
Copy link
Collaborator

Kaayy-J commented Sep 17, 2015

It did quite well. We had a very good sound quality.

@doe300 doe300 removed this from the Meeting 7 / Version 0.6 milestone Nov 6, 2015
@doe300
Copy link
Owner Author

doe300 commented Jan 27, 2016

rewrite one of the two buffer-implementations to solve all the problems in this ticket, including:

  • add minimum number of buffered package before playing audio (set playout point)
  • make minimum playout point configurable
  • make playout point dynamically adaptable
  • Test the behavior of the buffers on marginal situations (playout point adaption, correctness of order)
    • every second or third package gets lost
    • a big block of packages gets lost. How does buffer react, if overflow gets lost?
    • less packages read then received (buffer overflow behavior)
    • DTX (see Implement DTX #65) is enabled and packages get lost. What if the marker-package gets lost?

@doe300 doe300 added this to the Version 1.0 milestone Jan 27, 2016
@doe300 doe300 assigned doe300 and unassigned Kaayy-J Feb 14, 2016
@doe300 doe300 mentioned this issue Feb 20, 2016
Merged
@doe300 doe300 added needs testing and removed bug labels Feb 22, 2016
@doe300 doe300 removed their assignment Jan 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants