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

multi-frame transport #7

Closed
bmegli opened this issue Mar 15, 2020 · 2 comments · Fixed by #10
Closed

multi-frame transport #7

bmegli opened this issue Mar 15, 2020 · 2 comments · Fixed by #10
Labels
enhancement New feature or request

Comments

@bmegli
Copy link
Owner

bmegli commented Mar 15, 2020

Related to hardware-video-streaming#5

The idea is to make MLSP aware of transporting multiple logical subframes in a single frame.

The gains are:

  • avoids unnecessary copies when preparing packets
  • avoids unnecessary complexity on library user side

The disadvantages are:

  • adds complexity in MLSP implementation
  • adds complexity in MLSP interface
  • needs protocol change (information about frame structure)
@bmegli bmegli added the enhancement New feature or request label Mar 15, 2020
@bmegli
Copy link
Owner Author

bmegli commented Mar 15, 2020

needs protocol change (information about frame structure)

The frame structure may be encoded only with first (or last) packet and needs:

  • subframes number (or sizes followed by 0)
  • subframes sizes
  • optionally later subframe semantics (what it caries)

@bmegli
Copy link
Owner Author

bmegli commented Apr 4, 2020

The frame structure may be encoded in the current payload:

  • the current packet level header will be unchanged
  • the paylod will begin with frame structure description
  • the things that change are:
    • preparing packets (encode structure at the beginning of payload)
    • returning frames to user (decode structure after collecting frame)

Now, there is no need to copy any data to subframes when decoding.
It is enough to move the pointers to relevant sections.

bmegli added a commit that referenced this issue Apr 5, 2020
- library interface
   - mlsp_frame carries array of subframe sizes and data pointers
- library implementation
   - for send the data is packetized on the fly (constructed from subframes without preparing continous payload data)
   - for receive the data is reconstructed by setting pointers to data sections in the receive buffer

This means that all avoid unecessary copies:
- library interface
- sending
- receiving

Related to #7
bmegli added a commit that referenced this issue Apr 19, 2020
- consistently return relative offset by functions
- add some comments in the code
- multi-frame compatible readme
- data buffer padding (e.g. FFmpeg compatibility without copying data)

Related to #7
bmegli added a commit that referenced this issue Apr 19, 2020
- library interface
   - mlsp_frame carries array of subframe sizes and data pointers
- library implementation
   - data buffer padding (e.g. FFmpeg compatibility without copying data)
   - for send the data is packetized on the fly (constructed from subframes without preparing continous payload data)
   - for receive the data is reconstructed by setting pointers to data sections in the receive buffer
- documentation
   - updated readme and header

All avoid unnecessary copies:
- library interface (pointers to subframes)
- sending (packetizing on the fly)
- receiving (partitioning by pointers to data buffer)
- data consumption (already padded buffer)

Closes #7
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant