Főoldal | Osztályhierarchia | Osztálylista | Fájllista | Osztálytagok | Fájlelemek | Kapcsolódó lapok

common.hh

Ugrás a fájl dokumentációjához.
00001 /*
00002  * SubTimer header file
00003  *  Copyright (C) 2005 Peter Salvi
00004  *   Last modification: <2005.03.23., 16:15:46>
00005  *
00006  *  This program 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., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
00019  */
00020 
00021 #ifndef COMMON_HH
00022 #define COMMON_HH
00023 
00026 #include <alsa/asoundlib.h>
00027 
00028 #include <qdatetime.h>
00029 
00044 inline int MSECS(QTime const t)
00045 {
00046   return QTime(0, 0).msecsTo(t);
00047 }
00048 
00063 inline int SECS(QTime const t)
00064 {
00065   return QTime(0, 0).secsTo(t);
00066 }
00067 
00082 inline QTime QTIME_MS(int const i)
00083 {
00084   return QTime(0, 0).addMSecs(i);
00085 }
00086 
00101 inline QTime QTIME_S(int const i)
00102 {
00103   return QTime(0, 0).addSecs(i);
00104 }
00105 
00118 struct WaveFormat
00119 {
00129   int channels;           
00130 
00140   unsigned int rate;      
00141 
00155   _snd_pcm_format format; 
00156 
00170   _snd_pcm_access access; 
00171 };
00172 
00173 #endif // COMMON_HH

Projekt: SubTimer Készült: Wed Mar 23 22:06:52 2005 Készítette: doxygen 1.3.6