Hydrogen - Linux Drum Machine |
00001 /* 00002 * Hydrogen 00003 * Copyright(c) 2002-2003 by Alex >Comix< Cominu [comix@users.sourceforge.net] 00004 * 00005 * http://hydrogen.sourceforge.net 00006 * 00007 * This program is free software; you can redistribute it and/or modify 00008 * it under the terms of the GNU General Public License as published by 00009 * the Free Software Foundation; either version 2 of the License, or 00010 * (at your option) any later version. 00011 * 00012 * This program is distributed in the hope that it will be useful, 00013 * but WITHOUT ANY WARRANTY, without even the implied warranty of 00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 * GNU General Public License for more details. 00016 * 00017 * You should have received a copy of the GNU General Public License 00018 * along with this program; if not, write to the Free Software 00019 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00020 * 00021 * $Id: NullDriver.h,v 1.1 2003/04/16 21:58:06 comix Exp $ 00022 * 00023 */ 00024 00025 00026 #ifndef NULL_AUDIO_DRIVER_H 00027 #define NULL_AUDIO_DRIVER_H 00028 00029 #include "GenericDriver.h" 00030 00031 typedef int (*audioProcessCallback)(unsigned long, void *); 00032 00033 //---------------------------------------------------------------------------- 00037 class NullDriver : public GenericDriver { 00038 public: 00039 virtual string getClassName() { return "NullDriver"; } 00040 00042 NullDriver(audioProcessCallback processCallback); 00043 00045 ~NullDriver(); 00046 00047 int connect(); 00048 void disconnect(); 00049 void write(float* buffer_L, float* buffer_R, unsigned int bufferSize); 00050 void setBufferSize(uint bufferSize); 00051 uint getBufferSize(); 00052 uint getSampleRate(); 00053 00054 00055 }; 00056 00057 #endif 00058