Tag Archives: pixels

Easily manipulate pixels in WPF and C#

After building the example Save bitmap files in WPF and C#, I couldn’t get it out of my head. Doing the math to set the correct bytes in a one-dimensional pixel array isn’t all that hard, but it is annoying … Continue reading

Posted in graphics, image processing, wpf | Tagged , , , , , , , , , , , , , | 1 Comment

Save bitmap files in WPF and C#

This example shows how to use WPF and C# to save bitmap files. The example Set the pixels in a WPF bitmap in C# shows how to create a WriteableBitmap in WPF. This example shows how to save the resulting … Continue reading

Posted in files, graphics, image processing | Tagged , , , , , , , , , , , , , , , | 3 Comments

Make a Region from non-transparent pixels in C#

The example Make shaped PictureBoxes in C# sets the Region property of two PictureBox controls to circular regions. That works well in that example where the images are round volleyballs with transparent backgrounds, but it would be hard to manually … Continue reading

Posted in algorithms, geometry, graphics, image processing | Tagged , , , , , , , , , , , , , | 1 Comment

Resize an image to view its pixels in C#

This example shows how to resize an image so it is big enough to view its pixels. Normally you want resized images to be smooth, but this technique can be useful if you want to see exactly what colors the … Continue reading

Posted in graphics, image processing | Tagged , , , , , , , , , , , | Leave a comment

Set the pixels in a WPF bitmap in C#

This example shows how you can manipulate the pixels in a WPF bitmap. One of the things I like least about WPF is the way Microsoft threw away everything we had learned over years of working with Visual Studio. Yes, … Continue reading

Posted in graphics, image processing, wpf, XAML | Tagged , , , , , , , , , , , , , | 5 Comments