• R/O
  • HTTP
  • SSH
  • HTTPS

CsWin10Desktop3: Commit

Visual C# 7.0, Windows10 Desktop App


Commit MetaInfo

Revisione67f134b736e934992315870629f515c497b35af (tree)
Time2017-10-15 20:53:04
Authorくまかみ工房 <kumakamikoubou@gmai...>
Commiterくまかみ工房

Log Message

Array.Copy() を Buffer.BlockCopy() に変更。

BlockCopy のほうが速いと聞いたので。

Change Summary

Incremental Difference

--- a/FDK/メディア/サウンド/WASAPI/MediaFoundationWaveSource.cs
+++ b/FDK/メディア/サウンド/WASAPI/MediaFoundationWaveSource.cs
@@ -160,12 +160,12 @@ namespace FDK.メディア.サウンド.WASAPI
160160
161161 if( 0 < count )
162162 {
163- Array.Copy(
164- sourceArray: this._EncodedWaveData,
165- sourceIndex: this._Position,
166- destinationArray: buffer,
167- destinationIndex: offset,
168- length: count );
163+ Buffer.BlockCopy(
164+ src: this._EncodedWaveData,
165+ srcOffset: (int) this._Position,
166+ dst: buffer,
167+ dstOffset: offset,
168+ count: count );
169169
170170 this._Position += count;
171171 }
--- a/FDK/メディア/サウンド/WASAPI/NVorbisResampledWaveSource.cs
+++ b/FDK/メディア/サウンド/WASAPI/NVorbisResampledWaveSource.cs
@@ -87,12 +87,12 @@ namespace FDK.メディア.サウンド.WASAPI
8787
8888 if( 0 < count )
8989 {
90- Array.Copy(
91- sourceArray: this._EncodedWaveData,
92- sourceIndex: this._Position,
93- destinationArray: buffer,
94- destinationIndex: offset,
95- length: count );
90+ Buffer.BlockCopy(
91+ src: this._EncodedWaveData,
92+ srcOffset: (int) this._Position,
93+ dst: buffer,
94+ dstOffset: offset,
95+ count: count );
9696
9797 this._Position += count;
9898 }
Show on old repository browser