Update of /cvsroot/freevo/freevo/WIP/RobShortt
In directory sc8-pr-cvs1:/tmp/cvs-serv21654

Added Files:
        channels.py 
Log Message:
thinking out loud


--- NEW FILE: channels.py ---
#if 0 /*
# -----------------------------------------------------------------------
# channels.py - Freevo module to handle channel changing.
# -----------------------------------------------------------------------
# $Id: channels.py,v 1.1 2003/09/19 02:22:20 rshortt Exp $
#
# Notes:
# Todo:        
#
# -----------------------------------------------------------------------
# $Log: channels.py,v $
# Revision 1.1  2003/09/19 02:22:20  rshortt
# thinking out loud
#
#
#
# -----------------------------------------------------------------------
# Freevo - A Home Theater PC framework
# Copyright (C) 2003 Krister Lagerstrom, et al. 
# Please see the file freevo/Docs/CREDITS for a complete list of authors.
#
# This program is free software; you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation; either version 2 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful, but
# WITHOUT ANY WARRANTY; without even the implied warranty of MER-
# CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General
# Public License for more details.
#
# You should have received a copy of the GNU General Public License along
# with this program; if not, write to the Free Software Foundation, Inc.,
# 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
#
# ----------------------------------------------------------------------- */
#endif

import config

import freq, v4l2


VIDEO_GROUPS = [
    VideoGroup(vdev='/dev/video0',
               adev=None,
               input='tuner',
               tuner_type='external',
               tuner_chan='3',
               desc='Bell ExpressVu',
               recordable=True),
    VideoGroup(vdev='/dev/video1',
               adev='/dev/dsp1',
               input='tuner',
               desc='ATI TV-Wonder',
               recordable=True),
    VideoGroup(vdev='/dev/video2',
               adev=None,
               input='webcam',
               desc='Logitech Quickcam',
               recordable=False),
]



class FreevoChannels:

    def __init(self):
        self.chan_index = 0


    def chanUp(self):
        """
        Using this method will not support custom frequencies.
        """
        pass


    def chanUpFreq(self):
        pass


    def chanDown(self):
        """
        Using this method will not support custom frequencies.
        """
        pass


    def chanDownFreq(self):
        pass


    def chanSet(self):
        """
        Using this method will not support custom frequencies.
        """
        pass


    def chanSetFreq(self):
        pass


    def TunerSetChannel(self, tuner_channel):
        for pos in range(len(config.TV_CHANNELS)):
            channel = config.TV_CHANNELS[pos]
            if channel[2] == tuner_channel:
                self.tuner_chidx = pos
                return
        print 'ERROR: Cannot find tuner channel "%s" in the TV channel listing' % 
tuner_channel
        self.tuner_chidx = 0


    def getChannel(self):
        return config.TV_CHANNELS[self.tuner_chidx][2]


    def getNextChannel(self):
        return (self.tuner_chidx+1) % len(config.TV_CHANNELS)


    def getPrevChannel(self):
        return (self.tuner_chidx-1) % len(config.TV_CHANNELS)





-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
_______________________________________________
Freevo-cvslog mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/freevo-cvslog

Reply via email to