[squeak-dev] The Trunk: Sound-eem.91.mcz
Stéphane Rollandin
lecteur at zogotounga.net
Sun Aug 14 08:20:40 UTC 2022
> + ifTrue: "optimization for files: write sound buffer directly to file"
> + [aBinaryStream next: (out size // 2 min: remaining) putAll: out startingAt: 1] "size in words"
> + ifFalse: "for non-file streams:"
> + [1 to: (out monoSampleCount min: remaining) do: [:i | aBinaryStream int16: (out at: i)]].
Seems a good catch to me - but it currently makes the
SoundTest>>#testStoreSamples fails, so #storeWAVSamplesOn: should
probably be changed too.
BTW in muO I did change #storeWAVSamplesOn: because it ignored the
channel count:
- nextLittleEndianNumber: 2 put: 4; "alignment"
+ nextLittleEndianNumber: 2 put: 2 * channelCount; "alignment"
Stef
More information about the Squeak-dev
mailing list
|