Update ImageSharp to 2.1.2
このコミットが含まれているのは:
1 親
0c0b5e096f
コミット
f0ed5c46cf
14ファイル変更
+42
-25
検索条件に一致するファイルはありません
@@ -263,12 +263,12 @@ public sealed partial class HlslBokehBlurProcessor
|
||||
/// <inheritdoc/>
|
||||
protected override void OnFrameApply(ImageFrame<ImageSharpRgba32> source)
|
||||
{
|
||||
if (!source.TryGetSinglePixelSpan(out Span<ImageSharpRgba32> pixelSpan))
|
||||
if (!source.DangerousTryGetSinglePixelMemory(out Memory<ImageSharpRgba32> pixelMemory))
|
||||
{
|
||||
ThrowHelper.ThrowInvalidOperationException("Cannot process image frames wrapping discontiguous memory.");
|
||||
}
|
||||
|
||||
Span<Rgba32> span = MemoryMarshal.Cast<ImageSharpRgba32, Rgba32>(pixelSpan);
|
||||
Span<Rgba32> span = MemoryMarshal.Cast<ImageSharpRgba32, Rgba32>(pixelMemory.Span);
|
||||
|
||||
using ReadWriteTexture2D<Rgba32, float4> texture = GraphicsDevice.AllocateReadWriteTexture2D<Rgba32, float4>(span, source.Width, source.Height);
|
||||
using ReadWriteTexture2D<float4> temporary = GraphicsDevice.AllocateReadWriteTexture2D<float4>(source.Width, source.Height, AllocationMode.Clear);
|
||||
|
||||
@@ -93,12 +93,12 @@ public sealed partial class HlslGaussianBlurProcessor
|
||||
/// <inheritdoc/>
|
||||
protected override void OnFrameApply(ImageFrame<ImageSharpRgba32> source)
|
||||
{
|
||||
if (!source.TryGetSinglePixelSpan(out Span<ImageSharpRgba32> pixelSpan))
|
||||
if (!source.DangerousTryGetSinglePixelMemory(out Memory<ImageSharpRgba32> pixelMemory))
|
||||
{
|
||||
ThrowHelper.ThrowInvalidOperationException("Cannot process image frames wrapping discontiguous memory.");
|
||||
}
|
||||
|
||||
Span<Rgba32> span = MemoryMarshal.Cast<ImageSharpRgba32, Rgba32>(pixelSpan);
|
||||
Span<Rgba32> span = MemoryMarshal.Cast<ImageSharpRgba32, Rgba32>(pixelMemory.Span);
|
||||
|
||||
using ReadWriteTexture2D<Rgba32, float4> sourceTexture = GraphicsDevice.AllocateReadWriteTexture2D<Rgba32, float4>(span, source.Width, source.Height);
|
||||
using ReadWriteTexture2D<Rgba32, float4> firstPassTexture = GraphicsDevice.AllocateReadWriteTexture2D<Rgba32, float4>(source.Width, source.Height);
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする