Dirk Meyer wrote:

we got only a few bugreports for 1.4rc1. This sounds good. So here is the roadmap for 1.4

Sometime before 1.4, someone please take a look at the FreeBSD patches I sent (original message attached.) Two of them are essential, the others would be nice to have.

Also - if we want beastie on the splash screen - could you sent me the sources for the JPG? (I assume you used gimp, photoshop or illustrator?) Alternatively, I can send you beastie as an SVG, and you put him somewhere.

Thanks,
Lars
--
Lars Eggert <[EMAIL PROTECTED]>           USC Information Sciences Institute
--- Begin Message --- Lars Eggert wrote:

two more patches attached. The first (freevo.patch) eliminates "disown" which FreeBSD's sh doesn't have.

The second removes the audio options from VCR_CMD for FreeBSD. The
bsdbt848 driver does not seem to support them. It also adds a new
TV_OPTS variable that can be used to pass additional options to mplayer
in TV mode. (I use it to turn on deinterlacing.)

Here's an updated patch set. It has all the above changes, plus these:

1. Make src/setup_freevo.py find mencoder, and use that instead of the
absolute path in VCR_CMD.

2. Make VCR_CMD use TV_REC_SIZE and TV_REC_OUTFMT instead of hardcoded
values.

3. Make the recordserver switch the recording input to "line" on FreeBSD
before calling mencoder. Mplayer on FreeBSD does not support "adevice",
and if the mixer is not set up correctly, no audio will be recorded.

Please review.

Lars
--
Lars Eggert <[EMAIL PROTECTED]>           USC Information Sciences Institute

Index: freevo
===================================================================
RCS file: /cvsroot/freevo/freevo/freevo,v
retrieving revision 1.85
diff -u -r1.85 freevo
--- freevo      23 Sep 2003 13:31:23 -0000      1.85
+++ freevo      5 Oct 2003 17:14:01 -0000
@@ -188,7 +188,9 @@
     if [ "$1" = "start" ]; then
        $RUNAPP python "$script" &
        echo $! > $PID_FILE
-       disown
+       if [ `uname -s` != "FreeBSD" ]; then
+           disown
+       fi
     elif [ "$1" = "stop" ]; then
        if [ -e $PIDFILE ]; then
            kill -KILL `cat $PID_FILE` > /dev/null 2>&1
@@ -356,7 +358,9 @@
     $RUNAPP python $OPTIMZE $FREEVO_PYTHON/main.py $@ > /dev/null 2>&1 &
     
     echo $! > $PID_FILE
-    disown
+    if [ `uname -s` != "FreeBSD" ]; then
+        disown
+    fi
     exit 0
 fi
 
Index: freevo_config.py
===================================================================
RCS file: /cvsroot/freevo/freevo/freevo_config.py,v
retrieving revision 1.267
diff -u -r1.267 freevo_config.py
--- freevo_config.py    4 Oct 2003 14:38:10 -0000       1.267
+++ freevo_config.py    5 Oct 2003 17:14:02 -0000
@@ -875,6 +875,10 @@
     TV_DEVICE = '/dev/video0'
     TV_INPUT = 0
 
+# Additional options to pass to mplayer in TV mode.
+# For example, TV_OPTS = '-vop pp=ci' would turn on deinterlacing.
+TV_OPTS = ''
+
 TV_SETTINGS = '%s television %s %s' % (CONF.tv, CONF.chanlist, TV_DEVICE)
 
 # This is the size (in MB) of the timeshift buffer, ie: how long you can
@@ -928,22 +932,45 @@
 RECORD_SERVER_IP = 'localhost'
 RECORD_SERVER_PORT = 18001
 
+if os.uname()[0] == 'FreeBSD':
+  # FreeBSD's bsdbt848 TV driver doesn't support audio settings?
+  VCR_AUDIO = ''
+else:
+  VCR_AUDIO = (':adevice=%s' % AUDIO_DEVICE +
+               ':audiorate=32000' +         # 44100 for better sound
+               ':forceaudio:forcechan=1:' + # Forced mono for bug in my driver
+               'buffersize=64')             # 64MB capture buffer, change?
+
+# TV capture size for viewing and recording. Max 768x480 for NTSC,
+# 768x576 for PAL. Set lower if you have a slow computer!
 #
+# For the 'tvtime' TV viewing application, only the horizontal size is used.
+# Set the horizontal size to 400 or 480 if you have a slow (~500MHz) computer,
+# it still looks OK, and the picture will not be as jerky.
+# The vertical size is always either fullscreen or 480/576 (NTSC/PAL)
+# for tvtime.
+TV_VIEW_SIZE = (640, 480)
+TV_REC_SIZE = (320, 240)   # Default for slower computers
+
+# Input formats for viewing and recording. The format affect viewing
+# and recording performance. It is specific to your hardware, so read
+# the MPlayer docs and experiment with mplayer to see which one fits
+# your computer best.
+TV_VIEW_OUTFMT = 'yuy2'   # Better quality, slower on pure FB/X11
+TV_REC_OUTFMT = 'yuy2'
+
 # XXX Please see the mencoder docs for more info about the settings
 # XXX below. Some stuff must be changed (adevice), others probably
 # XXX should be ("Change"), or could be in some cases ("change?")
-VCR_CMD = ('/usr/local/bin/mencoder ' +    # Change. Absolute path to the runtime
+VCR_CMD = (CONF.mencoder + ' ' +
            '-tv on:driver=%s:input=%d' % (TV_DRIVER, TV_INPUT) +
            ':norm=%s' % CONF.tv +
            ':channel=%(channel)s' +        # Filled in by Freevo
            ':chanlist=%s' % CONF.chanlist +
-           ':width=320:height=240' +       # Change if needed
-           ':outfmt=yv12' +                # Prob. ok, yuy2 might be faster
+           ':width=%d:height=%d' % (TV_REC_SIZE[0], TV_REC_SIZE[1]) +
+           ':outfmt=%s' % TV_REC_OUTFMT +
            ':device=%s' % TV_DEVICE +
-           ':adevice=%s' % AUDIO_DEVICE +
-           ':audiorate=32000' +            # 44100 for better sound
-           ':forceaudio:forcechan=1:' +    # Forced mono for bug in my driver
-           'buffersize=64' +               # 64 Megabyte capture buffer, change?
+           VCR_AUDIO +                     # set above
            ' -ovc lavc -lavcopts ' +       # Mencoder lavcodec video codec
            'vcodec=mpeg4' +                # lavcodec mpeg-4
            ':vbitrate=1200:' +             # Change lower/higher, bitrate
@@ -956,27 +983,6 @@
 
 # XXX Not used yet
 VCR_SETTINGS = '%s composite1 %s %s' % (CONF.tv, CONF.chanlist, TV_DEVICE)
-
-# TV capture size for viewing and recording. Max 768x480 for NTSC,
-# 768x576 for PAL. Set lower if you have a slow computer!
-#
-# For the 'tvtime' TV viewing application, only the horizontal size is used.
-# Set the horizontal size to 400 or 480 if you have a slow (~500MHz) computer,
-# it still looks OK, and the picture will not be as jerky.
-# The vertical size is always either fullscreen or 480/576 (NTSC/PAL)
-# for tvtime.
-TV_VIEW_SIZE = (640, 480)
-
-# XXX Not used yet
-TV_REC_SIZE = (320, 240)   # Default for slower computers
-
-# Input formats for viewing and recording. The format affect viewing
-# and recording performance. It is specific to your hardware, so read
-# the MPlayer docs and experiment with mplayer to see which one fits
-# your computer best.
-TV_VIEW_OUTFMT = 'yuy2'   # Better quality, slower on pure FB/X11
-# XXX Not used yet
-TV_REC_OUTFMT = 'yuy2'
 
 
 #
Index: src/setup_freevo.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/setup_freevo.py,v
retrieving revision 1.9
diff -u -r1.9 setup_freevo.py
--- src/setup_freevo.py 26 Aug 2003 18:03:32 -0000      1.9
+++ src/setup_freevo.py 5 Oct 2003 17:14:02 -0000
@@ -67,6 +67,7 @@
 CONFIG_VERSION = 2.1
 
 EXTERNAL_PROGRAMS = (("mplayer", "mplayer", 1),
+                     ("mencoder", "mencoder", 0),
                      ("tvtime", "tvtime", 0),
                      ("xine", "xine", 0),
                      ("fbxine", "fbxine", 0),
Index: src/tv/plugins/generic_record.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/plugins/generic_record.py,v
retrieving revision 1.9
diff -u -r1.9 generic_record.py
--- src/tv/plugins/generic_record.py    6 Sep 2003 15:12:04 -0000       1.9
+++ src/tv/plugins/generic_record.py    5 Oct 2003 17:14:02 -0000
@@ -153,6 +153,13 @@
             elif self.mode == 'record':
                 print('Record_Thread::run: cmd=%s' % self.command)
 
+               # The FreeBSD bsdbt848 driver does not support the adevice
+               # setting, so we must switch the mixer to the correct record
+               # source before starting mencoder. I'm not sure how to do
+               # this with Python, so just call the mixer command directly.
+                if os.uname()[0] == 'FreeBSD':
+                    os.system('mixer =rec line rec 100 > /dev/null 2>&1')
+
                 tv_lock_file = config.FREEVO_CACHEDIR + '/record'
                 open(tv_lock_file, 'w').close()
 
Index: src/tv/plugins/mplayer.py
===================================================================
RCS file: /cvsroot/freevo/freevo/src/tv/plugins/mplayer.py,v
retrieving revision 1.20
diff -u -r1.20 mplayer.py
--- src/tv/plugins/mplayer.py   14 Sep 2003 01:38:59 -0000      1.20
+++ src/tv/plugins/mplayer.py   5 Oct 2003 17:14:03 -0000
@@ -173,8 +173,8 @@
             outfmt = 'outfmt=%s' % config.TV_VIEW_OUTFMT
 
             tvcmd = ('tv://%s -tv driver=%s:%s:%s:%s:'
-                     '%s:width=%s:height=%s:%s' %
-                     (tuner_channel, config.TV_DRIVER, device, input, norm, chanlist, 
w, h, outfmt))
+                     '%s:width=%s:height=%s:%s %s' %
+                     (tuner_channel, config.TV_DRIVER, device, input, norm, chanlist, 
w, h, outfmt, config.TV_OPTS))
             
             # Build the MPlayer command
             args = (config.MPLAYER_NICE, config.MPLAYER_CMD, config.MPLAYER_VO_DEV,
@@ -205,8 +205,8 @@
             outfmt = 'outfmt=%s' % config.TV_VIEW_OUTFMT
             
             tvcmd = ('-tv on:driver=%s:%s:%s:%s:'
-                     '%s:width=%s:height=%s:%s' %
-                     (config.TV_DRIVER, device, input, norm, chanlist, w, h, outfmt))
+                     '%s:width=%s:height=%s:%s %s' %
+                     (config.TV_DRIVER, device, input, norm, chanlist, w, h, outfmt, 
config.TV_OPTS))
 
             args = (config.MPLAYER_CMD, config.MPLAYER_VO_DEV,
                     config.MPLAYER_VO_DEV_OPTS, tvcmd,

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature


--- End Message ---

Attachment: smime.p7s
Description: S/MIME Cryptographic Signature

Reply via email to