XamlAnimatedGif/WpfAnimatedGif
소개
WPF에서 애니메이션 GIF 이미지를 표시하는 간단한 라이브러리로, XAML이나 코드에서 사용할 수 있습니다.
디자인 및 미디어What you can do
- Animates GIF images in a normal Image control; no need to use a specific control
- Takes actual frame duration into account
- Repeat behavior can be specified; if unspecified, the repeat count from the GIF metadata is used
- Notification when the animation completes, in case you need to do something after the animation
측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- 0
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
README.md
OriginalWPF Animated GIF
Nuget package available here: WpfAnimatedGif.
A simple library to display animated GIF images in WPF, usable in XAML or in code.
It's very easy to use: in XAML, instead of setting the Source property, set the AnimatedSource attached property to the image you want:
<Window x:Class="WpfAnimatedGif.Demo.MainWindow"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
xmlns:gif="http://wpfanimatedgif.codeplex.com"
Title="MainWindow" Height="350" Width="525">
<Grid>
<Image gif:ImageBehavior.AnimatedSource="Images/animated.gif" />
You can also specify the repeat behavior (the default is 0x, which means it will use the repeat count from the GIF metadata):
<Image gif:ImageBehavior.RepeatBehavior="3x"
gif:ImageBehavior.AnimatedSource="Images/animated.gif" />
And of course you can also set the image in code:
var image = new BitmapImage();
image.BeginInit();
image.UriSource = new Uri(fileName);
image.EndInit();
ImageBehavior.SetAnimatedSource(img, image);
See the wiki for more details on usage.
Features
- Animates GIF images in a normal
Imagecontrol; no need to use a specific control - Takes actual frame duration into account
- Repeat behavior can be specified; if unspecified, the repeat count from the GIF metadata is used
- Notification when the animation completes, in case you need to do something after the animation
- Animation preview in design mode (must be enabled explicitly)
- Support for controlling the animation manually (pause/resume/seek)
How to build
Run build.cmd.
Note: the library's version number is determined by MinVer based on Git history and tags. A consequence of this is that if you build the project outside a Git repository (e.g. if you just download sources), you'll get a version number of 0.0.0.0. So, in order to build with the correct version number, make sure you're in a Git clone of the project, and that your clone has the tags from the upstream project (git fetch upstream --tags, assuming your remote for the upstream project is named upstream).
관련 프로젝트 살펴보기
불러오는 중…