summaryrefslogtreecommitdiff
Side-by-side diff
Diffstat (more/less context) (ignore whitespace changes)
-rw-r--r--core/applets/vmemo/vmemo.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/applets/vmemo/vmemo.cpp b/core/applets/vmemo/vmemo.cpp
index 006e0ba..aa23ba7 100644
--- a/core/applets/vmemo/vmemo.cpp
+++ b/core/applets/vmemo/vmemo.cpp
@@ -354,50 +354,50 @@ int VMemo::openWAV(const char *filename)
void VMemo::record(void)
{
int length=0, result, value; //, i;
char sound[512]; //, leftBuffer[256], rightBuffer[256];
qWarning("VMemo::record()");
while(recording)
{
result = read(dsp, sound, 512); // 8192
qApp->processEvents();
/* attempt to write only one channel...didnt work.
for (i = 0; i < result; i++) {
leftBuffer[i] = sound[2*i];
rightBuffer[i] = sound[2*i+1];
}
*/
qApp->processEvents();
/* needed to only write one channel. comment out above "write/length" code.
write(wav, leftBuffer, result / 2);
length += result/2;
*/
write(wav, sound, result);
length += result;
qApp->processEvents();
}
qWarning("VMemo::record() -> Done recording");
qWarning("VMemo::record() -> Closing dsp");
value = length+36;
lseek(wav, 4, SEEK_SET);
write(wav, &value, 4);
lseek(wav, 40, SEEK_SET);
write(wav, &length, 4);
track.close();
if( ioctl( dsp, SNDCTL_DSP_RESET,0) == -1)
perror("ioctl(\"SNDCTL_DSP_RESET\")");
::close(dsp);
qWarning("VMemo::record() -> playing done recording sound");
QSound::play(Resource::findSound("vmemoe"));
qWarning("VMemo::record() -> terminating");
- QMessageBox::information(0, "VMemo", "Recording Done", 1);
+ //QMessageBox::information(0, "VMemo", "Recording Done", 1);
}