arts Library API Documentation

kaudioplaystream_p.h

00001 /* This file is part of the KDE project 00002 Copyright (C) 2003 Arnold Krille <arnold@arnoldarts.de> 00003 00004 This library is free software; you can redistribute it and/or 00005 modify it under the terms of the GNU Library General Public 00006 License version 2 as published by the Free Software Foundation. 00007 00008 This library is distributed in the hope that it will be useful, 00009 but WITHOUT ANY WARRANTY; without even the implied warranty of 00010 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00011 Library General Public License for more details. 00012 00013 You should have received a copy of the GNU Library General Public License 00014 along with this library; see the file COPYING.LIB. If not, write to 00015 the Free Software Foundation, Inc., 59 Temple Place - Suite 330, 00016 Boston, MA 02111-1307, USA. 00017 00018 */ 00019 00020 #ifndef KAUDIOPLAYSTREAM_P_H 00021 #define KAUDIOPLAYSTREAM_P_H 00022 00023 #include <soundserver.h> 00024 #include <stdsynthmodule.h> 00025 00026 #include <qobject.h> 00027 00028 class KArtsServer; 00029 class KAudioManagerPlay; 00030 namespace Arts { 00031 class Synth_AMAN_PLAY; 00032 class StereoEffectStack; 00033 class ByteStreamToAudio; 00034 } 00035 00036 class KAudioPlayStream; 00037 class KByteSoundProducer; 00038 00039 class KAudioPlayStreamPrivate : public QObject { 00040 Q_OBJECT 00041 public: 00042 KAudioPlayStreamPrivate( KArtsServer*, const QString title, QObject*, const char* =0 ); 00043 ~KAudioPlayStreamPrivate(); 00044 00045 KArtsServer* _server; 00046 KAudioManagerPlay* _play; 00047 Arts::StereoEffectStack _effectrack; 00048 Arts::ByteStreamToAudio _bs2a; 00049 KByteSoundProducer* _sender; 00050 Arts::ByteSoundProducerV2 _artssender; 00051 bool _polling, _attached, _effects; 00052 00053 public slots: 00054 void initaRts(); 00055 }; 00056 00057 class KByteSoundProducer : virtual public Arts::ByteSoundProducerV2_skel 00058 , virtual public Arts::StdSynthModule 00059 { 00060 public: 00061 KByteSoundProducer( KAudioPlayStream*, float minBufferTime, int rate, int bits, int channels, const char * title ); 00062 ~KByteSoundProducer(); 00063 00064 long samplingRate() { return _samplingRate; } 00065 long channels() { return _channels; } 00066 long bits() { return _bits; } 00067 std::string title() { return _title; } 00068 00069 void streamStart(); 00070 void streamEnd(); 00071 00072 protected: 00073 void request_outdata( Arts::DataPacket<Arts::mcopbyte> *packet ); 00074 00075 private: 00076 long _samplingRate, _channels, _bits, _packets; 00077 std::string _title; 00078 enum { packetCapacity = 4096 }; 00079 KAudioPlayStream* _impl; 00080 }; 00081 00082 #endif // KAUDIOPLAYSTREAM_P_H 00083 00084 // vim: sw=4 ts=4
KDE Logo
This file is part of the documentation for arts Library Version 3.2.3.
Documentation copyright © 1996-2004 the KDE developers.
Generated on Sun Oct 10 18:55:37 2004 by doxygen 1.3.7 written by Dimitri van Heesch, © 1997-2003