/*
 * =====================================================================================
 *         Name:  Mac Howe, Pmhowe@clemson.edu
 *         Date:  11/15/2022 
 *  Lab Section:  7  
 *         Lab#:  11
 *  Description:  Structure and prototypes 
 *
 *
 * =====================================================================================
 */

#ifndef DEFS_H
#define DEFS_H
#include <stdio.h>
#include <stdlib.h>
#include <string.h>


typedef struct header{
	char type[3];
	int width;
	int height;
	int maxColor;
} header_t;

typedef struct pixel{
	int red, green, blue;
}pixel_t;


header_t getHeader(FILE *in);

void writeHeader(header_t head, FILE *out);

void fillImageArray(pixel_t *p, int height, int width,FILE *in);

void writePixels(pixel_t *p, int height, int width);

void halfSizeWritePixels(pixel_t *p, int height, int width, FILE *out);

#endif
