mirror of
https://github.com/juce-framework/JUCE.git
synced 2026-01-17 00:44:19 +00:00
Fixed an alignment issue when writing WAV files with tracktion loop info blocks.
This commit is contained in:
parent
7e51e64422
commit
ba0c4bd823
1 changed files with 7 additions and 5 deletions
|
|
@ -609,16 +609,18 @@ namespace WavFileHelpers
|
|||
{
|
||||
static MemoryBlock createFrom (const StringPairArray& values)
|
||||
{
|
||||
const String s = values[WavAudioFormat::tracktionLoopInfo];
|
||||
MemoryBlock data;
|
||||
MemoryOutputStream out;
|
||||
const String s (values[WavAudioFormat::tracktionLoopInfo]);
|
||||
|
||||
if (s.isNotEmpty())
|
||||
{
|
||||
MemoryOutputStream os (data, false);
|
||||
os.writeString (s);
|
||||
out.writeString (s);
|
||||
|
||||
if ((out.getDataSize() & 1) != 0)
|
||||
out.writeByte (0);
|
||||
}
|
||||
|
||||
return data;
|
||||
return out.getMemoryBlock();
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue