Possibility to blank custom stage view

Like many others I'm starting to use a custom stage view as an OBS feed for displaying bible/lyrics to video streams. The downside I've found however is that stage views do not blank in the way the main view does and therefore creates additional work in that someone needs to baby sit the OBS feed and duplicate the show/blank commands that the person controlling OpenLP is already doing.

Probably what would be really ideal is the ability to use custom views for the main view also, eg. like this http://xxx.xxx.x.xx:4316/main/Bible-CL instead of http://xxx.xxx.x.xx:4316/stage/Bible-CL

Thoughts?

Comments

  • Hi, blanking sceeen can be done via javascript. There is a thread with sample code somewhere around.

  • If you want to blank the display completely whenever the main view is emptied, you need to change the function “pollServer” inside of the file “stage.js”

    pollServer: function () {
      $.getJSON(
        "/api/poll",
        function (data, status) {
          OpenLP.updateClock(data);
          if (OpenLP.currentItem != data.results.item ||
            OpenLP.currentService != data.results.service) {
            OpenLP.currentItem = data.results.item;
            OpenLP.currentService = data.results.service;
            OpenLP.loadSlides();
          }
          else if (OpenLP.currentSlide != data.results.slide) {
            OpenLP.currentSlide = parseInt(data.results.slide, 10);
            OpenLP.updateSlide();
          }
          // NEW CODE STARTS HERE
          if(data.results.display || data.results.blank || data.results.theme) {
            $("body").hide();
          }
          else {
            $("body").show();
          }
          // NEW CODE ENDS HERE
        }
      );
    }
    

    In the OpenLP API there are three options for the three types of blanking the screen (display, blank, theme). If any of these are active, it hides the complete page. Otherwise it is displayed.

Sign In or Register to comment.