[英]How to display GIF Image from URL in UWP using XAML?
我不知道什么對您不起作用,但是我很快做了一個演示項目,GIF很好顯示。
MainPage.xaml:
<Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}">
<Image Height="200" Width="200" Source="{x:Bind ImageSource, Mode=OneWay}"/>
</Grid>
MainPage.xaml.cs
public sealed partial class MainPage : Page
{
private string ImageSource { get; set; }
public MainPage()
{
this.InitializeComponent();
ImageSource = @"http://api.wunderground.com/api/9270a990901ad2ce/animatedradar/animatedsatellite/image.gif?num=5&delay=50&rad.maxlat=47.709&rad.maxlon=-69.263&rad.minlat=31.596&rad.minlon=-97.388&rad.width=640&rad.height=480&rad.rainsnow=1&rad.reproj.automerc=1&rad.num=5&sat.maxlat=47.709&sat.maxlon=-69.263&sat.minlat=31.596&sat.minlon=-97.388&sat.width=640&sat.height=480&sat.key=sat_ir4_bottom&sat.gtt=107&sat.proj=me&sat.timelabel=0&sat.num=5";
}
}
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.