-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/public/app/scoreboard/scoreboardController.js b/public/app/scoreboard/scoreboardController.js
index c324e83..ece1748 100644
--- a/public/app/scoreboard/scoreboardController.js
+++ b/public/app/scoreboard/scoreboardController.js
@@ -101,10 +101,10 @@
radarSpeedDataHistory: [],
showRadarConfig : true,
editRadarConfig: false,
+ serverLogsSubscribe: {timer:null,sockets:[]},
radarSpeedData: {
id: 0,
time: new Date(),
-
inMinSpeed: 0,
inMaxSpeed: 0,
outMinSpeed: 0,
@@ -227,6 +227,27 @@
$scope.commonData.isGameSelect = true;
}
+
+ var resubscribeServerLogs = function () {
+ console.log("resubscribeServerLogs");
+ if (streamerDetailsSubscribe.timerID && streamerDetailsSubscribe.audioStreamerId) {
+ Service.socket.emit("AudioStreamerAction", { "actionId": getFakeGuid(), "audioStreamerId": streamerDetailsSubscribe.audioStreamerId, "action": "SubscribeStreamerDetails" });
+ streamerDetailsSubscribe.timerID = window.setTimeout(resubscribeStreamerDetails, 10 * 60 * 1000);
+ }
+ }
+
+ var subscribeServerLogs = function (audioStreamerId) {
+ console.log("subscribeServerLogs");
+ if (streamerDetailsSubscribe.timerID) {
+ unsubscribeStreamerDetails();
+ }
+ streamerDetailsSubscribe.audioStreamerId = audioStreamerId;
+ Service.socket.emit("AudioStreamerAction", { "actionId": getFakeGuid(), "audioStreamerId": streamerDetailsSubscribe.audioStreamerId, "action": "SubscribeStreamerDetails", data: { logLevel: "info" } });
+ streamerDetailsSubscribe.timerID = window.setTimeout(resubscribeStreamerDetails, 10 * 60 * 1000 );
+
+ }
+
+
$scope.gameScore = function () {
if ($scope.commonData.selectedGame.id === '00000000-0000-0000-0000-000000000000') {
$scope.commonData.selectedGame.id = null;
@@ -285,26 +306,46 @@
}
- $scope.streamStart = function () {
- //Tell server the inningChanged
- radarMonitor.sendServerCommand("stream", { cmd: "start"});
- }
+ $scope.videoStreamStart = function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "start"});
+ }
- $scope.streamStop= function () {
- //Tell server the inningChanged
- radarMonitor.sendServerCommand("stream", { cmd: "stop" });
- }
+ $scope.videoStreamStop= function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "stop" });
+ }
+ $scope.videoStreamYoutubeStart = function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "youtubeStart"});
+ }
- $scope.streamStartRemote = function () {
- //Tell server the inningChanged
- radarMonitor.sendServerCommand("stream", { cmd: "startRemote" });
- }
+ $scope.videoStreamYoutubeStop= function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "youtubeStop" });
+ }
- $scope.streamStopRemote = function () {
- //Tell server the inningChanged
- radarMonitor.sendServerCommand("stream", { cmd: "stopRemote" });
- }
+ $scope.videoStreamGameChangerStart = function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "gamechangerStart"});
+ }
+
+ $scope.videoStreamGameChangerStop= function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "gamechangerStop" });
+ }
+
+ $scope.videoStreamFileStart = function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "fileStart"});
+ }
+
+ $scope.videoStreamFileStop= function () {
+ //Tell server the inningChanged
+ radarMonitor.sendServerCommand("videoStream", { cmd: "fileStop" });
+ }
+
$scope.batterChange = function () {
@@ -1115,6 +1156,16 @@
// $scope.$apply();
//});
+
+ $rootScope.$on('stream:youtubeStarted', function(event, data) {
+ // use the data accordingly
+ //console.log('radarMonitor:radarSpeedDataHistory detected ');
+ console.debug(data);
+ $scope.commonData.stream = data;
+ $scope.$apply();
+ });
+
+
$rootScope.$on('radarMonitor:radarSpeedDataHistory', function(event, data) {
// use the data accordingly
//console.log('radarMonitor:radarSpeedDataHistory detected ');
diff --git a/public/tests/youtube.html b/public/tests/youtube.html
new file mode 100644
index 0000000..b289d95
--- /dev/null
+++ b/public/tests/youtube.html
@@ -0,0 +1,50 @@
+
+
+
+
\ No newline at end of file
diff --git a/tests/testVideoCapture.js b/tests/testVideoCapture.js
index f92fb18..af85daf 100644
--- a/tests/testVideoCapture.js
+++ b/tests/testVideoCapture.js
@@ -16,7 +16,7 @@ var objOptions = {
"app":"debug"
},
"ffmpegVideoInput" :{
- "app":"debug"
+ "app":"trace"
},
"ffmpegVideoOutputRtmp" :{
"app":"debug"
@@ -31,50 +31,50 @@ var objOptions = {
input:"rtsp://10.100.34.112:554/s0",
//input:"video=Integrated Camera:audio=Microphone (Realtek High Definition Audio)",
//inputOptions: ["-f dshow", "-video_size 1280x720", "-rtbufsize 702000k", "-framerate 30"], // ["-rtsp_transport tcp","-stimeout 30000000"]
- inputOptions: ["-rtsp_transport tcp", "-stimeout 30000000"],
+ inputOptions: ["-rtsp_transport tcp"],
//outputOptions: [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-g 12", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset hq", "-f flv" ],
outputOptions: [ "-c:a copy", "-c:v copy", "-f nut" ],
capture:true,
outputs: {
ffmpegVideoOutputRtmp : {
- "rtmpUrl": "rtmp://a.rtmp.youtube.com/live2/x0fy-98kz-0967-s3gy-0jq2",
+ "rtmpUrl": "rtmp://a.rtmp.youtube.com/live2/a5fv-d7rc-7jsa-v7g4-2c70",
//"rtmpUrl2": "rtmps://601c62c19c9e.global-contribute.live-video.net:443/app/sk_us-east-1_gIgq11gfyeCV_yCYDarNv5iHdMgZJbDHnAhfjWPKvjt",
//"rtmpUrlRtp": "rtp://127.0.0.1:3000",
"inputOptions": [],
- //"outputOptions": [ "-c:a copy", "-pix_fmt +", "-c:v libx264", "-preset ultrafast", "-tune zerolatency", "-f flv" ],
- "outputOptions": [ "-c:a copy", "-c:v copy", "-f flv" ],
+ "outputOptions": [ "-c:a copy", "-c:v libx264", "-preset ultrafast", "-qp 0", "-f flv" ],
+ //"outputOptions": [ "-c:a copy", "-c:v copy", "-f flv" ],
//"outputOptions2": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-use_wallclock_as_timestamps 1", "-g 48", "-preset hq", "-f flv" ],
//"outputOptionsRtp": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-b:v 4.5M", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset llhq", "-rc vbr_hq", "-sdp_file video.sdp", "-f rtp" ],
- "overlayFileName": null,
- "videoFilters": null,
- // "videoFilters": {
- // "filter": "drawtext",
- // "options": "fontfile=arial.ttf:fontsize=50:box=1:boxcolor=black@0.75:boxborderw=5:fontcolor=white:x=(w-text_w)/2:y=((h-text_h)/2)+((h-text_h)/2):textfile=overlay.txt:reload=1"
- // }
+ "overlayFileName": youTubeOverlay.txt,
+ "videoFilters": {
+ "filter": "drawtext",
+ "options": "fontfile=arial.ttf:fontsize=50:box=1:boxcolor=black@0.75:boxborderw=5:fontcolor=white:x=(w-text_w)/2:y=((h-text_h)/2)+((h-text_h)/2):textfile=overlay.txt:reload=1"
+ }
}
- //,
- // ffmpegVideoOutputRtmp2 : {
- // "rtmpUrl": "rtmps://601c62c19c9e.global-contribute.live-video.net:443/app/sk_us-east-1_a8gQblEYUN3V_iHEQ0mXeSm1VROYp7YHqGapllvvXd5",
- // //"rtmpUrl2": "rtmps://601c62c19c9e.global-contribute.live-video.net:443/app/sk_us-east-1_gIgq11gfyeCV_yCYDarNv5iHdMgZJbDHnAhfjWPKvjt",
- // //"rtmpUrlRtp": "rtp://127.0.0.1:3000",
- // "inputOptions": [],
- // "outputOptions": [ "-c:a copy", "-pix_fmt +", "-c:v libx264", "-use_wallclock_as_timestamps 1", "-g 12", "-preset hq", "-f flv" ],
- // //"outputOptions2": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-use_wallclock_as_timestamps 1", "-g 48", "-preset hq", "-f flv" ],
- // //"outputOptionsRtp": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-b:v 4.5M", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset llhq", "-rc vbr_hq", "-sdp_file video.sdp", "-f rtp" ],
- // "overlayFileName": "overlay.txt",
- // "videoFilters": {
- // "filter": "drawtext",
- // "options": "fontfile=arial.ttf:fontsize=50:box=1:boxcolor=black@0.75:boxborderw=5:fontcolor=white:x=(w-text_w)/2:y=((h-text_h)/2)+((h-text_h)/2):textfile=overlay.txt:reload=1"
- // }
- // },
- // ffmpegVideoOutputMp4File : {
- // "inputOptions": [],
- // "outputOptions": [ "-c:a copy", "-c:v copy", "-f flv", "-y" ],
- // "outputFile": "e:\\videos\\testVideoCapture.flv",
- // //"outputOptionsRtp": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-b:v 4.5M", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset llhq", "-rc vbr_hq", "-sdp_file video.sdp", "-f rtp" ],
- // "overlayFileName": null,
- // "videoFilters": null
- // }
+ ,
+ ffmpegVideoOutputRtmp2 : {
+ "rtmpUrl": "rtmps://601c62c19c9e.global-contribute.live-video.net:443/app/sk_us-east-1_iAKfeoPwrELU_yxEtfN8t1iC9IjsHHnLbC8vBUW8eoT",
+ //"rtmpUrl2": "rtmps://601c62c19c9e.global-contribute.live-video.net:443/app/sk_us-east-1_gIgq11gfyeCV_yCYDarNv5iHdMgZJbDHnAhfjWPKvjt",
+ //"rtmpUrlRtp": "rtp://127.0.0.1:3000",
+ "inputOptions": [],
+ "outputOptions": [ "-c:a copy", "-c:v libx264", "-vf scale=1920:1080", "-preset ultrafast", "-qp 0", "-f flv" ],
+ //"outputOptions2": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-use_wallclock_as_timestamps 1", "-g 48", "-preset hq", "-f flv" ],
+ //"outputOptionsRtp": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-b:v 4.5M", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset llhq", "-rc vbr_hq", "-sdp_file video.sdp", "-f rtp" ],
+ "overlayFileName": "GameChangerOverlay.txt",
+ "overlayFilter": {showRadarIn:true},
+ "videoFilters": {
+ "filter": "drawtext",
+ "options": "fontfile=arial.ttf:fontsize=50:box=1:boxcolor=black@0.75:boxborderw=5:fontcolor=white:x=(w-text_w)/2:y=((h-text_h)/2)+((h-text_h)/2):textfile=overlay.txt:reload=1"
+ }
+ },
+ ffmpegVideoOutputFile : {
+ "inputOptions": [],
+ "outputOptions": [ "-c:a copy", "-c:v copy", "-f flv", "-y" ],
+ "outputFile": "e:\\videos\\testVideoCapture.flv",
+ //"outputOptionsRtp": [ "-c:a copy", "-pix_fmt +", "-c:v h264_nvenc", "-b:v 4.5M", "-use_wallclock_as_timestamps 1", "-fflags +genpts", "-preset llhq", "-rc vbr_hq", "-sdp_file video.sdp", "-f rtp" ],
+ "overlayFileName": null,
+ "videoFilters": null
+ }
}
}