[UWP] [XAML] [C#]错误报告:BimapImage在桌面和移动设备上有不同的行为。 [英] [UWP][XAML][C#]Bug Report:BimapImage have different behavior betwwen Desktop and Mobile.

查看:66
本文介绍了[UWP] [XAML] [C#]错误报告:BimapImage在桌面和移动设备上有不同的行为。的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个示例应用。 xaml如下:

I create a sample app. The xaml as following:

    <Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}" Height="500">
        <Grid.ColumnDefinitions>
            <ColumnDefinition/>
            <ColumnDefinition/>
        </Grid.ColumnDefinitions>
        <Image>
            <Image.Source>
                <BitmapImage DecodePixelWidth="336" DecodePixelType="Logical" UriSource="image_1280.png"/>
            </Image.Source>
        </Image>
        <Image Grid.Column="1">
            <Image.Source>
                <BitmapImage DecodePixelWidth="336" DecodePixelType="Physical" UriSource="image_1280.png"/>
            </Image.Source>
        </Image>
    </Grid>

两个BitmapImage具有相同的DecodePixelWidth和UriSource,唯一不同的是DecodePixelType。在本地计算机上启动应用程序时,这两个图像是相同的。

The two BitmapImage have same DecodePixelWidth and UriSource, the only different is DecodePixelType. When launch the app on local machine,  the two images is the same.







但是如果在模拟器或ARM设备上启动应用程序,则两个图像显示不同。

But if launch the app on emulator or ARM device, the two images shows different.

如您所见,左图仅显示图像的一部分。

As you can see, the left image only show a part of image.

这是示例应用程序

推荐答案

是的,这是一个错误。

 我可以在我的UWP app。
Yes, it is a bug.
 I can meet it on my UWP app.


这篇关于[UWP] [XAML] [C#]错误报告:BimapImage在桌面和移动设备上有不同的行为。的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆