Output video from Linux box to a TV

Q I'm trying to output video from a Linux box to a TV for my son. I've tried Dreamlinux, Macpuppy, GeeXbox Live and Ubuntu 9.04. Only Ubuntu worked, and that needed the Nvidia driver, and that meant the resolution dropped to 800x600. Even then I had to tweak xorg.conf to get it working. Two of my laptops output to composite and one to S-Video. The Ubuntu success was on an old Toshiba Satellite PIII 1.6GHz output to composite. Is there an easier way? I do hope so, as it's embarrassing to hear my son say 'but Windows just does it'.

A Using the composite or S-Video output from a graphics card usually requires that you enable this, in xorg.conf, the BIOS, or both. The BIOS option, if present, sets which video outputs are available, while the xorg.conf setting determines which is actually used. With a composite or S-Video output, you often have little or no control over the resolution beyond an option to use NTSC or PAL values. As composite is output only, it has no way of getting information from the display in the way that X.org does with monitors, so you will need an xorg.conf to set this up, unless the BIOS has a setting to force all output to the composite output (the VIA Mini-ITX boards do this, with output being sent to TV, VGA or both, according to the BIOS setting). You define the settings in a Device section of xorg.conf. The settings can be different for each driver (see the man page of your particular driver for details) but for an Nvidia card you would use:

Section "Device"
Identifier  "TV-Composite"
Driver       "nvidia"
Option      "TVStandard" "PAL-I"
Option      "UseDisplayDevice" "TV"
Option      "TVOutFormat" "COMPOSITE"
Screen 1
EndSection

The TVStandard setting is country-specific; PAL-I is the correct value for the UK. The Nvidia driver documentation lists the various options. The TVOutFormat setting should be set to SVIDEO if appropriate. You should also add 'Screen 0' to your existing Device section. Now you have two screens, one on the VGA output and one on the TV output. Add a new Screen section to xorg.conf:

Section "Screen"
Device "TV-Composite"
Identifier "TVscreen"
Monitor "TV-monitor"
EndSection

You also need to create a new Monitor section for your TV, calling it TV-monitor (or whatever you used in the second Screen section). Now edit the ServerLayout section to contain

Screen 0 "Screen0" # or whatever your original screen is called
Screen 1 "TV-composite" "Clone"

This will duplicate the primary screen on to the TV screen, so everything should be repeated on the TV too. With an Nvidia card, much of this work can be done with the nvidia-settings program, although you will need to run it as root if you want it to be able to rewrite your xorg.conf for you. As always, you should make a backup copy of xorg.conf before you do any of the above.

Back to the list