Thread: Histogram of an image

  1. #1
    Registered User
    Join Date
    Feb 2019

    Post Histogram of an image

    Write a C program to compute the histogram of an image. The program should be able to read the input image from an ASCII file, visit each pixel, and update an element of a 1-dimensional array called histogram[], which has a length of 256 (the values of the gray scale). The element of the array that will be updated (incremented) will be the one corresponding to the pixel value read at the current location of the nested loop. The program should save the output into an ASCII file of exactly the same size as the histogram array. Call the output file Histogram.dat.

  2. #2
    and the hat of int overfl Salem's Avatar
    Join Date
    Aug 2001
    The edge of the known universe
    Yeah, this isn't a homework dump site for you to get answers on a plate.

    Show some effort.
    If you dance barefoot on the broken glass of undefined behaviour, you've got to expect the occasional cut.
    If at first you don't succeed, try writing your phone number on the exam paper.

Popular pages Recent additions subscribe to a feed

Similar Threads

  1. histogram of an image
    By mrtfb123 in forum C Programming
    Replies: 14
    Last Post: 08-03-2017, 11:31 PM
  2. Histogram in C of an PGM image
    By gg123 in forum C Programming
    Replies: 5
    Last Post: 08-03-2014, 10:58 AM
  3. Replies: 4
    Last Post: 03-13-2010, 05:10 AM
  4. Replies: 13
    Last Post: 11-20-2009, 04:43 PM
  5. Problems with Image Magick [Unable to Quantisize Image]
    By Maragato in forum C Programming
    Replies: 1
    Last Post: 09-18-2006, 10:41 PM

Tags for this Thread