gpt4 book ai didi

C# RenderTargetBitmap 到 SoftwareBitmap

转载 作者:太空宇宙 更新时间:2023-11-03 19:01:32 26 4
gpt4 key购买 nike

如何将 RenderTargetBitmap 对象放入 SoftwareBitmap 中?可以获取 RenderTargetBitmap 作为图像源,另一方面我可以使用 SoftwareBitmap 作为 SoftwareBitmapSource 并将其转换为 ImageSource。但是如何将 RenderTargetBitmap 直接转换为 SoftwareBitmap?

最佳答案

渲染目标位图。 GetPixelsAsync返回一个 IBuffer,您可以使用 SoftwareBitmap 将其复制到 SoftwareBitmap 中。 CreateCopyFromBuffer

关于C# RenderTargetBitmap 到 SoftwareBitmap,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/35043114/

26 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com