{"id":13640401,"url":"https://github.com/GuOrg/Gu.Wpf.Geometry","last_synced_at":"2025-04-20T02:33:29.502Z","repository":{"id":5838845,"uuid":"42720645","full_name":"GuOrg/Gu.Wpf.Geometry","owner":"GuOrg","description":null,"archived":false,"fork":false,"pushed_at":"2024-05-25T21:01:13.000Z","size":3030,"stargazers_count":166,"open_issues_count":10,"forks_count":28,"subscribers_count":13,"default_branch":"master","last_synced_at":"2025-04-04T20:15:29.336Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/GuOrg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-09-18T12:27:47.000Z","updated_at":"2025-01-20T04:02:40.000Z","dependencies_parsed_at":"2023-12-25T17:07:26.685Z","dependency_job_id":"d21e7756-a4a2-48fd-8e66-22d464368091","html_url":"https://github.com/GuOrg/Gu.Wpf.Geometry","commit_stats":{"total_commits":508,"total_committers":6,"mean_commits":84.66666666666667,"dds":0.16338582677165359,"last_synced_commit":"56e9e4e348bcfaf6a2e127fbb0f5ac975b1e4766"},"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GuOrg%2FGu.Wpf.Geometry","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GuOrg%2FGu.Wpf.Geometry/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GuOrg%2FGu.Wpf.Geometry/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/GuOrg%2FGu.Wpf.Geometry/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/GuOrg","download_url":"https://codeload.github.com/GuOrg/Gu.Wpf.Geometry/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249840694,"owners_count":21332925,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-08-02T01:01:10.819Z","updated_at":"2025-04-20T02:33:29.068Z","avatar_url":"https://github.com/GuOrg.png","language":"C#","funding_links":[],"categories":["UI Controls"],"sub_categories":["Individual Controls"],"readme":"# Gu.Wpf.Geometry\n[![License](https://img.shields.io/badge/license-MIT-blue.svg)](LICENSE.md)\n[![Gitter](https://badges.gitter.im/JoinChat.svg)](https://gitter.im/GuOrg/Gu.Wpf.Geometry?utm_source=badge\u0026utm_medium=badge\u0026utm_campaign=pr-badge\u0026utm_content=badge)\n[![NuGet](https://img.shields.io/nuget/v/Gu.Wpf.Geometry.svg)](https://www.nuget.org/packages/Gu.Wpf.Geometry/)\n[![Build status](https://ci.appveyor.com/api/projects/status/1nk9elw89ker9fjs?svg=true)](https://ci.appveyor.com/project/JohanLarsson/gu-wpf-geometry)\n[![Build Status](https://dev.azure.com/guorg/Gu.Wpf.Geometry/_apis/build/status/GuOrg.Gu.Wpf.Geometry?branchName=master)](https://dev.azure.com/guorg/Gu.Wpf.Geometry/_build/latest?definitionId=6\u0026branchName=master)\n[![ci](https://github.com/GuOrg/Gu.Wpf.Geometry/actions/workflows/ci.yml/badge.svg)](https://github.com/GuOrg/Gu.Wpf.Geometry/actions/workflows/ci.yml)\n\nSmall library with WPF geometries and shaders.\n\n# Contents\n- [Geometries](#geometries)\n  - [Balloon](#balloon)\n  - [BoxBalloon](#boxballoon)\n        - [Simple](#simple)\n        - [ConnectorAngle](#connectorangle)\n        - [ConnectorOffset](#connectoroffset)\n        - [With PlacementTarget](#with-placementtarget)\n        - [PlacementTarget](#placementtarget)\n        - [PlacementOptions](#placementoptions)\n  - [EllipseBalloon](#ellipseballoon)\n  - [GradientPath](#gradientpath)\n- [Controls](#controls)\n  - [Zoombox](#zoombox)\n- [Effects](#effects)\n  - [DesaturateEffect](#desaturateeffect)\n  - [FadeEffect](#fadeeffect)\n  - [MaskEffect](#maskeffect)\n  - [AngularGradientEffect](#angulargradienteffect)\n  - [HsvWheelEffect](#hsvwheeleffect)\n  - [HslWheelEffect](#hslwheeleffect)\n\n# Geometries\n\n## Balloon\nA `ContentControl`for showing balloons.\n\nNote: WPF Popup clips to bounds so the connector will be clipped when used in a popup.\n\n```\n\u003cgeometry:Balloon Grid.Row=\"1\"\n                  HorizontalAlignment=\"Center\"\n                  VerticalAlignment=\"Center\"\n                  ConnectorAngle=\"25\"\n                  CornerRadius=\"15\"\n                  PlacementOptions=\"Bottom, Center\"\n                  PlacementTarget=\"{Binding ElementName=Target}\"\u003e\n    \u003cGrid Margin=\"5\"\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cTextBlock Text=\"{Binding Text, ElementName=TextBox}\" /\u003e\n        \u003cUniformGrid Grid.Row=\"1\"\n                     Rows=\"1\"\u003e\n            \u003cEllipse Width=\"20\"\n                     Height=\"20\"\n                     Fill=\"Blue\" /\u003e\n            \u003cEllipse Width=\"20\"\n                     Height=\"20\"\n                     Fill=\"Yellow\" /\u003e\n            \u003cEllipse Width=\"20\"\n                     Height=\"20\"\n                     Fill=\"Red\" /\u003e\n        \u003c/UniformGrid\u003e\n    \u003c/Grid\u003e\n\u003c/geometry:Balloon\u003e\n```\n\n![balloon](http://i.imgur.com/5BLZzJU.png)\n\n## BoxBalloon\nDraws a border with a connector.\nNote: the connector is drawn outside the bounds of the element.\n\n\n##### Simple\n\n```xaml\n\u003cgeometry:BoxBalloon Grid.Row=\"1\"\n                     Grid.Column=\"1\"\n                     ConnectorAngle=\"45\"\n                     ConnectorOffset=\"-10,-0\"\n                     CornerRadius=\"10\"\n                     Stroke=\"CornflowerBlue\"\n                     StrokeThickness=\"4\" /\u003e\n```\n![simple balloon](http://i.imgur.com/YZDjCvj.png)\n\n##### ConnectorAngle\n![connector angle](http://i.imgur.com/lwViiPI.png)\n\n##### ConnectorOffset\n\n![connector offset](http://i.imgur.com/hT1fFsj.png)\n\n##### With PlacementTarget\n```xaml\n\u003cCanvas\u003e\n    \u003cGrid\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cGrid.ColumnDefinitions\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition /\u003e\n        \u003c/Grid.ColumnDefinitions\u003e\n        \u003cListBox x:Name=\"Placements\"\n                 Grid.Row=\"0\"\n                 Grid.RowSpan=\"3\"\n                 Grid.Column=\"2\"\n                 SelectedIndex=\"0\"\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Top\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Bottom\u003c/geometry:PlacementOptions\u003e\n        \u003c/ListBox\u003e\n\n        \u003cgeometry:BoxBalloon Grid.Row=\"1\"\n                             Grid.Column=\"1\"\n                             Margin=\"6\"\n                             ConnectorAngle=\"45\"\n                             CornerRadius=\"10\"\n                             PlacementOptions=\"{Binding SelectedItem,\n                                                        ElementName=Placements}\"\n                             PlacementTarget=\"{Binding ElementName=Target}\"\n                             Stroke=\"HotPink\"\n                             StrokeThickness=\"4\" /\u003e\n    \u003c/Grid\u003e\n    \u003cRectangle x:Name=\"Target\"\n               Canvas.Left=\"100\"\n               Canvas.Top=\"50\"\n               Width=\"100\"\n               Height=\"10\"\n               Fill=\"Gainsboro\"\n               MouseLeftButtonDown=\"OnTargetMouseLeftDown\" /\u003e\n\u003c/Canvas\u003e\n```\n\n![connected balloon](http://i.imgur.com/wJBJACc.gif)\n\n##### With PlacementRectangle\n```xaml\n\u003cCanvas\u003e\n    \u003cGrid\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cGrid.ColumnDefinitions\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition /\u003e\n        \u003c/Grid.ColumnDefinitions\u003e\n        \u003cListBox x:Name=\"Placements\"\n                 Grid.Row=\"0\"\n                 Grid.RowSpan=\"3\"\n                 Grid.Column=\"2\"\n                 SelectedIndex=\"0\"\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Top\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Bottom\u003c/geometry:PlacementOptions\u003e\n        \u003c/ListBox\u003e\n\n        \u003cgeometry:BoxBalloon Grid.Row=\"1\"\n                             Grid.Column=\"1\"\n                             Margin=\"6\"\n                             ConnectorAngle=\"45\"\n                             CornerRadius=\"10\"\n                             PlacementOptions=\"{Binding SelectedItem,\n                                                        ElementName=Placements}\"\n                             PlacementRectangle=\"100, 50, 100, 10\"\n                             Stroke=\"HotPink\"\n                             StrokeThickness=\"4\" /\u003e\n    \u003c/Grid\u003e\n    \u003cRectangle x:Name=\"Target\"\n               Canvas.Left=\"100\"\n               Canvas.Top=\"50\"\n               Width=\"100\"\n               Height=\"10\"\n               Fill=\"Gainsboro\"\n               MouseLeftButtonDown=\"OnTargetMouseLeftDown\" /\u003e\n\u003c/Canvas\u003e\n```\n\n![connected balloon](http://i.imgur.com/wJBJACc.gif)\n\n##### With PlacementRectangle and PlacementTarget\n```xaml\n\u003cCanvas\u003e\n    \u003cGrid\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition Height=\"100\" /\u003e\n            \u003cRowDefinition /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cGrid.ColumnDefinitions\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition Width=\"100\" /\u003e\n            \u003cColumnDefinition /\u003e\n        \u003c/Grid.ColumnDefinitions\u003e\n        \u003cListBox x:Name=\"Placements\"\n                 Grid.Row=\"0\"\n                 Grid.RowSpan=\"3\"\n                 Grid.Column=\"2\"\n                 SelectedIndex=\"0\"\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter 5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eCenter -5\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eTop Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eBottom Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Center\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Left\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Right\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Top\u003c/geometry:PlacementOptions\u003e\n            \u003cgeometry:PlacementOptions\u003eAuto Bottom\u003c/geometry:PlacementOptions\u003e\n        \u003c/ListBox\u003e\n\n        \u003cgeometry:BoxBalloon Grid.Row=\"1\"\n                             Grid.Column=\"1\"\n                             Margin=\"6\"\n                             ConnectorAngle=\"45\"\n                             CornerRadius=\"10\"\n                             PlacementOptions=\"{Binding SelectedItem,\n                                                        ElementName=Placements}\"\n                             PlacementRectangle=\"0, 0, 100, 10\"\n\t\t\t\t\t\t\t PlacementTarget={Binding ElementName=Target}\n                             Stroke=\"HotPink\"\n                             StrokeThickness=\"4\" /\u003e\n    \u003c/Grid\u003e\n    \u003cRectangle x:Name=\"Target\"\n               Canvas.Left=\"100\"\n               Canvas.Top=\"50\"\n               Width=\"100\"\n               Height=\"10\"\n               Fill=\"Gainsboro\"\n               MouseLeftButtonDown=\"OnTargetMouseLeftDown\" /\u003e\n\u003c/Canvas\u003e\n```\n\n![connected balloon](http://i.imgur.com/wJBJACc.gif)\n\n##### PlacementTarget\nThe UIElement to connect the balloon to.\n\n##### PlacementRectangle\nThe rectangle to connect the balloon to. If used with PlacementTarget, the rectangle coordinates are relative to it. If used alone, the coordinates are relative to the parent UIElement.\n\n##### PlacementOptions\nWhere on the connected element the connector should be attached.\n\nIn xaml either input a string `\u003cgeometry:BoxBalloon PlacementOptions=\"Top Left\" .../\u003e`\nOr use the `PlacementOptionsExtension`:\n```xaml\n\u003cgeometry:BoxBalloon PlacementOptions=\"{geometry:PlacementOptions Horizontal=Auto,\n                                                                  Vertical=Top,\n                                                                  Offset=5}\"\n                     ...\n                      /\u003e\n```\n\n## EllipseBalloon\n\nSame API as BoxBalloon but renders:\n\n![EllipseBallon](http://i.imgur.com/2yMYmfR.png)\n\n## GradientPath\n\nBased on [this blog post](http://www.charlespetzold.com/blog/2009/02/Graphical-Paths-with-Gradient-Colors.html)\n\n```xaml\n\u003cgeometry:GradientPath GradientMode=\"Parallel\"\n                        StrokeThickness=\"10\"\n                        UseLayoutRounding=\"True\"\u003e\n    \u003cgeometry:GradientPath.Data\u003e\n        \u003cPathGeometry\u003e\n            \u003cPathFigure StartPoint=\"35,400\"\u003e\n                \u003cLineSegment Point=\"100,300\" /\u003e\n                \u003cBezierSegment Point1=\"300,10\"\n                                Point2=\"500,600\"\n                                Point3=\"700,300\" /\u003e\n                \u003cLineSegment Point=\"800,100\" /\u003e\n            \u003c/PathFigure\u003e\n            \u003cPathFigure StartPoint=\"200,200\"\u003e\n                \u003cLineSegment Point=\"200,400\" /\u003e\n                \u003cLineSegment Point=\"400,400\" /\u003e\n            \u003c/PathFigure\u003e\n        \u003c/PathGeometry\u003e\n    \u003c/geometry:GradientPath.Data\u003e\n    \u003cgeometry:GradientPath.GradientStops\u003e\n        \u003cGradientStop Offset=\"0\" Color=\"#4C0000FF\" /\u003e\n        \u003cGradientStop Offset=\"0.5\" Color=\"#4CFF0000\" /\u003e\n        \u003cGradientStop Offset=\"1\" Color=\"#4CFFFF00\" /\u003e\n    \u003c/geometry:GradientPath.GradientStops\u003e\n\u003c/geometry:GradientPath\u003e\n```\n![screenie](http://i.imgur.com/YxNoS87.gif)\n\n# Controls\n\n## Zoombox\n\nPanel for zooming \u0026 panning. Handles touch but IsManipulationEnabled has default value `false` meaning no touch.\n\n```xaml\n\u003cUserControl ...\n             xmlns:effects=\"http://gu.se/Geometry\"\u003e\n    \u003cGrid\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003ceffects:Zoombox x:Name=\"ImageBox\"\n                         IsManipulationEnabled=\"True\"\n                         MaxZoom=\"10\"\n                         MinZoom=\"0.1\"\u003e\n            \u003cImage Source=\"Images/Circles.png\" /\u003e\n        \u003c/effects:Zoombox\u003e\n        \u003cUniformGrid Grid.Row=\"1\" Rows=\"1\"\u003e\n            \u003cButton Command=\"effects:ZoomCommands.Increase\"\n                    CommandParameter=\"2.0\"\n                    CommandTarget=\"{Binding ElementName=ImageBox}\"\n                    Content=\"Increase\" /\u003e\n\n            \u003cButton Command=\"effects:ZoomCommands.Decrease\"\n                    CommandParameter=\"2.0\"\n                    CommandTarget=\"{Binding ElementName=ImageBox}\"\n                    Content=\"Decrease\" /\u003e\n\n            \u003cButton Command=\"effects:ZoomCommands.None\"\n                    CommandTarget=\"{Binding ElementName=ImageBox}\"\n                    Content=\"None\" /\u003e\n\n            \u003cButton Command=\"effects:ZoomCommands.Uniform\"\n                    CommandTarget=\"{Binding ElementName=ImageBox}\"\n                    Content=\"Uniform\" /\u003e\n\n            \u003cButton Command=\"effects:ZoomCommands.UniformToFill\"\n                    CommandTarget=\"{Binding ElementName=ImageBox}\"\n                    Content=\"UniformToFill\" /\u003e\n        \u003c/UniformGrid\u003e\n    \u003c/Grid\u003e\n\u003c/UserControl\u003e\n```\n\n# Effects\nA collection of pixel shaders.\n\n## DesaturateEffect\nDesaturate an image, brush or WPF controls. It has only one property `Strength` 0 means the effect does nothing and 1 means a grayscale image is returned.\n\n```xaml\n\u003cUserControl\n    ...\n    xmlns:effects=\"http://gu.se/Geometry\"\u003e\n    \u003cGrid\u003e\n        \u003cImage Source=\"Images/Hustler.jpg\"\u003e\n            \u003cImage.Effect\u003e\n                \u003ceffects:DesaturateEffect Strength=\"{Binding ElementName=Slider, Path=Value}\" /\u003e\n            \u003c/Image.Effect\u003e\n        \u003c/Image\u003e\n        \u003cSlider\n            x:Name=\"Slider\"\n            VerticalAlignment=\"Bottom\"\n            Maximum=\"1\"\n            Minimum=\"0\" /\u003e\n    \u003c/Grid\u003e\n\u003c/UserControl\u003e\n```\n\n## FadeEffect\nFade an image to a colour.\n\n```xaml\n\u003cUserControl ...\n             xmlns:effects=\"http://gu.se/Geometry\"\u003e\n    \u003cGrid\u003e\n        \u003cImage Source=\"../Images/Hustler.jpg\"\u003e\n            \u003cImage.Effect\u003e\n                \u003ceffects:FadeEffect To=\"Black\" Strength=\"{Binding ElementName=StrengthSlider, Path=Value}\" /\u003e\n            \u003c/Image.Effect\u003e\n        \u003c/Image\u003e\n        \u003cSlider\n            x:Name=\"StrengthSlider\"\n            VerticalAlignment=\"Bottom\"\n            Maximum=\"1\"\n            Minimum=\"0\" /\u003e\n    \u003c/Grid\u003e\n\u003c/UserControl\u003e\n```\n\n## MaskEffect\nRender an image as a selection mask.\n\n```xaml\n\u003cUserControl ...\n             xmlns:effects=\"http://gu.se/Geometry\"\u003e\n    \u003cGrid\u003e\n        \u003cImage Source=\"../Images/Circle.png\"\u003e\n            \u003cImage.Effect\u003e\n                \u003ceffects:MaskEffect  /\u003e\n            \u003c/Image.Effect\u003e\n        \u003c/Image\u003e\n    \u003c/Grid\u003e\n\u003c/UserControl\u003e\n```\n\n## AngularGradientEffect\nA gradient that changes value along the angle. Perhaps useful for spinners.\nReplaces the pixels of the owning element. The owning element must have a `Brush` set the brush can be any color that is not transparent.\n\n### StartAngle\nThe angle for the `StartColor` -360 - 360 degrees, positive clockwise. Zero at 12 o'clock.\n\n### CentralAngle\nThe anglular extent of the gradient -360 - 360 degrees, positive clockwise.\n\n### CenterPoint\nThe center point of the gradient (0, 0) - (1, 1) default is (0.5, 0.5) fore a gradient around the center.\n\n```xaml\n\u003cWindow xmlns=\"http://schemas.microsoft.com/winfx/2006/xaml/presentation\"\n        xmlns:x=\"http://schemas.microsoft.com/winfx/2006/xaml\"\n        xmlns:d=\"http://schemas.microsoft.com/expression/blend/2008\"\n        xmlns:effects=\"http://gu.se/Geometry\"\n        xmlns:mc=\"http://schemas.openxmlformats.org/markup-compatibility/2006\"\n        Title=\"AngularGradientWindow\"\n        SizeToContent=\"WidthAndHeight\"\n        mc:Ignorable=\"d\"\u003e\n    \u003cGrid\u003e\n        \u003cGrid.ColumnDefinitions\u003e\n            \u003cColumnDefinition Width=\"Auto\" /\u003e\n            \u003cColumnDefinition /\u003e\n        \u003c/Grid.ColumnDefinitions\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cGroupBox x:Name=\"Render\"\n                  Grid.Row=\"0\"\n                  Grid.Column=\"1\"\n                  Margin=\"50\"\n                  Background=\"LightGray\"\n                  BorderThickness=\"0\"\n                  Style=\"{StaticResource InvisibleGroupBoxStyle}\"\u003e\n            \u003cEllipse x:Name=\"Ellipse\"\n                     Width=\"200\"\n                     Height=\"200\"\n                     Stroke=\"White\"\n                     StrokeThickness=\"25\"\u003e\n                \u003cEllipse.Effect\u003e\n                    \u003ceffects:AngularGradientEffect CenterPoint=\"{Binding ElementName=CenterPoint,\n                                                                         Path=Text}\"\n                                                   CentralAngle=\"{Binding ElementName=CentralAngle,\n                                                                          Path=Value}\"\n                                                   EndColor=\"{Binding ElementName=EndColour,\n                                                                      Path=Text}\"\n                                                   StartAngle=\"{Binding ElementName=StartAngle,\n                                                                        Path=Value}\"\n                                                   StartColor=\"{Binding ElementName=StartColour,\n                                                                        Path=Text}\" /\u003e\n                \u003c/Ellipse.Effect\u003e\n            \u003c/Ellipse\u003e\n        \u003c/GroupBox\u003e\n\n        \u003cTextBlock Grid.Row=\"1\"\n                   Grid.Column=\"0\"\n                   Text=\"Start colour:\" /\u003e\n        \u003cTextBox x:Name=\"StartColour\"\n                 Grid.Row=\"1\"\n                 Grid.Column=\"1\"\n                 Text=\"#FFFF0000\" /\u003e\n\n        \u003cTextBlock Grid.Row=\"2\"\n                   Grid.Column=\"0\"\n                   Text=\"End colour:\" /\u003e\n        \u003cTextBox x:Name=\"EndColour\"\n                 Grid.Row=\"2\"\n                 Grid.Column=\"1\"\n                 Text=\"#00FF0000\" /\u003e\n\n        \u003cTextBlock Grid.Row=\"3\"\n                   Grid.Column=\"0\"\n                   Text=\"Center point:\" /\u003e\n        \u003cTextBox x:Name=\"CenterPoint\"\n                 Grid.Row=\"3\"\n                 Grid.Column=\"1\"\n                 Text=\"0.5 0.5\" /\u003e\n\n        \u003cTextBlock Grid.Row=\"4\"\n                   Grid.Column=\"0\"\n                   Text=\"Start angle:\" /\u003e\n        \u003cSlider x:Name=\"StartAngle\"\n                Grid.Row=\"4\"\n                Grid.Column=\"1\"\n                Maximum=\"360\"\n                Minimum=\"-360\" /\u003e\n\n        \u003cTextBlock Grid.Row=\"5\"\n                   Grid.Column=\"0\"\n                   Text=\"Central angle:\" /\u003e\n        \u003cSlider x:Name=\"CentralAngle\"\n                Grid.Row=\"5\"\n                Grid.Column=\"1\"\n                Maximum=\"360\"\n                Minimum=\"-360\"\n                Value=\"360\" /\u003e\n    \u003c/Grid\u003e\n\u003c/Window\u003e\n\n```\n\n![animation](https://user-images.githubusercontent.com/1640096/33270557-c407bbdc-d384-11e7-9e81-03d5ab9f7b08.gif)\n\n## HsvWheelEffect\nA gradient that changes value along the angle. Perhaps useful for colour pickers.\nNote that the element must have a background or fill. The brush can be any colour.\n\n```xaml\n\u003cUserControl ...\n             xmlns:effects=\"http://gu.se/Geometry\"\u003e\n    \u003cGrid\u003e\n        \u003cGrid.ColumnDefinitions\u003e\n            \u003cColumnDefinition Width=\"Auto\" /\u003e\n            \u003cColumnDefinition /\u003e\n        \u003c/Grid.ColumnDefinitions\u003e\n        \u003cGrid.RowDefinitions\u003e\n            \u003cRowDefinition /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n            \u003cRowDefinition Height=\"Auto\" /\u003e\n        \u003c/Grid.RowDefinitions\u003e\n        \u003cEllipse Grid.ColumnSpan=\"2\"\n                 Width=\"300\"\n                 Height=\"300\"\n                 HorizontalAlignment=\"Center\"\n                 Fill=\"White\"\u003e\n            \u003cEllipse.Effect\u003e\n                \u003ceffects:HsvWheelEffect InnerRadius=\"{Binding ElementName=InnerRadius, Path=Value}\"\n                                        InnerSaturation=\"{Binding ElementName=InnerSaturation, Path=Value}\" /\u003e\n            \u003c/Ellipse.Effect\u003e\n        \u003c/Ellipse\u003e\n\n        \u003cLabel Grid.Row=\"1\"\n               Grid.Column=\"0\"\n               Content=\"Inner radius:\" /\u003e\n        \u003cSlider x:Name=\"InnerRadius\"\n                Grid.Row=\"1\"\n                Grid.Column=\"1\"\n                Maximum=\"1\"\n                Minimum=\"0\"\n                Value=\"0\" /\u003e\n\n        \u003cLabel Grid.Row=\"2\"\n               Grid.Column=\"0\"\n               Content=\"Inner saturation:\" /\u003e\n        \u003cSlider x:Name=\"InnerSaturation\"\n                Grid.Row=\"2\"\n                Grid.Column=\"1\"\n                Maximum=\"1\"\n                Minimum=\"0\"\n                Value=\"0\" /\u003e\n    \u003c/Grid\u003e\n\u003c/UserControl\u003e\n```\n\n## HslWheelEffect\nA gradient that changes value along the angle. Perhaps useful for colour pickers.\nNote that the element must have a background or fill. The brush can be any colour.\nSame API as HsvWheelEffect\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGuOrg%2FGu.Wpf.Geometry","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FGuOrg%2FGu.Wpf.Geometry","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FGuOrg%2FGu.Wpf.Geometry/lists"}