This commit is contained in:
Devdatt Bhatt 2026-05-23 20:16:07 +00:00
parent 91892058dd
commit 320d999bf7
2 changed files with 23 additions and 6 deletions

View File

@ -857,7 +857,7 @@ function update_service($which_service)
break; break;
case "srt"; case "srt";
update_service_backend('srt', $srt_pass1, $srt_pass2); update_service_backend('srt', $srt_pass1, $srt_pass2);
if ($service_srt_multiple) { if ($service_srt_multiple === "enable") {
$srt = 'ffmpeg -hwaccel auto -hide_banner -fflags +discardcorrupt -i '; $srt = 'ffmpeg -hwaccel auto -hide_banner -fflags +discardcorrupt -i ';
switch ($use_common_backend) { switch ($use_common_backend) {
case "copy_input": case "copy_input":
@ -1109,11 +1109,6 @@ function update_service($which_service)
} }
} }
function update_firewall() {}
function update_firmware() {}
function update_service_backend($service, $srt_pass1, $srt_pass2) function update_service_backend($service, $srt_pass1, $srt_pass2)
{ {

View File

@ -29,6 +29,8 @@ if (file_exists($jsonFile)) {
$data = json_decode($raw, true); $data = json_decode($raw, true);
} }
$service_display = $data['service_display'];
$service_rtmp0_multiple = $data['service_rtmp0_multiple']; $service_rtmp0_multiple = $data['service_rtmp0_multiple'];
$service_rtmp0_hls = $data['service_rtmp0_hls']; $service_rtmp0_hls = $data['service_rtmp0_hls'];
$service_rtmp0_dash = $data['service_rtmp0_dash']; $service_rtmp0_dash = $data['service_rtmp0_dash'];
@ -37,11 +39,21 @@ $service_rtmp1_hls = $data['service_rtmp1_hls'];
$service_rtmp1_dash = $data['service_rtmp1_dash']; $service_rtmp1_dash = $data['service_rtmp1_dash'];
$service_srt_multiple = $data['service_srt_multiple']; $service_srt_multiple = $data['service_srt_multiple'];
$service_udp0 = $data['service_udp0'];
$service_udp1 = $data['service_udp1'];
$service_udp2 = $data['service_udp2'];
$text = "<h3>Encoder</h3>"; $text = "<h3>Encoder</h3>";
$text .= "<h5>http://" . $domain; $text .= "<h5>http://" . $domain;
if ($https) $text .= "<br>https://" . $domain; if ($https) $text .= "<br>https://" . $domain;
$text .= "</h5>"; $text .= "</h5>";
if ($service_display == 'enable') {
$text .= "<br><h5>Display Output is Enable</h5>";
}
if ($service_rtmp0_multiple == 'enable') { if ($service_rtmp0_multiple == 'enable') {
$text .= "<h5>rtmp://" . $domain . "/shree/bhattji<br>"; $text .= "<h5>rtmp://" . $domain . "/shree/bhattji<br>";
if ($service_rtmp0_hls == 'enable') { if ($service_rtmp0_hls == 'enable') {
@ -79,6 +91,16 @@ if ($service_srt_multiple == 'enable') {
$text .= "<h5>srt://" . $domain . ":1937?streamid=shree/bhatt/ji</h5>"; $text .= "<h5>srt://" . $domain . ":1937?streamid=shree/bhatt/ji</h5>";
} }
if ($service_udp0 == 'enable') {
$text .= "<h5>".$data['udp0']['udp']."</h5>";
}
if ($service_udp1 == 'enable') {
$text .= "<h5>".$data['udp1']['udp']."</h5>";
}
if ($service_udp2 == 'enable') {
$text .= "<h5>".$data['udp2']['udp']."</h5>";
}
if ($_SERVER['REQUEST_METHOD'] === 'POST') { if ($_SERVER['REQUEST_METHOD'] === 'POST') {
if (isset($_POST['action'])) { if (isset($_POST['action'])) {