00001 /* 00002 * Copyright: (C) 2001 Bruce W. Forsberg 00003 * 00004 * This library is free software; you can redistribute it and/or 00005 * modify it under the terms of the GNU Lesser General Public 00006 * License as published by the Free Software Foundation; either 00007 * version 2.1 of the License, or any later version. 00008 * 00009 * This library 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 GNU 00012 * Lesser General Public License for more details. 00013 * 00014 * You should have received a copy of the GNU Lesser General Public 00015 * License along with this library; if not, write to the Free Software 00016 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA 00017 * 00018 * Bruce Forsberg forsberg@tns.net 00019 * 00020 */ 00021 00022 00023 #ifndef _AFLIBAUDIOMEMORYINPUT_H_ 00024 #define _AFLIBAUDIOMEMORYINPUT_H_ 00025 00026 #include "aflibAudio.h" 00027 00028 00029 typedef long (*samples_callback)(aflibAudio *, void *, long, long, long long); 00030 00031 00065 class aflibAudioMemoryInput: public aflibAudio { 00066 00067 public: 00068 00069 // Available contructors and destructors 00070 aflibAudioMemoryInput(const aflibConfig& config); 00071 00072 ~aflibAudioMemoryInput(); 00073 00074 void 00075 setAudioMemoryInputCallback( samples_callback func_ptr); 00076 00077 aflibStatus 00078 compute_segment( 00079 list<aflibData *>& data, 00080 long long position = -1) ; 00081 00083 const char * 00084 getName() const { return "aflibAudioMemoryInput";}; 00085 00086 private: 00087 00088 aflibAudioMemoryInput(); 00089 aflibAudioMemoryInput(const aflibAudioMemoryInput& op); 00090 00091 const aflibAudioMemoryInput& 00092 operator=(const aflibAudioMemoryInput& op); 00093 00094 samples_callback _samples_func_ptr; 00095 00096 }; 00097 00098 #endif