00001 /* scope_plugin.h 00002 * Copyright (C) 1999-2002 Andy Lo A Foe <andy@alsaplayer.org> 00003 * 00004 * This program is free software; you can redistribute it and/or modify 00005 * it under the terms of the GNU General Public License as published by 00006 * the Free Software Foundation; either version 2 of the License, or 00007 * (at your option) any later version. 00008 * 00009 * This program is distributed in the hope that it will be useful, 00010 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00011 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00012 * GNU General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU General Public License 00015 * along with this program; if not, write to the Free Software 00016 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. 00017 * 00018 * 00019 * 00020 * $Id: scope_plugin.h,v 1.5 2003/04/08 15:14:59 adnans Exp $ 00021 * 00022 */ 00023 00024 #ifndef __scope_plugin_h__ 00025 #define __scope_plugin_h__ 00026 00027 /* 00028 * Format of version number is 0x1000 + version 00029 * So 0x1001 is *binary* format version 1 00030 * THE VERSION NUMBER IS *NOT* A USER SERVICABLE PART! 00031 */ 00032 00036 #define SCOPE_PLUGIN_BASE_VERSION 0x1000 00037 00043 #define SCOPE_PLUGIN_VERSION (SCOPE_PLUGIN_BASE_VERSION + 7) 00044 00053 #define SCOPE_NICE 10 00054 00062 #define SCOPE_SLEEP 20000 00063 00068 #define SCOPE_BG_RED 0 00069 00074 #define SCOPE_BG_GREEN 0 00075 00080 #define SCOPE_BG_BLUE 0 00081 00087 typedef int scope_version_type; 00088 00096 typedef int(*scope_init_type)(void *arg); 00097 00102 typedef void(*scope_start_type)(void); 00103 00109 typedef int(*scope_running_type)(void); 00110 00115 typedef void(*scope_stop_type)(void); 00116 00122 typedef void(*scope_shutdown_type)(void); 00123 00136 typedef void(*scope_set_data_type)(void *buffer, int count); 00137 00150 typedef void(*scope_set_fft_type)(void *buffer, int samples, int channels); 00151 00156 typedef struct _scope_plugin 00157 { 00161 scope_version_type version; 00165 char *name; 00170 char *author; 00175 void *handle; 00180 scope_init_type init; 00185 scope_start_type start; 00190 scope_running_type running; 00195 scope_stop_type stop; 00200 scope_shutdown_type shutdown; 00204 scope_set_data_type set_data; 00209 scope_set_fft_type set_fft; 00210 } scope_plugin; 00211 00217 typedef scope_plugin*(*scope_plugin_info_type)(void); 00218 00219 #endif