Skip to content

Commit

Permalink
fix udp ports
Browse files Browse the repository at this point in the history
  • Loading branch information
pedro committed Feb 22, 2021
1 parent bdbd15f commit f1e6704
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ allprojects {
}
}
dependencies {
implementation 'com.github.pedroSG94.RTSP-Server:rtspserver:1.0.2'
implementation 'com.github.pedroSG94.RTSP-Server:rtspserver:1.0.3'
implementation 'com.github.pedroSG94.rtmp-rtsp-stream-client-java:rtplibrary:1.9.8'
}
Expand Down
4 changes: 2 additions & 2 deletions app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ android {
applicationId "com.pedro.sample"
minSdkVersion 16
targetSdkVersion 30
versionCode 102
versionName "1.0.2"
versionCode 103
versionName "1.0.3"
}
buildTypes {
release {
Expand Down
4 changes: 2 additions & 2 deletions rtspserver/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ android {
defaultConfig {
minSdkVersion 16
targetSdkVersion 30
versionCode 102
versionName "1.0.2"
versionCode 103
versionName "1.0.3"
}

buildTypes {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -72,21 +72,21 @@ class ServerCommandManager(private val serverIp: String, private val serverPort:
}
getTrack(request)
if (track != null) {
if (track == 0) { //audio ports
if (track == RtpConstants.trackAudio) { //audio ports
audioPorts.clear()
audioPorts.add(ports[0])
audioPorts.add(ports[1])
Log.i(TAG, "Audio ports: $audioPorts")
} else { //video ports
videoPorts.clear()
videoPorts.add(ports[0])
videoPorts.add(ports[1])
Log.i(TAG, "Video ports: $videoPorts")
}
} else {
Log.e(TAG, "Track id not found")
return false
}
Log.i(TAG, "Video ports: $videoPorts")
Log.i(TAG, "Audio ports: $audioPorts")
return true
}

Expand Down

0 comments on commit f1e6704

Please sign in to comment.