00001 /* 00002 Copyright (C) 2005-2006 Remon Sijrier 00003 00004 This file is part of Traverso 00005 00006 Traverso 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 2 of the License, or 00009 (at your option) any later version. 00010 00011 This program 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, write to the Free Software 00018 Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. 00019 00020 $Id: AudioDeviceThread.h,v 1.4 2007/03/16 00:10:26 r_sijrier Exp $ 00021 */ 00022 00023 #ifndef AUDIODEVICETHREAD_H 00024 #define AUDIODEVICETHREAD_H 00025 00026 #include <QThread> 00027 00028 class AudioDevice; 00029 00030 class AudioDeviceThread : public QThread 00031 { 00032 00033 public: 00034 AudioDeviceThread(AudioDevice* device); 00035 int become_realtime(bool realtime); 00036 00037 void run_on_cpu(int cpu); 00038 00039 void mili_sleep(int msec) {msleep(msec);} 00040 00041 volatile size_t watchdogCheck; 00042 00043 protected: 00044 void run(); 00045 00046 private: 00047 AudioDevice* m_device; 00048 bool m_realTime; 00049 }; 00050 00051 #endif 00052 00053 //eof
1.5.5