dotnet / dotnet/wpf

[API Proposal] Adding CreateBitmapSourceFromWICBitmap method to System.Windows.Interop.Imaging

Open
#7,217 3 comments 0 reactions 0 assignees View on GitHub
:construction: work in progress API suggestion
Dominant language
C#
Stars
7.7k
Forks
1.3k
Avg merge
1d 11h
Merged PRs (30d)
61

Description

We should show the WICBitmap which created by the other logic, such as D2D in WPF. But I didn't find a low cost way to do it.

As we know, the WPF uses the WICBitmap to draw the image in GFX. And IWICBitmap can cross resource devices, and it means that this is another way to Interop with D2D.

## API

```csharp
namespace System.Windows.Interop
{
public static class Imaging
{
public static BitmapSource CreateBitmapSourceFromWICBitmap(IntPtr wicBitmap);
}
}
```

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.