Originally Posted by

**herbert**
Hi Aaron,

Most histograms will use 256 levels (8-bits can represent this many values and JPEGs are 8-bit). So a histogram wider than 256 pixels would be stretching the data but adding no more information. In this case I would just use an image resize routine on the histogram you have and ensure you use nearest neighbour interpolation. Make the histogram 2, 3 or 4 times larger and it will be big enough for your tutorials and still have the block-like appearance. Bilinear or cubic interpolation will make the graph edges soft.

If using a raw image with a bigger bit depth you could draw a lot more vertical bars. However they would be very thin and patchy due to sparse distribution of data. In this case it is common to collect values together to make the histogram a bit more smooth, e.g. 0-5, 6-10, etc. So you may never really need a histogram with more than 256 vertical bars anyway.

Alex