Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I'm trying to develop a small image viewer just as an exercise to sharpen my programming skills. So far , all the features that I could think of adding to it are zooming in and out, inverting the colors of the image and resizing.

Could anyone suggest me a few more features?? You are also welcome to suggest anything which has not been implemented yet. I would like to take it as a learning challenge.



migration rejected from stackoverflow.com Aug 30 at 4:45

This question came from our site for professional and enthusiast programmers. Votes, comments, and answers are locked due to the question being closed here, but it may be eligible for editing and reopening on the site where it originated.

closed as too broad by rwong, MichaelT, ratchet freak, GlenH7, gnat Aug 30 at 4:45

There are either too many possible answers, or good answers would be too long for this format. Please add details to narrow the answer set or to isolate an issue that can be answered in a few paragraphs.If this question can be reworded to fit the rules in the help center, please edit the question.

Rotating the image by +/- 90 degrees is very useful. Cropping could be as well. I'd say these two are more useful than inverting colours. –  FrustratedWithFormsDesigner Jun 15 '10 at 18:10
@: Sure Mr. Thanks for your suggestions. I think they can be considered :-) –  avi Jun 15 '10 at 18:15
Please give some more suggestions. Zooming in and out wasn't so difficult to implement so please suggest more and meanwhile I will try to finish cropping and rotation things. –  avi Jun 16 '10 at 2:13
+1 for cropping. Any chance you'll be open-sourcing this? I've been trying to learn silverlight myself. –  Ben Herila Jun 18 '10 at 5:04
Take a look at any popular painting package - Paint.NET for example - and work through it's options in any order you like. –  ChrisF Feb 2 '11 at 21:39

6 Answers 6

If the goal is learning, implement some basic matrix based effects such as different types of blurs. That will introduce you to image processing.

And if you are scaling the image, or allowing the user to export it at a different size, you could study up on different interpolation techniques to create better looking images when you resize them.

+1 Doing the work to pass a MxM matrix over your image will open up a huge number of possibilities such as sharpening, blurring, etc. So one routine implemented in a re-usable way gives you dozens of new features through varying the data (matrix). –  JBRWilkinson Feb 2 '11 at 21:34

How about the functionality to do a binary compare between two images? That would be useful, and interesting from a programming perspective.


Histogram Equalization would give you a function which can do 'enhance'-type of operations on photos. Compare the two images below (before > after)

Original Image Enhanced Image

See the full article on Wikipedia.


Hough Transforms and a little bit of statistical analysis would allow you to perform 'straighten image' operations and things like 'auto-align to horizon'. The maths is pretty simple, if a little computationally-expensive for large images. For each 'on' pixel, you increment a lookup table in the row, column representing the distance-from-origin and possible angle of a line that passes through that point.

I used this to analyse manuscript music and then straighten it before doing image processing as when decomposing high-resolution images of complex symbologies (musical notation), it really helps if they're straight on the page to begin with!

See the full article on Wikipedia.


Mathematical Morphology would give your application a suite of operations which can be combined to produce effects like Edge Detection. The processing is really easy - to 'dilate', replace all on-pixels with a 'plus' shape, to 'erode' replace all 'plus' shapes with single pixels. Do this a few times and you'll see broken paths join up and edges smoothen. Subtract one image from another to get edges.


(WARNING: personal-horn-tooting) I have been doing this, myself (albiet in a web context). I started out with a fork of a Django thumbnailing framework, but I've added many other image-manipulation algorithms and data-structures, e.g.:



... Normally, I wouldn't be all like "hey look at my project!!" except that I can personally identify with what you are trying to do.

So, have a look at my code -- https://github.com/fish2000/django-imagekit -- I have cited all of my sources in the comments, and although I've explored a number of image-processing techniques, I've really barely scratched the surface. I'd be interested in seeing your app, as well, if it's up somewhere public.