These instructions apply only to Mac mini models that have the Intel GMA 950 graphics device, with Apple's DVI-to-video adapter connected to a PAL TV. Only the S-video output has so far been tested by me, but everything should reasonably work the same for composite video. If you have a modern TV with VGA or HDMI connectors, this guide is not for you. At least not until my TV gets upgraded so I am forced to update this page ;-)
OK, this happened in January 2009, and now it's already 2010 and I still haven't updated this page. For my new TV, the Mac mini is connected via a short cheap HDMI/DVI-D cable.
When done, watching movies is as simple as startx and then mplayer -vo xv -fs -monitorpixelaspect 12:11 file.mpg, for pre-recorded material. If you want to record also, and maybe use a remote control, take a look at my web page The Mac mini as a digital video recorder. But first, follow the steps below:
Section "Device" Identifier "Intel 945GM" Driver "intel" Option "Monitor-TMDS-1" "My Monitor" Option "Monitor-VGA" "My Monitor" Option "Monitor-TV" "tv" EndSectionThe strings "My Monitor" and "tv" correspond to identifiers in monitor sections, where "My Monitor" is the pre-configured default monitor. Leave it alone since you may want or need to hook up the Mac mini to a regular monitor in the future. Create a new monitor section for the TV:
Section "Monitor" Identifier "tv" Option "Enable" "true" Option "TV Format" "PAL" Option "PreferredMode" "720x576" Option "DPMS" "false" Modeline "720x576" 13.500 720 760 824 864 576 599 601 625 EndSectionNote: This resolution/timing mode only works for standard PAL televsion (e.g. B/G/D/K etc). PAL-N should work with the same modeline, but "TV Format" should be changed. See the manpage for "intel" for details. PAL-M and NTSC needs different resolution and timing, so you will have to find another modeline to use. If you create your own modeline, make sure you don't include any of the options hsync, vsync, or interlaced. Otherwise the driver will reject the mode without explaining why. The pixel clock should reflect the "full" frame-rate (i.e. 25fps for PAL, 29.97fps for NTSC) and in my PAL modeline above I have chosen it to correspond exactly to the ITU-R BT.601 standard luminance sampling frequency of 13.5 MHz.
xrandr --output TV --set BOTTOM 0 --set RIGHT 0 --set TOP 0 --set LEFT 0The default setting can be restored by:
xrandr --output TV --set BOTTOM 37 --set RIGHT 46 --set TOP 36 --set LEFT 54This feature requires xorg 7.3 or later, which is included in Slackware 12.1.
A simple solution is to change MPlayer to search for XVideo ports in the reverse order: it will then find the correct port first. A one-line patch to MPlayer-1.0rc2 that accomplishes this is available here.
Now the built-in MPlayer controls can be used to change saturation etc, but sometimes the "overlay" port gets connected to the wrong output pipe, resulting in a blue screen instead of the video picture. To fix this you need the program xvattr which can be downloaded from http://freshmeat.net/projects/xvattr/. The command to associate the overlay port with the TV output pipe then looks like this:
xvattr -p $XVPORT -a XV_PIPE -v 1where $XVPORT is the overlay port number. That port number can be determined at runtime like this:
XVPORT=`xvinfo | grep 'port base:' | tail -1 | cut -d: -f2`
or if you prefer, by a small Perl script available here.
The program xvattr can also be used to set the initial saturation and contrast. I have the following lines in my .xinitrc:
XVPORT=`perl find-xv-overlay-port.pl` if [ "$XVPORT" != "" ]; then xvattr -p $XVPORT -a XV_PIPE -v 1 xvattr -p $XVPORT -a XV_SATURATION -v 140 xvattr -p $XVPORT -a XV_CONTRAST -v 50 fi