// -*- c++ -*-

/*
 *
 * Copyright (C) 2002 Richard Moore <rich@kde.org>
 *
 * This library is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Library General Public
 * License as published by the Free Software Foundation; either
 * version 2 of the License, or (at your option) any later version.
 *
 * This library is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 * Library General Public License for more details.
 *
 * You should have received a copy of the GNU Library General Public License
 * along with this library; see the file COPYING.LIB.  If not, write to
 * the Free Software Foundation, Inc., 59 Temple Place - Suite 330,
 * Boston, MA 02111-1307, USA.
 */


#ifndef QTVISIONIFACE_H
#define QTVISIONIFACE_H

#include <dcopobject.h>
#include <dcopref.h>

/**
 * A DCOP interface for QtVision.
 *
 * @author Richard Moore, rich@kde.org
 */
class QtVisionIface : virtual public DCOPObject
{
    K_DCOP
k_dcop:
    /**
     * Ask the user to select a device.
     */
    virtual void selectDevice()=0;

    /**
     * Sets the source to use.
     */
    virtual void setSource( const QString &src )=0;

    /**
     * Starts capture.
     */
    virtual void start()=0;

    /**
     * Stops capture.
     */
    virtual void stop()=0;

    /**
     * Starts video stream, leaving the audio alone.
     */
    virtual void startVideo()=0;

    /**
     * Stops video stream, leaving the audio alone.
     */
    virtual void stopVideo()=0;

    /**
     * Returns a DCOP reference to the ChannelStore.
     */
    virtual DCOPRef channelStoreIface()=0;

    /**
     * Returns a DCOP reference to the current Channel.
     */
    virtual DCOPRef channelIface()=0;

    /**
     * Returns the name of the current Channel.
     */
    virtual QString channelName() const=0;

    /**
     * Returns the number of the current Channel.
     */
    virtual int channelNumber() const=0;

    /**
     * Changes the channel to the one preceding the current, wrapping
     * round if we are currently showing the first channel.
     */
    virtual void channelDown()=0;

    /**
     * Changes the channel to the one following the current, wrapping
     * round if we are currently showing the last channel.
     */
    virtual void channelUp()=0;
    
    /**
     *  Recall the previous channel.
     */
     virtual void previousChannel() = 0;

    //
    // Sound
    //

    /**
     * Mutes the sound.
     */
    virtual void volumeMute()=0;

    /**
     * Increases the volume.
     */
    virtual void volumeUp()=0;

    /**
     * Decreases the volume.
     */
    virtual void volumeDown()=0;

    /**
     * Sets the volume.
     */
    virtual void setVolume(int vol)=0;

    /**
     * Sets the volume.
     */
    virtual void setVolume(int left, int right)=0;

    //
    // IO
    //

    /**
     * Launches the default channel import dialog.
     */
    virtual void importDefaultChannels() = 0;

    /**
     * Launched a file open dialog.
     */
    virtual void openChannelFile() = 0;

    /**
     * Loads channels from the given filename.
     */
    virtual void openChannelFile(const QString &filename) = 0;

    //
    // Misc
    //

    /**
     * Toggle video desktop on or off.
     */
    virtual void setVideoDesktop(bool on) = 0;

    /**
     * Launches the settings dialog.
     */
    virtual void settings()=0;

    /**
     * Launches the channel wizard and returns the dialog return value.
     */
    virtual int launchWizard()=0;    
};

#endif // QTVISIONIFACE_H


// Local Variables:
// c-basic-offset: 4
// End:

