Skip to content

Update Rtmp Library - #6

Open
daroltidan wants to merge 1393 commits into
theshiftstudio:masterfrom
pedroSG94:master
Open

daroltidan wants to merge 1393 commits into
theshiftstudio:masterfrom
pedroSG94:master

Conversation

@daroltidan

Copy link
Copy Markdown

No description provided.

@daroltidan daroltidan closed this Mar 8, 2023
@daroltidan daroltidan reopened this Mar 8, 2023
@daroltidan daroltidan closed this Mar 8, 2023
@daroltidan daroltidan reopened this Mar 8, 2023
@pedroSG94
pedroSG94 force-pushed the master branch 2 times, most recently from d54eeb0 to 1af26b2 Compare November 7, 2025 08:32
pedroSG94 and others added 24 commits June 10, 2026 05:47
avoid camera freezing because fps range
…dia3-media3-inspector-1.10.1

Bump androidx.media3:media3-inspector from 1.10.0 to 1.10.1
Bumps `ktor` from 3.5.0 to 3.5.1.

Updates `io.ktor:ktor-network` from 3.5.0 to 3.5.1
- [Release notes](https://github.com/ktorio/ktor/releases)
- [Changelog](https://github.com/ktorio/ktor/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ktorio/ktor/commits)

Updates `io.ktor:ktor-network-tls` from 3.5.0 to 3.5.1
- [Release notes](https://github.com/ktorio/ktor/releases)
- [Changelog](https://github.com/ktorio/ktor/blob/main/CHANGELOG.md)
- [Commits](https://github.com/ktorio/ktor/commits)

---
updated-dependencies:
- dependency-name: io.ktor:ktor-network
  dependency-version: 3.5.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: io.ktor:ktor-network-tls
  dependency-version: 3.5.1
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
* add whip module

* creating whip client

* testing post request

* fix post request

* add whip stun

* adding srtp support

* add srtcp support and fix calculate iv

* fix compilation

* update socket and add gathering

* add write offer

* read stun command correctly

* finish read and write stuns

* fix fingerprint crc32

* parse sdp answer

* add stun connection flush

* fixing integrity attribute

* finish gathering stun candidates

* request finally working

* stun connection finished

* adding dtls handshake

* update java socket

* doing dtls connection

* dtls handshake worked

* fix conexion

* connection working

* remove unnecessary files

* fix connection

* create send whip

* extract crypto provisional

* send packets working

* remove unused files

* stream audio working

* fix whip only video

* refactoring

* update readme

* fix send video info on rtp keyframes

* refactor rtp sockets

* fix app example
 dependencies
pedroSG94 and others added 30 commits August 12, 2026 12:00
…origin

Fix/surface pts shares audio origin
VideoEncoder stores width/height exactly as prepareVideoEncoder received them and
keeps rotation separately; at 90 or 270 it configures the codec as height x width.
A portrait broadcast prepared with (1920, 1080, rotation = 90) therefore produces
1080x1920 frames, while getVideoResolution() reported 1920x1080.

That pair goes straight into onMetaData:

  GenericStream.kt:111  val resolution = super.getVideoResolution()
  RtmpStream.kt:73      val resolution = super.getVideoResolution()
  MultiStream.kt:188    val resolution = super.getVideoResolution()

so every portrait broadcast through the newer API told the server it was landscape.
Players trust onMetaData: YouTube opens a 16:9 window and pillarboxes the vertical
picture, which is what our users reported. MultiCamera1/2 already swapped at their
call sites (MultiCamera2.kt:197-201), so only the newer classes were affected.

Fixed in getVideoResolution() rather than at the three call sites, so anything else
reading it gets the shape that is actually on the wire.

Verified on a Samsung SM-A065F: prepared 1920x1080 with rotation 90, the encoder
emits 1080x1920 (confirmed from the SPS of the captured stream), and the metadata
now matches instead of claiming landscape.
Announce the rotated resolution so portrait streams are not pillarboxed
…dia3-media3-inspector-1.11.0

Bump androidx.media3:media3-inspector from 1.10.1 to 1.11.0
Bumps `agp` from 9.3.1 to 9.3.2.

Updates `com.android.application` from 9.3.1 to 9.3.2

Updates `com.android.library` from 9.3.1 to 9.3.2

---
updated-dependencies:
- dependency-name: com.android.application
  dependency-version: 9.3.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
- dependency-name: com.android.library
  dependency-version: 9.3.2
  dependency-type: direct:production
  update-type: version-update:semver-patch
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [gradle-wrapper](https://github.com/gradle/gradle) from 9.6.1 to 9.7.1.
- [Release notes](https://github.com/gradle/gradle/releases)
- [Commits](gradle/gradle@v9.6.1...v9.7.1)

---
updated-dependencies:
- dependency-name: gradle-wrapper
  dependency-version: 9.7.1
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
…per-9.7.1

Bump gradle-wrapper from 9.6.1 to 9.7.1
With TCP backpressure (server ACKs not arriving, send window full) the sender
blocks in a java.io socket write, which ignores coroutine cancellation.
disconnect() stopped the sender first (BaseSender.stop -> job.cancelAndJoin)
and closed the socket only afterwards, so the join waited until the network
recovered or TCP gave up. A reConnect hung for the whole time.

Try a cooperative stop first (keeps the graceful close in the normal case) and,
if the sender does not stop within 1 s, close the socket to unblock the write
and stop again. RTSP over TCP (interleaved) writes to the same socket and has
the same issue. SRT/UDP are not affected (UDP sends do not block on ACKs).
SrtSender does not wait for ACKs and handleServerPackets swallows receive
timeouts, so a silent path (NAT rebind, black hole, frozen server) is never
reported: the stream keeps sending into the void. setServerSilenceTimeout(ms)
reports onConnectionFailed("No response from server") when no packet from
the server arrived for the given time. Disabled by default (0).
…g or paused

Co-authored-by: Cursor <cursoragent@cursor.com>
…oders-while-record-starting

keep encoders running in stopStream while a recording is starting or paused
…nce-timeout

srt: optional server silence timeout to detect a dead path
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.

8 participants