Vorraussetzungen:
- Xorg lauffähig mit nvidia treiber
- mplayer
1. Anpassen der xorg.conf
Folgende Sections müsst ihr zu eurer xorg.conf hinzufügen:
Code: Select all
Section "Monitor"
Identifier "TV"
HorizSync 30-50
VertRefresh 60
EndSectionCode: Select all
Section "Device"
Identifier "NV2"
Driver "nvidia"
BusID "PCI:3:0:0"
Option "TVStandard" "PAL-G"
Option "NoLogo"
Option "IgnoreEDID" "off"
Option "ConnectedMonitor" "TV"
Option "TVoutFormat" "COMPOSITE"
EndSectionCode: Select all
Option "TVoutFormat" "SVIDEO"Code: Select all
Section "Screen"
Identifier "Screen1"
Device "NV2"
Monitor "TV"
DefaultColorDepth 16
Subsection "Display"
Depth 16
Modes "800x600"
EndSubsection
EndSection
Code: Select all
Section "ServerLayout"
Identifier "tv_out"
Screen "Screen1"
InputDevice "Mouse1" "CorePointer"
InputDevice "Keyboard1" "CoreKeyboard"
EndSection2. Video starten:
Nun könnt ihr aus eurem aktuellen X-Server das Video mit folgendem Script starten:
Code: Select all
#!/bin/bash
# ********************************************************************* #
# Script to start mplayer-movie direct on the second x-server (tv-out) #
# Author: Matthias Schröer #
# Date: 04.11.2004 #
# License: GPL #
# Version 0.1 #
# ********************************************************************* #
# Config
DISPLAY_NO=":1" # specifies the displaynumber used by the new x-server
LAYOUT_NAME="tv_out" # The xorg-server layout
MPLAYER_AO="-ao alsa:mmap:device=hw#0.2 -ac hwac3, -srate 48000" # the ao options for mplayer
MPLAYER_VO="-vo x11" # the vo-options for mplayer
MPLAYER_MISC="" # misc options for mplayer
# Config end
if [ $# == 0 ]; then
echo "Need movie as argument!"
exit 1
fi
X $DISPLAY_NO -ac -layout $LAYOUT_NAME &
sleep 5
X_PID=`ps aux | grep "X $DISPLAY_NO" | grep root | tr -s " " | cut -d " " -f2`
#mplayer -display localhost:1 -vo x11 -fs $1
mplayer -zoom -double $MPLAYER_VO -display localhost${DISPLAY_NO} -fs $MPLAYER_AO $MPLAYER_MISC "$1"
kill $X_PID
exit 0Nun ruft man einfach
Code: Select all
tv_out /pfad/zum/video.aviViel spass beim Filme gucken!!
Bei Fragen und Anregungen bitte posten!
Edit:
Probleme:
Manchmal muss man das script mehrmals hintereinander starten bis der film anläuft. Jedenfalls ist das bei mir so. Wenn da einer weiss woran das liegt, dann bitte ich um aufklärung. Der mplayer sagt dann nämlich einfach sofort: Dateiende erreicht.





