After having considered it a few times I decided to get myself one of these “blog” thingies. I have no idea yet if and how often I’ll write something here, and it will probably mostly be for my own (future) reference, but it’s worth a try.
Background
As part of graduating there is a tradition of performing a revue for the younger classes at the high school from which I graduated last week. Also almost a tradition is that the graduates start thinking about it less than a week before and thus get very little time to plan it. This year we were earlier though, which meant that we had at least a bit more time to prepare (at least for me who was responsible for the technical part). Of course starting to plan so early resulted in a “we’ve got time, we don’t need to do this yet”-mentality so that we weren’t anywhere close to ready the evening before.
What’s needed?
As probably the most tech-savvy I took it upon myself to take care of the technical parts, like sound and light. Part of that was playing some music and showing some videos at specific parts of the revue. For that I wanted something that…
- …could play both audio and video files
- …was stable (I don’t want to restart it during the performance, obviously)
- …plays videos in fullscreen
- …had a completely black screen when no video was played (can’t turn of the projector since that would be visible to the spectators)
- …run on linux
Basically it should be as smooth as possible for the audience.
What options are there?
Surprisingly, not a lot. A quick google search didn’t give me anything useful.
My next thought was writing something myself, but while I did have about a week it would have been risky (not very well tested, thus not stable enough) and there was other stuff I needed to do during this time. I did start working on something but quickly discarded that.
Cue: Enter VLC
For the rehersals I went for VLC. There, smoothness for the viewers wasn’t a high priority, I just needed something that worked. While others where arguing about how much bare skin would be acceptable for the male fashionshow I started playing with the VLC settings, which there are plenty of. Already in the default configuration it conforms to all except the fourth prerequisite.
Customizations
For the last piece of the puzzle some playing with the VLC advanced settings was required. Ensure that Fullscreen video output
and Embedded video
are checked and that Show a controller in fullscreen mode
, Play and pause
and On Screen Display
are unchecked. Also set the Lua HTTP password and ensure that the Web interface is enabled (in Main interfaces
).
Adapting media files
When playing plain audio files VLC will show a cone and exit fullscreen mode (thus the controller will be shown). To get around this I converted all audio files into .mp4s with a static black background using avconv:
avconv -i AudioFile.mp3 -i black.png -acodec copy -vcodec copy AudioFile.avi
black.png
is simply a plain black image (any size and resolution should work, I went with the resolution of the projector). Add AudioFile.avi
(not .mp3!) to the playlist.
Playlist control
Next, we need to ensure that the next playlist item is not played at the end of a track. The Play and pause
option seems like the obvious answer here. Another alternative is adding vlc://pause:9999
item whenever you want to stop. Play and pause
was not possible to use because we had some tracks that SHOULD follow each other without interruption, this could have been worked around by merging them into a single track, but there was another issue:
If a video is paused at it’s end the last frame will stay visible, instead of a black screen like we want. This happens both when using vlc://pause:9999
and Play and pause
. A way around this would be to insert a single black frame at the end of each video, but I went for a more straight forward solution: I created a 10 minute silent static black video, again with avconv:
avconv -loop 1 -i black.png -t 600 Black.avi
Just add Black.avi
everywhere in the playlist where you want to an interruption in the playback. The 10 minutes give you plenty of time to manually pause the playback in case there should be more than 10 minutes between playing two tracks.
Now I just needed to put all the files in the playlist (including Black.avi
(tip: also put one as the first item)) in the right order (also remember to save the playlist in case anything goes wrong). Of course the order of the show was changed several times before the play, so in the end I had to jump up and down in the playlist…
Lights, camera, action!
Before the show, set up all the hardware, turn on the projector and move the main VLC window to it. Also uncheck View > Docker playlist
and make the now separate playlist window visible. Put the playlist window on one half of the laptop screen and visit http://localhost:8080
with your browser, and put it on the other half of the laptop screen. This gives you full control without having to ever move the mouse in the area visible to the audience.
Double click the first (or any really) Black.avi
and pause the playback (use the web interface + the playlist). Give the main VLC window focus by clicking anywhere on it, press F11
(for making the window go fullscreen) and then f
to go into fullscreen mode (hides the controller, a video needs to be active for this to work). Done!
Conclusion and final thoughts
This is far from an optimal solution, and many parts of it feel hacky. I prefered straight forward (thus hopefully stable) ways over more elegant solutions, given more time I would have wanted to explore some of the more elegant solutions more. Some things that could be improved:
- The playlist view, getting rid of all the
Black.avi
items- Add black frames at the end of all videos
- Merge some files
- Enable
Play and pause
- Better view of what’s happening
- Something that shows the audio waveform (gives more information than just the elapsed/total time)
- Small view of what’s happening on the projected view
- More time to prepare
Well, writing this post went alright I guess. Feel free to come with feedback if you have any own experience from a similar scenario.