AlsaPlayer  0.99.80
scope_plugin.h
Go to the documentation of this file.
00001 /*  scope_plugin.h
00002  *  Copyright (C) 1999-2002 Andy Lo A Foe <andy@alsaplayer.org>
00003  *
00004  *  This file is part of AlsaPlayer
00005  *
00006  *  AlsaPlayer is free software; you can redistribute it and/or modify
00007  *  it under the terms of the GNU General Public License as published by
00008  *  the Free Software Foundation; either version 3 of the License, or
00009  *  (at your option) any later version.
00010  *
00011  *  AlsaPlayer is distributed in the hope that it will be useful,
00012  *  but WITHOUT ANY WARRANTY; without even the implied warranty of
00013  *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014  *  GNU General Public License for more details.
00015  *
00016  *  You should have received a copy of the GNU General Public License
00017  *  along with this program; if not, see <http://www.gnu.org/licenses/>.
00018  *
00019  *  $Id: scope_plugin.h 1250 2007-07-08 14:17:12Z dominique_libre $
00020  *  
00021 */ 
00022 
00023 #ifndef __scope_plugin_h__
00024 #define __scope_plugin_h__
00025 
00026 /*
00027  * Format of version number is 0x1000 + version
00028  * So 0x1001 is *binary* format version 1
00029  * THE VERSION NUMBER IS *NOT* A USER SERVICABLE PART!
00030  */
00031 
00035 #define SCOPE_PLUGIN_BASE_VERSION 0x1000
00036 
00042 #define SCOPE_PLUGIN_VERSION    (SCOPE_PLUGIN_BASE_VERSION + 7)
00043 
00052 #define SCOPE_NICE      10
00053 
00061 #define SCOPE_SLEEP 20000
00062 
00067 #define SCOPE_BG_RED    0
00068 
00073 #define SCOPE_BG_GREEN  0
00074 
00079 #define SCOPE_BG_BLUE   0
00080 
00086 typedef int scope_version_type;
00087 
00095 typedef int(*scope_init_type)(void *arg);
00096 
00101 typedef void(*scope_start_type)(void);
00102 
00108 typedef int(*scope_running_type)(void);
00109 
00114 typedef void(*scope_stop_type)(void);
00115 
00121 typedef void(*scope_shutdown_type)(void);
00122 
00135 typedef void(*scope_set_data_type)(void *buffer, int count);
00136 
00149 typedef void(*scope_set_fft_type)(void *buffer, int samples, int channels);
00150 
00155 typedef struct _scope_plugin
00156 {
00160         scope_version_type version;
00164         char *name;
00169         char *author;
00174         void *handle;
00179         scope_init_type init;
00184         scope_start_type start;
00189         scope_running_type running;
00194         scope_stop_type stop;
00199         scope_shutdown_type shutdown;
00203         scope_set_data_type set_data;
00208         scope_set_fft_type set_fft;
00209 } scope_plugin;
00210 
00216 typedef scope_plugin*(*scope_plugin_info_type)(void);
00217 
00218 #endif