/*
    This file is part of kenvy24 KDE multimedia utility
    Copyright (c) 2007  Valentin RUSU kenvy24@rusu.info

    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) version 3 or, at the discretion of KDE e.V. (which shall
    act as a proxy as in section 14 of the GPLv3), 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
    MERCHANTABILITY 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, see <http://www.gnu.org/licenses/>.
*/
#ifndef _ENVY_STRUCTS_H_
#define _ENVY_STRUCTS_H_

#define UPDATE_TIMER_INTERVAL 20

/**
 * Define this macro to enable driver events tracing
 */
//#define TRACE_DRIVER_EVENTS

/**
 * Number of stereo outputs
 * NOTE : be warned that, for some reasons, alsa tool envy24control counts each
 * pcm output independently
 */
#define MAX_PCM_OUTPUTS   4

/**
 * NOTE: a channel has two, left and right, streams
 */
#define MAX_SPDIF_CHANNELS  1

/**
 * number of *stereo* input channels
 */
#define MAX_INPUT_CHANNELS  4

/**
 * number of *stereo* output channels
 */
#define MAX_OUTPUT_CHANNELS 4

/**
 * number of *stereo* output SPDIF channels
 */
#define MAX_SPDIF_CHANNELS	1

/**
 * this is the maximum level for a channel
 */
#define MAX_LEVEL 255

/**
 * Structure used by level monitors
 */
struct StereoLevels {
  int left;
  int right;
};

enum LeftRight {
    LEFT = 0,
    RIGHT = 1
};

/**
 * Envy cards handle two kinds of routes
 */
enum RouteKind  {
    ANALOG,
    SPDIF
};

/**
 * define maximum value for panning
 */
#define PAN_MAX 32
#define PAN_LEFT -PAN_MAX
#define PAN_RIGHT PAN_MAX

#endif // _ENVY_STRUCTS_H_
