struct pixel read_pixel_array(FILE *image, int pixel_array_offset, int width, int height) {
    //allocate rows
    struct pixel** rows = malloc(height * sizeof(struct pixel*));
    if (rows == NULL){
        exit(1);
    }
    //alocate each row
    for (int i=0; i<height; i++) {
        rows[i] = malloc(width * sizeof(struct pixel));
        if (rows[i] == NULL){
            exit(1);
        }
    }
    //read into memory
    fseek(image, pixel_array_offset, SEEK_SET);
    for (int i=0; i<height; i++) {
        for (int j=0; j<width; j++) {
            unsigned char r;
            unsigned char g;
            unsigned char b;
            fread(&b, sizeof(char), 1, image);
            fread(&g, sizeof(char), 1, image);
            fread(&r, sizeof(char), 1, image);
            struct pixel pix;
            pix.blue = b;
            pix.green = g;
            pix.red = r;
            rows[i][j] = pix;
        }
    }
    return rows;
}
return an array of arrays of pixels