This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{"first_name":"Jean-S\u00e9bastien","last_name":"Dupuy","profile_pic":"https:\/\/scontent.xx.fbcdn.net\/v\/t1.0-1\/16113899_10154938512472498_6380520617107877960_n.jpg?oh=05405c7c5665b213ed6929bfde684ddf&oe=5925A20F","locale":"fr_FR","timezone":1,"gender":"male"} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
https://graph.facebook.com/v2.6/[userid]?fields=first_name,last_name,profile_pic,locale,timezone,gender&access_token=[pagetoken] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using Windows.UI.Composition; | |
using Windows.UI.Xaml; | |
using Windows.UI.Xaml.Controls; | |
using Windows.UI.Xaml.Hosting; | |
namespace XamlComposition | |
{ | |
public sealed partial class MainPage : Page | |
{ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<Page | |
x:Class="XamlComposition.MainPage" | |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:local="using:XamlComposition" | |
xmlns:d="http://schemas.microsoft.com/expression/blend/2008" | |
xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" | |
mc:Ignorable="d"> | |
<Grid Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#region Saturation Effect | |
var graphicsEffect = new SaturationEffect | |
{ | |
Saturation = 0.0f, | |
Source = new CompositionEffectSourceParameter("input") | |
}; | |
var effectFactory = _compositor.CreateEffectFactory(graphicsEffect); | |
var effectBrush = effectFactory.CreateBrush(); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#region Image Visual | |
Uri localUri = new Uri("ms-appx:///Assets/windowscube.jpg"); | |
var imageFactory = CompositionImageFactory.CreateCompositionImageFactory(_compositor); | |
CompositionImageOptions options = new CompositionImageOptions() | |
{ | |
DecodeWidth = 450, | |
DecodeHeight = 300, | |
}; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#region Expression Animations | |
ExpressionAnimation expressionAnimation = _compositor.CreateExpressionAnimation(); | |
expressionAnimation.Expression = "foreground.RotationAngleInDegrees < 180 ? background.Offset.X + 4.0f : background.Offset.X - 4.0f"; | |
expressionAnimation.SetReferenceParameter("background", background); | |
expressionAnimation.SetReferenceParameter("foreground", foreground); | |
background.StartAnimation("Offset.X", expressionAnimation); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#region KeyFrame Animations | |
ScalarKeyFrameAnimation keyframeAnimation = _compositor.CreateScalarKeyFrameAnimation(); | |
keyframeAnimation.InsertKeyFrame(0.0f, 0.0f); // Optional | |
keyframeAnimation.InsertKeyFrame(1.0f, 360.0f, _compositor.CreateLinearEasingFunction()); | |
keyframeAnimation.Duration = TimeSpan.FromSeconds(3); | |
keyframeAnimation.IterationBehavior = AnimationIterationBehavior.Forever; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#region Composition | |
SpriteVisual background = _compositor.CreateSpriteVisual(); | |
background.Size = new Vector2(300.0f, 300.0f); | |
background.Offset = new Vector3(50.0f, 50.0f, 0.0f); | |
CompositionColorBrush indigo = _compositor.CreateColorBrush(); | |
indigo.Color = Color.FromArgb(0xFF, 0x4B, 0x00, 0x82); | |
background.Brush = indigo; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System; | |
using System.Numerics; | |
using Windows.ApplicationModel.Core; | |
using Windows.UI; | |
using Windows.UI.Composition; | |
using Windows.UI.Core; | |
namespace DemoComposition | |
{ | |
class DefaultView : IFrameworkView, IFrameworkViewSource |