Skip to content

Refactor H264Payloader to allow the deactivation of STAP-A packets. #292

Merged
Sean-Der merged 1 commit intopion:masterfrom
YannSc:evol_h264_packet_stapa_disable
Feb 15, 2025
Merged

Refactor H264Payloader to allow the deactivation of STAP-A packets. #292
Sean-Der merged 1 commit intopion:masterfrom
YannSc:evol_h264_packet_stapa_disable

Conversation

@YannSc
Copy link
Copy Markdown
Contributor

@YannSc YannSc commented Feb 13, 2025

Description

This change adds a field* to disable the creation of STAP-A packets by the H264Payloader.

  • As per current behaviour, STAP-A packets are created by default.
  • If the creation of STAP-A packets is disabled, NALUs of type 7 (SPS) and type 8 (PPS) will be packed as Single NAL Units.

This change can be a step to support packetization-mode=0 (single NALUs) in compliance with RFC6184.

Reference issue

This change is related to bluenviron/gortsplib#585

Context and use case

The use case motivating this change is to simulate a proprietary piece of hardware. This hardware shows limited RTP packetization capabilities as it does not generate STAP-A packets (only single NALUs and FUas).

Thanks,

@Sean-Der
Copy link
Copy Markdown
Member

LGTM @YannSc! Mind exposing the field (instead of using a method) and we can get this merged :)

@codecov
Copy link
Copy Markdown

codecov bot commented Feb 13, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.72%. Comparing base (3e1f46a) to head (50b323b).
Report is 2 commits behind head on master.

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #292      +/-   ##
==========================================
+ Coverage   84.69%   84.72%   +0.02%     
==========================================
  Files          24       24              
  Lines        2699     2703       +4     
==========================================
+ Hits         2286     2290       +4     
  Misses        354      354              
  Partials       59       59              
Flag Coverage Δ
go 84.72% <100.00%> (+0.02%) ⬆️
wasm 84.09% <100.00%> (+0.02%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@YannSc YannSc requested a review from Sean-Der February 13, 2025 22:45
@YannSc
Copy link
Copy Markdown
Contributor Author

YannSc commented Feb 13, 2025

Changed as requested. Thank you for the review !

…ALUs of type 7 (SPS) and type 8 (PPS) will be packed as Single NAL Units if STAP-A are disabled.

This change can  help to support packetization-mode=0 (single NALUs) in compliance with RFC6184.
@Sean-Der Sean-Der force-pushed the evol_h264_packet_stapa_disable branch from e2c3e61 to 50b323b Compare February 15, 2025 03:30
@Sean-Der Sean-Der merged commit 2cd23bd into pion:master Feb 15, 2025
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants