openbsd-ports/audio/audacity/patches/patch-tests_SimpleBlockFileTest_cpp
ajacoutot 7a9dcfa8fc - update to version 1.3.2
big thanks to Martynas Venckus for his work on regression tests

"go ahead!" jasper@
2006-12-17 12:12:58 +00:00

43 lines
2.2 KiB
Plaintext

$OpenBSD: patch-tests_SimpleBlockFileTest_cpp,v 1.3 2006/12/17 12:12:59 ajacoutot Exp $
--- tests/SimpleBlockFileTest.cpp.orig Sun Oct 29 01:05:36 2006
+++ tests/SimpleBlockFileTest.cpp Wed Dec 6 14:11:41 2006
@@ -45,13 +45,13 @@ public:
floatData[i] = sign*j/((j*j)+1);
}
- int16BlockFile = new SimpleBlockFile(wxFileName("/tmp/int16"),
+ int16BlockFile = new SimpleBlockFile(wxFileName(_T("/tmp/int16")),
(samplePtr)int16Data, dataLen,
int16Sample);
- int24BlockFile = new SimpleBlockFile(wxFileName("/tmp/int24"),
+ int24BlockFile = new SimpleBlockFile(wxFileName(_T("/tmp/int24")),
(samplePtr)int24Data, dataLen,
int24Sample);
- floatBlockFile = new SimpleBlockFile(wxFileName("/tmp/float"),
+ floatBlockFile = new SimpleBlockFile(wxFileName(_T("/tmp/float")),
(samplePtr)floatData, dataLen,
floatSample);
@@ -82,7 +82,7 @@ public:
SF_INFO info;
memset(&info, 0, sizeof(info));
- SNDFILE *sf = sf_open(bf->GetFileName().GetFullPath(), SFM_READ, &info);
+ SNDFILE *sf = sf_open(bf->GetFileName().GetFullPath().mb_str(), SFM_READ, &info);
assert(sf);
assert(info.frames == dataLen);
@@ -115,9 +115,9 @@ public:
memset(&info2, 0, sizeof(info2));
memset(&info3, 0, sizeof(info3));
- SNDFILE *int16sf = sf_open(int16BlockFile->GetFileName().GetFullPath(), SFM_READ, &info1);
- SNDFILE *int24sf = sf_open(int24BlockFile->GetFileName().GetFullPath(), SFM_READ, &info2);
- SNDFILE *floatsf = sf_open(floatBlockFile->GetFileName().GetFullPath(), SFM_READ, &info3);
+ SNDFILE *int16sf = sf_open(int16BlockFile->GetFileName().GetFullPath().mb_str(), SFM_READ, &info1);
+ SNDFILE *int24sf = sf_open(int24BlockFile->GetFileName().GetFullPath().mb_str(), SFM_READ, &info2);
+ SNDFILE *floatsf = sf_open(floatBlockFile->GetFileName().GetFullPath().mb_str(), SFM_READ, &info3);
// First do a read of the entire block
short int16buf[dataLen];