CodeDog57
CodeDog57

Reputation: 21

Glow effect for lines drawn in InkCanvas

I'm using the WPF InkCanvas for a drawing application. The canvas is over a image. I can scribble over the image OK but I need it to have a glow effect - i.e. the actual lines drawn must have this effect. Is there a way to do this in XAML or in the C# code?

Upvotes: 2

Views: 336

Answers (1)

Ani
Ani

Reputation: 10896

You want to use a ShaderEffect and attach it to the UIElement.Effect of the InkCanvas. This MSDN article contains a sample that shows how to write ShaderEffects.

Try starting with the excellent set of ShaderEffects implemented in the Windows Presentation Foundation Pixel Shader Effects Library.

Upvotes: 1

Related Questions