简体   繁体   English

WriteableBitmapEx-将两个图像合二为一

[英]WriteableBitmapEx - merge two images in one

I want to merge two images into one. 我想将两个图像合并为一个。 I read that I should use WriteableBitmapEx library and use blit method. 我读到我应该使用WriteableBitmapEx库并使用blit方法。 Both of my images are Image type. 我的两个图像都是图像类型。

So, should I first convert Image type to WriteableBitmap ? 那么,我应该首先将Image类型转换为WriteableBitmap吗? Like this: 像这样:

var im1 = image1.ToImage().ToBitmap(); 
var im2 = image2.ToImage().ToBitmap();

And how can I use method blit now ? 现在如何使用blit方法?

You have to use WriteableBitmapEx library to use the image merge functionality in your application WriteableBitmapEx Library has Blit Method. 您必须使用WriteableBitmapEx库才能在应用程序中使用图像合并功能。WriteableBitmapEx库具有Blit方法。

Here is an example for the same see the following link 这是相同的示例,请参见以下链接

Hope it helps 希望能帮助到你

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM