[PR #243] [MERGED] Replace RTP parser with libdatachannel depacketizers in WhipServerClient #244

Closed
opened 2026-03-02 04:00:53 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/eerimoq/moblin/pull/243
Author: @Copilot
Created: 2/15/2026
Status: Merged
Merged: 2/15/2026
Merged by: @eerimoq

Base: mainHead: copilot/replace-rtp-parser-with-libdatachannel


📝 Commits (5)

  • 3f982b4 Initial plan
  • b849ca5 Replace RTP parser with libdatachannel depacketizers in WhipServerClient
  • 23dc1b2 Add guard for data size in splitNalUnits to prevent potential underflow
  • af6fa20 Use rtcSetFrameCallback from libdatachannel v0.27.0 for frame data with timestamps
  • b5deacd Fix video decoder -12909 error: use existing NAL unit utilities matching SRT/RIST pattern

📊 Changes

2 files changed (+38 additions, -128 deletions)

View changed files

📝 Moblin.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved (+1 -1)
📝 Moblin/Media/WhipServer/WhipServerClient.swift (+37 -127)

📄 Description

  • Explore repository structure and understand the codebase
  • Use libdatachannel depacketizers instead of manual RTP parsing
  • Use rtcSetFrameCallback from libdatachannel v0.27.0
  • Fix video decoder -12909 error by using existing NAL unit utilities (getNalUnits, readH264NalUnits, removeNalUnitStartCodes) matching the SRT/RIST/RTMP server pattern
    • Previously only NAL types 1 and 5 were passed to the decoder; now all NAL units are included in the AVCC block buffer

Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/eerimoq/moblin/pull/243 **Author:** [@Copilot](https://github.com/apps/copilot-swe-agent) **Created:** 2/15/2026 **Status:** ✅ Merged **Merged:** 2/15/2026 **Merged by:** [@eerimoq](https://github.com/eerimoq) **Base:** `main` ← **Head:** `copilot/replace-rtp-parser-with-libdatachannel` --- ### 📝 Commits (5) - [`3f982b4`](https://github.com/eerimoq/moblin/commit/3f982b4ad0318559c496e6206154114d871a8906) Initial plan - [`b849ca5`](https://github.com/eerimoq/moblin/commit/b849ca5597bdab784260beb92fc3afe4ded6bfef) Replace RTP parser with libdatachannel depacketizers in WhipServerClient - [`23dc1b2`](https://github.com/eerimoq/moblin/commit/23dc1b2c24177ab37c84785b7d49670692118fe3) Add guard for data size in splitNalUnits to prevent potential underflow - [`af6fa20`](https://github.com/eerimoq/moblin/commit/af6fa2014dd3666783002e7f033b880c5accc54f) Use rtcSetFrameCallback from libdatachannel v0.27.0 for frame data with timestamps - [`b5deacd`](https://github.com/eerimoq/moblin/commit/b5deacd230f670e3899ea67f15b013b145f2ad79) Fix video decoder -12909 error: use existing NAL unit utilities matching SRT/RIST pattern ### 📊 Changes **2 files changed** (+38 additions, -128 deletions) <details> <summary>View changed files</summary> 📝 `Moblin.xcodeproj/project.xcworkspace/xcshareddata/swiftpm/Package.resolved` (+1 -1) 📝 `Moblin/Media/WhipServer/WhipServerClient.swift` (+37 -127) </details> ### 📄 Description - [x] Explore repository structure and understand the codebase - [x] Use libdatachannel depacketizers instead of manual RTP parsing - [x] Use `rtcSetFrameCallback` from libdatachannel v0.27.0 - [x] Fix video decoder -12909 error by using existing NAL unit utilities (getNalUnits, readH264NalUnits, removeNalUnitStartCodes) matching the SRT/RIST/RTMP server pattern - Previously only NAL types 1 and 5 were passed to the decoder; now all NAL units are included in the AVCC block buffer <!-- START COPILOT CODING AGENT TIPS --> --- ✨ Let Copilot coding agent [set things up for you](https://github.com/eerimoq/moblin/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot) — coding agent works faster and does higher quality work when set up for your repo. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 04:00:53 +03:00
Sign in to join this conversation.
No labels
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/moblin#244
No description provided.