Recommended

  • Silverlight 4 Podcast Pack with Tim Heuer
  • Building Modular Silverlight Applications
  • Prism -  10 Things to Know
  • Securing Silverlight Application and WCF Service using ASP.Net Authentication Techniques
  • Model– View – ViewModel in Silverlight
Skip Navigation LinksHome / News / View News

Changing Brush Brightness in WPF/Silverlight

+ Add to SilverlightShow Favorites
0 comments   /   posted by Silverlight Show on Mar 05, 2010
(0 votes)
Tags: Brushes , Colors , WPF , C#
Ailon demonstrates a way to change the brightness of a Brush or Color in WPF and Silverlight.

System.Windows.Media.Color structure represents colors as 4 channels: alpha (opacity) channel and 3 channels for each core color (red, green and blue). aRGB color space is good for representing colors but it’s quite problematic to control such properties as brightness with these 4 channels. We will convert our colors to and from a HSB color space which is good at exactly what we need – controlling such perceptual color characteristics as hue, saturation and brightness.

Share


Comments

Comments RSS RSS
No comments

Add Comment

 
 

   
  
  
   
Please add 4 and 5 and type the answer here: