diff options
author | Nick Hadaway <raker@gentoo.org> | 2003-01-15 19:02:57 +0000 |
---|---|---|
committer | Nick Hadaway <raker@gentoo.org> | 2003-01-15 19:02:57 +0000 |
commit | 2a2e1beac3a7cb5ee5d5a1ef46a87add41d903cd (patch) | |
tree | c525cb58ca1648cadc7614607e24294604b9b71a /media-sound/audacity/files | |
parent | fixed digest (diff) | |
download | gentoo-2-2a2e1beac3a7cb5ee5d5a1ef46a87add41d903cd.tar.gz gentoo-2-2a2e1beac3a7cb5ee5d5a1ef46a87add41d903cd.tar.bz2 gentoo-2-2a2e1beac3a7cb5ee5d5a1ef46a87add41d903cd.zip |
Version bump. Now depends on wxGTK-2.4.0
Diffstat (limited to 'media-sound/audacity/files')
-rw-r--r-- | media-sound/audacity/files/digest-audacity-1.1.1 | 1 | ||||
-rw-r--r-- | media-sound/audacity/files/mono_mp3_export.patch | 150 |
2 files changed, 151 insertions, 0 deletions
diff --git a/media-sound/audacity/files/digest-audacity-1.1.1 b/media-sound/audacity/files/digest-audacity-1.1.1 new file mode 100644 index 000000000000..e2f6eff266dd --- /dev/null +++ b/media-sound/audacity/files/digest-audacity-1.1.1 @@ -0,0 +1 @@ +MD5 70ffc1f9b076bccd4892148a87a24502 audacity-src-1.1.1.tgz 2310533 diff --git a/media-sound/audacity/files/mono_mp3_export.patch b/media-sound/audacity/files/mono_mp3_export.patch new file mode 100644 index 000000000000..18bed1aeeb09 --- /dev/null +++ b/media-sound/audacity/files/mono_mp3_export.patch @@ -0,0 +1,150 @@ +diff -ru audacity-src-1.1.1-3/src/export/ExportMP3.cpp /var/tmp/portage/audacity-1.1.1/work/audacity-src-1.1.1-3/src/export/ExportMP3.cpp +--- audacity-src-1.1.1-3/src/export/ExportMP3.cpp 2002-11-11 00:58:21.000000000 -0600 ++++ /var/tmp/portage/audacity-1.1.1/work/audacity-src-1.1.1-3/src/export/ExportMP3.cpp 2003-01-15 00:30:29.000000000 -0600 +@@ -190,6 +190,7 @@ + /* function pointers to the symbols we get from the library */ + lame_init_t* lame_init; + lame_init_params_t* lame_init_params; ++ lame_encode_buffer_t* lame_encode_buffer; + lame_encode_buffer_interleaved_t* lame_encode_buffer_interleaved; + lame_encode_flush_t* lame_encode_flush; + lame_close_t* lame_close; +@@ -259,6 +260,10 @@ + "get_lame_version"); + lame_init_params = + (lame_init_params_t *) wxDllLoader::GetSymbol(libHandle, "lame_init_params"); ++ ++ lame_encode_buffer = ++ (lame_encode_buffer_t *) wxDllLoader::GetSymbol(libHandle, ++ "lame_encode_buffer"); + lame_encode_buffer_interleaved = + (lame_encode_buffer_interleaved_t *) wxDllLoader::GetSymbol(libHandle, + "lame_encode_buffer_interleaved"); +@@ -294,6 +299,7 @@ + if (!lame_init || + !get_lame_version || + !lame_init_params || ++ !lame_encode_buffer || + !lame_encode_buffer_interleaved || + !lame_encode_flush || + !lame_close || +@@ -346,6 +352,22 @@ + mOutBufferSize); + } + ++ ++ ++ int EncodeBufferMono(short int inbuffer[], unsigned char outbuffer[]) { ++ if(!mEncoding) return -1; ++ ++ return lame_encode_buffer(mGF, inbuffer,inbuffer, mSamplesPerChunk, ++ outbuffer, mOutBufferSize); ++ } ++ ++ int EncodeRemainderMono(short int inbuffer[], int nSamples, ++ unsigned char outbuffer[]) { ++ return lame_encode_buffer(mGF, inbuffer, inbuffer, nSamples, outbuffer, ++ mOutBufferSize); ++ } ++ ++ + int FinishStream(unsigned char outbuffer[]) { + mEncoding = false; + int result = lame_encode_flush(mGF, outbuffer, mOutBufferSize); +@@ -425,6 +447,7 @@ + /* function pointers to the symbols we get from the library */ + lame_init_t* lame_init; + lame_init_params_t* lame_init_params; ++ lame_encode_buffer_t* lame_encode_buffer; + lame_encode_buffer_interleaved_t* lame_encode_buffer_interleaved; + lame_encode_flush_t* lame_encode_flush; + lame_close_t* lame_close; +@@ -556,6 +579,10 @@ + FindSymbol(connID, name, &mainAddr, &symClass); + lame_encode_buffer_interleaved = NewMachOFromCFM(mainAddr); + ++ MakePString(name, "lame_encode_buffer"); ++ FindSymbol(connID, name, &mainAddr, &symClass); ++ lame_encode_buffer = NewMachOFromCFM(mainAddr); ++ + MakePString(name, "lame_encode_flush"); + FindSymbol(connID, name, &mainAddr, &symClass); + lame_encode_flush = NewMachOFromCFM(mainAddr); +@@ -594,6 +621,7 @@ + if (!lame_init || + !get_lame_version || + !lame_init_params || ++ !lame_encode_buffer || + !lame_encode_buffer_interleaved || + !lame_encode_flush || + !lame_close || +@@ -636,7 +664,7 @@ + int EncodeBuffer(short int inbuffer[], unsigned char outbuffer[]) { + if(!mEncoding) return -1; + +- return lame_encode_buffer_interleaved(mGF, inbuffer, mSamplesPerChunk, ++ return lame_encode_buffer_interleaved(mGF, inbuffer, inbuffer, mSamplesPerChunk, + outbuffer, mOutBufferSize); + } + +@@ -646,6 +674,19 @@ + mOutBufferSize); + } + ++ int EncodeBufferMono(short int inbuffer[], unsigned char outbuffer[]) { ++ if(!mEncoding) return -1; ++ ++ return lame_encode_buffer(mGF, inbuffer, inbuffer, mSamplesPerChunk, ++ outbuffer, mOutBufferSize); ++ } ++ ++ int EncodeRemainderMono(short int inbuffer[], int nSamples, ++ unsigned char outbuffer[]) { ++ return lame_encode_buffer(mGF, inbuffer, inbuffer , inbuffer, nSamples, outbuffer, ++ mOutBufferSize); ++ } ++ + int FinishStream(unsigned char outbuffer[]) { + mEncoding = false; + int result = lame_encode_flush(mGF, outbuffer, mOutBufferSize); +@@ -1285,9 +1326,22 @@ + short *mixed = (short *)mixer->GetBuffer(); + + if(lastFrame) +- bytes = GetMP3Exporter()->EncodeRemainder(mixed, numSamples, buffer); +- else +- bytes = GetMP3Exporter()->EncodeBuffer(mixed, buffer); ++ ++ if (stereo) { ++ bytes = GetMP3Exporter()->EncodeRemainder(mixed, numSamples , buffer); ++ } ++ else{ ++ bytes = GetMP3Exporter()->EncodeRemainderMono(mixed, numSamples , buffer); ++ } ++ else { ++ ++ if (stereo) { ++ bytes = GetMP3Exporter()->EncodeBuffer(mixed, buffer); ++ } ++ else { ++ bytes = GetMP3Exporter()->EncodeBufferMono(mixed, buffer); ++ } ++ } + + outFile.Write(buffer, bytes); + +diff -ru audacity-src-1.1.1-3/src/export/ExportMP3.h /var/tmp/portage/audacity-1.1.1/work/audacity-src-1.1.1-3/src/export/ExportMP3.h +--- audacity-src-1.1.1-3/src/export/ExportMP3.h 2002-11-11 00:58:21.000000000 -0600 ++++ /var/tmp/portage/audacity-1.1.1/work/audacity-src-1.1.1-3/src/export/ExportMP3.h 2003-01-15 00:30:29.000000000 -0600 +@@ -38,6 +38,11 @@ + virtual int EncodeBuffer(short int inbuffer[], unsigned char outbuffer[]) = 0; + virtual int EncodeRemainder(short int inbuffer[], int nSamples, + unsigned char outbuffer[]) = 0; ++ ++ virtual int EncodeBufferMono(short int inbuffer[], unsigned char outbuffer[]) = 0; ++ virtual int EncodeRemainderMono(short int inbuffer[], int nSamples, ++ unsigned char outbuffer[]) = 0; ++ + virtual int FinishStream(unsigned char outbuffer[]) = 0; + virtual void CancelEncoding() = 0; + |