/*
*Madison Noyce
*11/17/22
*Lab Section 1011-007
*Lab 11
*This program will take pixels from a source and send them along with an
*image header to an outside source such as Gimp but in a smaller size with
file pointers.
*/

#ifndef DEFS_H
#define DEFS_H

#include <stdio.h>
#include <stdlib.h>
#include <string.h>

//Structs
typedef struct HeaderInfo {
        char type[3];
        int width, height, maxColor;
} headerInfo;

typedef struct pixel {
        unsigned int r, g, b;
} pixelValues;

//Prototypes
headerInfo getHeader(FILE *inFile);
void writeHeader(headerInfo Header, FILE *outFile);
void fillImageArray(pixelValues picture[], int width, int height,FILE *inFile);
void writePixels(pixelValues picture[], int width, int height, FILE *outFile);
void halfSizeWritePixels(pixelValues picture[], int width, int height, FILE *outFile);

#endif
