author | llornkcor <llornkcor> | 2003-04-21 23:58:24 (UTC) |
---|---|---|
committer | llornkcor <llornkcor> | 2003-04-21 23:58:24 (UTC) |
commit | 2d4cf8a85edc83b72855854b0bd337d2993df95b (patch) (unidiff) | |
tree | a4d1909771e181a984b00cc573669de0985ac179 | |
parent | e951446d52d2a89dd919b1665b034516567384ee (diff) | |
download | opie-2d4cf8a85edc83b72855854b0bd337d2993df95b.zip opie-2d4cf8a85edc83b72855854b0bd337d2993df95b.tar.gz opie-2d4cf8a85edc83b72855854b0bd337d2993df95b.tar.bz2 |
no defaults in constructors
-rw-r--r-- | noncore/multimedia/opierec/device.h | 2 | ||||
-rw-r--r-- | noncore/multimedia/opierec/helpwindow.h | 2 | ||||
-rw-r--r-- | noncore/multimedia/opierec/qtrec.h | 2 | ||||
-rw-r--r-- | noncore/multimedia/opierec/wavFile.h | 4 |
4 files changed, 5 insertions, 5 deletions
diff --git a/noncore/multimedia/opierec/device.h b/noncore/multimedia/opierec/device.h index c9a7491..2d4d2fc 100644 --- a/noncore/multimedia/opierec/device.h +++ b/noncore/multimedia/opierec/device.h | |||
@@ -1,45 +1,45 @@ | |||
1 | 1 | ||
2 | #ifndef DEVICE_H | 2 | #ifndef DEVICE_H |
3 | #define DEVICE_H | 3 | #define DEVICE_H |
4 | #include <qobject.h> | 4 | #include <qobject.h> |
5 | #include <sys/soundcard.h> | 5 | #include <sys/soundcard.h> |
6 | 6 | ||
7 | class Device : public QObject { | 7 | class Device : public QObject { |
8 | Q_OBJECT | 8 | Q_OBJECT |
9 | public: | 9 | public: |
10 | Device( QObject * parent=0, const char * dspStr=0, const char * mixerStr=0, bool record=false ); | 10 | Device( QObject * parent, const char * dspStr, const char * mixerStr, bool record ); |
11 | ~Device() {}; | 11 | ~Device() {}; |
12 | bool closeDevice( bool); | 12 | bool closeDevice( bool); |
13 | int getChannels(); | 13 | int getChannels(); |
14 | int getFormat(); | 14 | int getFormat(); |
15 | int getInVolume(); | 15 | int getInVolume(); |
16 | int getOutVolume(); | 16 | int getOutVolume(); |
17 | int getRate(); | 17 | int getRate(); |
18 | int getRes(); | 18 | int getRes(); |
19 | int sd; //sound descriptor | 19 | int sd; //sound descriptor |
20 | void changedInVolume(int); | 20 | void changedInVolume(int); |
21 | void changedOutVolume(int); | 21 | void changedOutVolume(int); |
22 | bool openDsp(); | 22 | bool openDsp(); |
23 | int getDeviceFormat(); | 23 | int getDeviceFormat(); |
24 | int getDeviceRate(); | 24 | int getDeviceRate(); |
25 | int getDeviceBits(); | 25 | int getDeviceBits(); |
26 | int getDeviceChannels(); | 26 | int getDeviceChannels(); |
27 | int getDeviceFragSize(); | 27 | int getDeviceFragSize(); |
28 | bool setFragSize(int); | 28 | bool setFragSize(int); |
29 | bool setDeviceChannels(int); | 29 | bool setDeviceChannels(int); |
30 | bool setDeviceRate(int); | 30 | bool setDeviceRate(int); |
31 | bool setDeviceFormat(int); | 31 | bool setDeviceFormat(int); |
32 | bool reset(); | 32 | bool reset(); |
33 | 33 | ||
34 | private: | 34 | private: |
35 | int devRes, devCh, devRate, devForm, flags; | 35 | int devRes, devCh, devRate, devForm, flags; |
36 | char *dspstr, *mixstr; | 36 | char *dspstr, *mixstr; |
37 | bool selectMicInput(); | 37 | bool selectMicInput(); |
38 | int openDevice( int ); | 38 | int openDevice( int ); |
39 | private slots: | 39 | private slots: |
40 | 40 | ||
41 | protected: | 41 | protected: |
42 | 42 | ||
43 | }; | 43 | }; |
44 | 44 | ||
45 | #endif | 45 | #endif |
diff --git a/noncore/multimedia/opierec/helpwindow.h b/noncore/multimedia/opierec/helpwindow.h index 76b672a..bd8fbdf 100644 --- a/noncore/multimedia/opierec/helpwindow.h +++ b/noncore/multimedia/opierec/helpwindow.h | |||
@@ -1,62 +1,62 @@ | |||
1 | /**************************************************************************** | 1 | /**************************************************************************** |
2 | ** $Id$ | 2 | ** $Id$ |
3 | ** | 3 | ** |
4 | ** Copyright (C) 1992-2000 Trolltech AS. All rights reserved. | 4 | ** Copyright (C) 1992-2000 Trolltech AS. All rights reserved. |
5 | ** | 5 | ** |
6 | ** This file is part of an example program for Qt. This example | 6 | ** This file is part of an example program for Qt. This example |
7 | ** program may be used, distributed and modified without limitation. | 7 | ** program may be used, distributed and modified without limitation. |
8 | ** | 8 | ** |
9 | *****************************************************************************/ | 9 | *****************************************************************************/ |
10 | 10 | ||
11 | #ifndef HELPWINDOW_H | 11 | #ifndef HELPWINDOW_H |
12 | #define HELPWINDOW_H | 12 | #define HELPWINDOW_H |
13 | 13 | ||
14 | #include <qmainwindow.h> | 14 | #include <qmainwindow.h> |
15 | #include <qtextbrowser.h> | 15 | #include <qtextbrowser.h> |
16 | #include <qstringlist.h> | 16 | #include <qstringlist.h> |
17 | #include <qmap.h> | 17 | #include <qmap.h> |
18 | #include <qdir.h> | 18 | #include <qdir.h> |
19 | #include <qevent.h> | 19 | #include <qevent.h> |
20 | 20 | ||
21 | class QComboBox; | 21 | class QComboBox; |
22 | class QPopupMenu; | 22 | class QPopupMenu; |
23 | 23 | ||
24 | class HelpWindow : public QMainWindow | 24 | class HelpWindow : public QMainWindow |
25 | { | 25 | { |
26 | Q_OBJECT | 26 | Q_OBJECT |
27 | public: | 27 | public: |
28 | HelpWindow( const QString& home_, const QString& path, QWidget* parent = 0, const char *name=0 ); | 28 | HelpWindow( const QString& home_, const QString& path, QWidget* parent, const char *name ); |
29 | ~HelpWindow(); | 29 | ~HelpWindow(); |
30 | 30 | ||
31 | private slots: | 31 | private slots: |
32 | 32 | ||
33 | void addBookmark(); | 33 | void addBookmark(); |
34 | void bookmChosen( int ); | 34 | void bookmChosen( int ); |
35 | void histChosen( int ); | 35 | void histChosen( int ); |
36 | void newWindow(); | 36 | void newWindow(); |
37 | void openFile(); | 37 | void openFile(); |
38 | void pathSelected( const QString & ); | 38 | void pathSelected( const QString & ); |
39 | void print(); | 39 | void print(); |
40 | void setBackwardAvailable( bool ); | 40 | void setBackwardAvailable( bool ); |
41 | void setForwardAvailable( bool ); | 41 | void setForwardAvailable( bool ); |
42 | void textChanged(); | 42 | void textChanged(); |
43 | private: | 43 | private: |
44 | QTextBrowser* browser; | 44 | QTextBrowser* browser; |
45 | QComboBox *pathCombo; | 45 | QComboBox *pathCombo; |
46 | int backwardId, forwardId; | 46 | int backwardId, forwardId; |
47 | QString selectedURL; | 47 | QString selectedURL; |
48 | QStringList history, bookmarks; | 48 | QStringList history, bookmarks; |
49 | QMap<int, QString> mHistory, mBookmarks; | 49 | QMap<int, QString> mHistory, mBookmarks; |
50 | QPopupMenu *hist, *bookm; | 50 | QPopupMenu *hist, *bookm; |
51 | 51 | ||
52 | void readHistory(); | 52 | void readHistory(); |
53 | void readBookmarks(); | 53 | void readBookmarks(); |
54 | 54 | ||
55 | }; | 55 | }; |
56 | 56 | ||
57 | 57 | ||
58 | 58 | ||
59 | 59 | ||
60 | 60 | ||
61 | #endif | 61 | #endif |
62 | 62 | ||
diff --git a/noncore/multimedia/opierec/qtrec.h b/noncore/multimedia/opierec/qtrec.h index d0623d0..1a51151 100644 --- a/noncore/multimedia/opierec/qtrec.h +++ b/noncore/multimedia/opierec/qtrec.h | |||
@@ -11,97 +11,97 @@ copyright 2002 by L.J. Potter ljp@llornkcor.com | |||
11 | #include <iostream.h> | 11 | #include <iostream.h> |
12 | #include <qfile.h> | 12 | #include <qfile.h> |
13 | #include <qimage.h> | 13 | #include <qimage.h> |
14 | #include <qlineedit.h> | 14 | #include <qlineedit.h> |
15 | #include <qpixmap.h> | 15 | #include <qpixmap.h> |
16 | #include <qvariant.h> | 16 | #include <qvariant.h> |
17 | #include <qwidget.h> | 17 | #include <qwidget.h> |
18 | #include <stdio.h> | 18 | #include <stdio.h> |
19 | #include <stdlib.h> | 19 | #include <stdlib.h> |
20 | 20 | ||
21 | #include "device.h" | 21 | #include "device.h" |
22 | #include "wavFile.h" | 22 | #include "wavFile.h" |
23 | 23 | ||
24 | class QButtonGroup; | 24 | class QButtonGroup; |
25 | class QCheckBox; | 25 | class QCheckBox; |
26 | class QComboBox; | 26 | class QComboBox; |
27 | class QGridLayout; | 27 | class QGridLayout; |
28 | class QGroupBox; | 28 | class QGroupBox; |
29 | class QHBoxLayout; | 29 | class QHBoxLayout; |
30 | class QIconView; | 30 | class QIconView; |
31 | class QIconViewItem; | 31 | class QIconViewItem; |
32 | class QLabel; | 32 | class QLabel; |
33 | class QLabel; | 33 | class QLabel; |
34 | class QListView; | 34 | class QListView; |
35 | class QListViewItem; | 35 | class QListViewItem; |
36 | class QPushButton; | 36 | class QPushButton; |
37 | class QSlider; | 37 | class QSlider; |
38 | class QTabWidget; | 38 | class QTabWidget; |
39 | class QTimer; | 39 | class QTimer; |
40 | class QVBoxLayout; | 40 | class QVBoxLayout; |
41 | class QLineEdit; | 41 | class QLineEdit; |
42 | 42 | ||
43 | #define MAX_TRACKS 2 | 43 | #define MAX_TRACKS 2 |
44 | //#define BUFSIZE 4096 | 44 | //#define BUFSIZE 4096 |
45 | // #define BUFSIZE 8182 //Z default buffer size | 45 | // #define BUFSIZE 8182 //Z default buffer size |
46 | #define BUFSIZE 1024 | 46 | #define BUFSIZE 1024 |
47 | //#define BUFSIZE 2048 | 47 | //#define BUFSIZE 2048 |
48 | #define FRAGSIZE 0x7fff000A; | 48 | #define FRAGSIZE 0x7fff000A; |
49 | 49 | ||
50 | #define WAVE_FORMAT_DVI_ADPCM (0x0011) | 50 | #define WAVE_FORMAT_DVI_ADPCM (0x0011) |
51 | #define WAVE_FORMAT_PCM (0x0001) | 51 | #define WAVE_FORMAT_PCM (0x0001) |
52 | //AFMT_IMA_ADPCM | 52 | //AFMT_IMA_ADPCM |
53 | 53 | ||
54 | class QtRec : public QWidget | 54 | class QtRec : public QWidget |
55 | { | 55 | { |
56 | Q_OBJECT | 56 | Q_OBJECT |
57 | 57 | ||
58 | public: | 58 | public: |
59 | QtRec( QWidget* parent = 0, const char* name = 0, WFlags fl = 0 ); | 59 | QtRec( QWidget* parent, const char* name, WFlags fl ); |
60 | ~QtRec(); | 60 | ~QtRec(); |
61 | QSlider *OutputSlider,*InputSlider; | 61 | QSlider *OutputSlider,*InputSlider; |
62 | 62 | ||
63 | public slots: | 63 | public slots: |
64 | private: | 64 | private: |
65 | // int fragment; | 65 | // int fragment; |
66 | int fd1; | 66 | int fd1; |
67 | int secCount; | 67 | int secCount; |
68 | QString timeString; | 68 | QString timeString; |
69 | 69 | ||
70 | QLineEdit *renameBox; | 70 | QLineEdit *renameBox; |
71 | QGroupBox* GroupBox1; | 71 | QGroupBox* GroupBox1; |
72 | QString currentFile; | 72 | QString currentFile; |
73 | QString date, currentFileName, tmpFileName; | 73 | QString date, currentFileName, tmpFileName; |
74 | QTimer *t_timer; | 74 | QTimer *t_timer; |
75 | bool needsStereoOut, paused, playing; | 75 | bool needsStereoOut, paused, playing; |
76 | bool useTmpFile, autoMute; | 76 | bool useTmpFile, autoMute; |
77 | 77 | ||
78 | bool eventFilter( QObject * , QEvent * ); | 78 | bool eventFilter( QObject * , QEvent * ); |
79 | void okRename(); | 79 | void okRename(); |
80 | void cancelRename(); | 80 | void cancelRename(); |
81 | QString getStorage(const QString &); | 81 | QString getStorage(const QString &); |
82 | bool rec(); | 82 | bool rec(); |
83 | int getCurrentSizeLimit(); | 83 | int getCurrentSizeLimit(); |
84 | long checkDiskSpace(const QString &); | 84 | long checkDiskSpace(const QString &); |
85 | void doMute(bool); | 85 | void doMute(bool); |
86 | void errorStop(); | 86 | void errorStop(); |
87 | void fillDirectoryCombo(); | 87 | void fillDirectoryCombo(); |
88 | void getInVol(); | 88 | void getInVol(); |
89 | void getOutVol(); | 89 | void getOutVol(); |
90 | void init(); | 90 | void init(); |
91 | void initConfig(); | 91 | void initConfig(); |
92 | void initConnections(); | 92 | void initConnections(); |
93 | void selectItemByName(const QString &); | 93 | void selectItemByName(const QString &); |
94 | void setRecordButton(bool); | 94 | void setRecordButton(bool); |
95 | void start(); | 95 | void start(); |
96 | void stop(); | 96 | void stop(); |
97 | void timerEvent( QTimerEvent *e ); | 97 | void timerEvent( QTimerEvent *e ); |
98 | 98 | ||
99 | private slots: | 99 | private slots: |
100 | 100 | ||
101 | 101 | ||
102 | void FastforwardPressed(); | 102 | void FastforwardPressed(); |
103 | void FastforwardReleased(); | 103 | void FastforwardReleased(); |
104 | void changeDirCombo(int); | 104 | void changeDirCombo(int); |
105 | void changeSizeLimitCombo(int); | 105 | void changeSizeLimitCombo(int); |
106 | void changeTimeSlider(int); | 106 | void changeTimeSlider(int); |
107 | void changebitrateCombo(int); | 107 | void changebitrateCombo(int); |
diff --git a/noncore/multimedia/opierec/wavFile.h b/noncore/multimedia/opierec/wavFile.h index 51366ec..53740e0 100644 --- a/noncore/multimedia/opierec/wavFile.h +++ b/noncore/multimedia/opierec/wavFile.h | |||
@@ -1,56 +1,56 @@ | |||
1 | //wavFile.h | 1 | //wavFile.h |
2 | #ifndef WAVFILE_H | 2 | #ifndef WAVFILE_H |
3 | #define WAVFILE_H | 3 | #define WAVFILE_H |
4 | 4 | ||
5 | #include <qobject.h> | 5 | #include <qobject.h> |
6 | #include <sys/soundcard.h> | 6 | #include <sys/soundcard.h> |
7 | #include <qfile.h> | 7 | #include <qfile.h> |
8 | #include <qstring.h> | 8 | #include <qstring.h> |
9 | 9 | ||
10 | typedef struct { | 10 | typedef struct { |
11 | char riffID[4]; | 11 | char riffID[4]; |
12 | unsigned long riffLen; | 12 | unsigned long riffLen; |
13 | char wavID[4]; | 13 | char wavID[4]; |
14 | char fmtID[4]; | 14 | char fmtID[4]; |
15 | unsigned long fmtLen; | 15 | unsigned long fmtLen; |
16 | unsigned short fmtTag; | 16 | unsigned short fmtTag; |
17 | unsigned short nChannels; | 17 | unsigned short nChannels; |
18 | unsigned long sampleRate; | 18 | unsigned long sampleRate; |
19 | unsigned long avgBytesPerSec; | 19 | unsigned long avgBytesPerSec; |
20 | unsigned short nBlockAlign; | 20 | unsigned short nBlockAlign; |
21 | unsigned short bitsPerSample; | 21 | unsigned short bitsPerSample; |
22 | char dataID[4]; | 22 | char dataID[4]; |
23 | unsigned long dataLen; | 23 | unsigned long dataLen; |
24 | } wavhdr; | 24 | } wavhdr; |
25 | 25 | ||
26 | 26 | ||
27 | class WavFile : public QObject { | 27 | class WavFile : public QObject { |
28 | Q_OBJECT | 28 | Q_OBJECT |
29 | public: | 29 | public: |
30 | WavFile( QObject * parent=0,const QString &fileName=0, bool newFile=true, int sampleRate = 0, | 30 | WavFile( QObject * parent,const QString &fileName, bool newFile, int sampleRate, |
31 | int channels = 0, int resolution = 0, int format=0); | 31 | int channels , int resolution, int format); |
32 | ~WavFile(); | 32 | ~WavFile(); |
33 | wavhdr hdr; | 33 | wavhdr hdr; |
34 | bool adjustHeaders(int fd, int total); | 34 | bool adjustHeaders(int fd, int total); |
35 | QString currentFileName; | 35 | QString currentFileName; |
36 | QString trackName(); | 36 | QString trackName(); |
37 | 37 | ||
38 | QFile track; | 38 | QFile track; |
39 | int wavHandle(); | 39 | int wavHandle(); |
40 | int getFormat(); | 40 | int getFormat(); |
41 | int getResolution(); | 41 | int getResolution(); |
42 | int getSampleRate(); | 42 | int getSampleRate(); |
43 | int getNumberSamples(); | 43 | int getNumberSamples(); |
44 | bool isTempFile(); | 44 | bool isTempFile(); |
45 | int openFile(const QString &); | 45 | int openFile(const QString &); |
46 | bool newFile(); | 46 | bool newFile(); |
47 | void closeFile(); | 47 | void closeFile(); |
48 | 48 | ||
49 | private: | 49 | private: |
50 | int wavFormat, wavChannels, wavResolution, wavSampleRate, wavNumberSamples; | 50 | int wavFormat, wavChannels, wavResolution, wavSampleRate, wavNumberSamples; |
51 | bool useTmpFile; | 51 | bool useTmpFile; |
52 | bool setWavHeader(int fd, wavhdr *hdr); | 52 | bool setWavHeader(int fd, wavhdr *hdr); |
53 | int parseWavHeader(int fd); | 53 | int parseWavHeader(int fd); |
54 | }; | 54 | }; |
55 | 55 | ||
56 | #endif | 56 | #endif |