Gnu Lightweight Opuscule TeleVision

Latest news at the bottom of this page.

Disclaimer: Some assembly required.



GLOTV is a free DVR system that I am developing as a "lightweight" alternative to MythTV and Freevo. It was prompted by my need for a useful interface to my experimental libusb driver for the Hauppauge WinTV-PVR-usb2 device for video input. That driver has since been obsoleted by a much better kernel driver for Linux 2.6+ systems. But GLOTV lives on anyway, since it is practical enough for my own purposes: watching TV in a window on the computer screen, watching MPEG/AVI/Quicktime/Flash/etc movies on the TV, recording video, viewing photographs on the TV, and (in an extremely primitive way) playing music through the TV speakers.

GLOTV is free software in the GNU sense: all of the GLOTV code is GPL-licensed. Other components that you might need for a complete working system might not be. Caveat emptor.



Not yet implemented:

Author: Björn Danielsson


2021-10-13 Version 2.0alpha15. Various tweaks to make MP4 HD work in MPEG transport streams. Also disabled the code that captures a whole 8MHz DVB-multiplex at once. It's fragile enough as it is, so that feature will simply have to wait.

2021-03-25 Version 2.0alpha14. Fixed a minor bug and a compilation warning in glotvschedule.

2017-02-25 Version 2.0alpha13. Preliminary support for the linuxtv DVBv5 API (in capture/play5.pl). This means support for DVB-T2 (HDTV capture for terrestrial freeview broadcasts, yay!) and the future potential of extracting multiple programs simultaneously from an 8MHz DVB-multiplex with a single tuner. The latter will require some serious re-architecturing of the capture layer however, so don't hold your breath. On the other hand, GLOTV is just 3087 lines of Perl + 222 lines of C, so it's not like it's impossible.

Note: The DVBv5 stuff requires a fairly recent version of ffmpeg.

2017-02-07 Version 2.0alpha12. Added hook for filtering the data stream while recording. See $config{rec_filter} in the sample config.

2016-03-28 Version 2.0alpha11 uploaded, with the following backward-compatible changes:

Note: It's unlikely that version 2.0 will ever be released, since I no longer use the GLOTV kiosk mode myself. I use Kodi (formerly known as "Xbox Media Center") which is vastly superior, and nowadays there are plenty of other solutions for the living room anyway. However, I still use the recording and streaming features (using pvrusb2 and DVB-T specifically), so I might do a final release (3.0?) with only that stuff, stripping out the kiosk mode features. But don't hold your breath.

2010-08-16 Version 2.0alpha10. Updated link to twm-kiosk in the installation docs.

2010-05-13 Version 2.0alpha9 uploaded, with some new minor features. In kiosk mode it is now possible to toggle deinterlacing. This is only possible for HDTV output, where pressing "Minus" toggles the deinterlace filter instead of toggling overscan/underscan. MPlayer now runs with SSA/ASS subtitle rendering (-ass). This fixes some problems with OSD, and is generally beneficial. In desktop mode there is a new checkbox "AWS" which controls anamorphic widescreen mode, just as the "Plus" button does in kiosk mode. Finally, the pvrusb2 backend now adjusts the recording volume and the aspect ratio depending on the signal source. This is still experimental, so the adjustments are done directly in the code instead of in glotv.conf.

[Nokia N900]

As a sidenote, an interesting milestone has been reached in that GLOTV can now stream live MPEG2 content to a mobile phone. The phone in question is the Nokia N900. I did this without attempting to install any GLOTV software on the phone, the streaming was accomplished via simpler tools. Here is how to do it: First use the N900 Application Manager to install "MPlayer Movie Player". Then add the "fremantle/tools" Maemo repository, and install the netcat package which provides the nc command:

apt-get install netcat

Then create the following shell script, after first changing the hostname and port to match your own GLOTV server:

echo play | nc glotv.example.com 1150 | \
    mplayer -quiet -framedrop -ass -fs -monitorpixelaspect 39:40 -cache 2048 -autosync 10 -

Running this script will show the currently selected TV channel in fullscreen mode. The same script can of course be used on any machine that has nc and mplayer.

2009-08-17 Version 2.0alpha8 uploaded. Two bugs fixed: got rid of the flickering of OSD text when using yadif deinterlacing (enabled for all progressive-scan output). The magic MPlayer filter option expand=osd=1 did the trick. The other bug was that the "Play File" button in desktop mode didn't work for UTF-8 filenames, due to a broken Perl/Tk widget. The workaround was to replace "getOpenFile" with "FileSelect". The former is broken, the latter works painlessly even if the filesystem and the xglotv host use different Unicode normalization schemes (e.g. MacOS-generated filenames consisting of decomposed Unicode aka NFD, with xglotv running on Linux where there normalization is composed Unicode aka NFC).

2009-02-01 Version 2.0alpha7 uploaded, with the following news:

Version 2.0alpha6 uploaded. Support for multiple tuners in scheduled recordings, plus some bug fixes and minor adjustments. The web interface has a new field "Tuner" where you fill in a number 0, 1, 2, etc which is an index representing the tuner to use. Changing the parameters of a scheduled recording works almost as before: if you change anything except the starting time or the tuner index, the new parameters will overwrite the old ones. If you change the starting time or the tuner, a new entry will be created, so you will need to cancel the old one manually.

Simultaneous recordings may be mixed in the same directory. The filenames contain a letter a, b, c, etc that indicates the corresponding tuner index, so the generated filenames will be different even when the starting time is the same. But if you want to avoid filesystem fragmentation you should configure the glotvd servers to use spool directories that reside on different partitions or different disks.

Known bugs: the player process will hang if you change DVB channel while playing video. New clients (i.e. glotvrecord) will however get the new channel without problems.

Version 2.0alpha5 uploaded. Two new experimental features, plus some minor bug fixes. The first feature is a backend for LinuxTV DVB drivers. Only terrestrial digital broadcast is supported at the moment. You will need to load the kernel modules appropriate for your DVB tuner, install the program tzap from linux-dvb-apps together with my patch that makes tzap responsive when running behind a pipe. When I find the time, I will add my notes on how I configured LinuxTV for my Hauppauge Nova-T USB-Stick.

The second experimental feature is (surprise!) preliminary support for multiple video capture devices. It works like this: For each device, a separate glotvd server process is started, configured to listen on its own TCP port and/or Unix socket, perhaps even on different machines. The default configuration file for xglotv contains a special declaration that points to a list of alternative client configurations. When giving a "switch tuner" command in the GUI, the next alternative configuration is loaded, presumably selecting a different glotvd server process. The minimum alternative configuration needed for a client is a different port or socket, and a different pid file for glotvrecord, since recording is technically a client activity. But this is still very much work in progress, so the exact details will probably change...

Note: The glotv scheduler doesn't know about multiple tuners yet, so scheduled recordings will always use the default tuner.

Version 2.0alpha4 uploaded. The only change is a bug fix: The table "lirc_translations" was missing from etc/glotv.conf.sample. It is currently needed for Hauppauge IR remotes to work, and it currently supports two models. See my LIRC tips for configuration details.

Version 2.0alpha3 uploaded, with two minor enhancements. Pressing "Play" while paused single-steps one frame. The autorepeat magic for fast forward and reverse has been adjusted to be slightly more useful.

Bug fix: version 2.0alpha2 fixes a race condition in the new glotvschedule system. The "at" job that handles the recording now does an atomic "test and clear" operation before proceeding.

Version 2.0alpha1 uploaded. Lots of things have changed:

Version 1.0 uploaded. I decided to tag this as a final 1.0 release since a year has gone by since the previous beta, and since work on 2.0 has recently begun. Two new features have been added in this release, both of them available in kiosk mode only. The first is an "underscan" mode for viewing special content on TV, together with a command that toggles between overscan and underscan. The second is automatic filtering of any file names that match the regexp ^\.(_|DS_Store$). This filters out attribute files that are created by MacOS when writing to an NFS share.

Version 1.0beta2 uploaded. Big cleanup of aspect ratio handling. The special 16:9 anamorphic rescaling in cinemascope mode has been deprecated and replaced with a button that toggles between 4:3 and 16:9 aspect for the display device, or more exactly between 12:11 and 16:11 pixel aspect ratios. MPlayer then performs the correct rescaling. This version has only been tested on MPlayer-1.0rc1.

Version 1.0beta1 uploaded. New glotvd commands "channel_lock" and "play_locked". These ensure that the channel is locked when a client is recording. Any client can override the lock, but only by starting a new recording. Fast forward and reverse now automatically mutes the sound. Support for Cinemascope format via 16:9 anamorphic aspect (kiosk mode only). Bug fixed that prevented unsegmented recordings. After more than a year without changes, I decided to call this a beta release.

Version 1.0alpha9 uploaded. A new feature in the kiosk mode is that pressing "Pause" on the Xbox remote control will open an xterm window with a shell. Upon termination, xglotv will regain focus and hide the cursor. Various bug fixes in xglotv: most notably "%" characters in mplayer options are now handled correctly (useful for e.g. -geometry X%:Y%). While tracking down this bug, a bug in MPlayer itself was discovered. A patch was submitted and is available in MPlayer CVS after 2005-02-09.

Version 1.0alpha8 uploaded. Makefile and glotvrecord.c have been patched for FreeBSD. A week ago I created a temporary file server by putting a 200 GB disk in an old 240 MHz machine (with 32 MB RAM) and installed FreeBSD on it. After using it as an NFS server for a while, I then tried using it as a GLOTV recording client, and to my surprise it used less resources running glotv than by recording via NFS.

Version 1.0alpha7 uploaded. Updated etc/glotv.conf.sample for NTSC tuner support. Also fixed a bug in the kiosk-mode photo album viewer (image rotation was broken).

Version 1.0alpha6 uploaded. Added anamorphic widescreen (16:9) choices in desktop mode, and made some various minor improvements in the desktop mode interface. Also fixed a couple of bugs in glotvd.

Version 1.0alpha5 uploaded. MPlayer in kiosk mode now switches to 720x576 resolution (non-square pixels) while playing. Updated pvrusb2 backend to handle switching between TV tuner and composite video inputs.

Version 1.0alpha4 uploaded. This is mainly a bugfix release. A number of things that ended up broken in alpha3 have been fixed.

Changed the square-pixel mode from 768x576 to 792x576, to account for the fact that 720x576 isn't really a 4:3 format.

Added photo album viewer for the kiosk mode. Pressing the DISPLAY button in the file browser enables still-image viewing. Press LEFT/RIGHT to rotate. ImageMagick is a prerequisite for this: /usr/bin/convert is used to resize the next image in the browser, which is then preloaded while the previous one is displayed. Without preloading there is a painfully long delay when loading 1600x1200 size images on the Xbox.

First version uploaded.