/*
 * MultiGIF  V1.0  28-Jun-96  Andy Wardley
 *
 * (C) 1996 Andy Wardley <abw@peritas.com>.  All rights reserved.
 *
 * gifio.h
 *
 * Header file for gifio.c
 *
 */

#ifndef GIFIO_H
#define GIFIO_H

#include <stdio.h>
#include <string.h>
#include "gif.h"



/* 
 * function prototypes from gifio.c 
 */

BYTE read_byte(FILE *fp);
void write_byte(BYTE b, FILE *fp);

WORD read_word(FILE *fp);
void write_word(WORD w, FILE *fp);

int read_string(BYTE *buffer, int length, FILE *fp);
int write_string(BYTE *buffer, int length, FILE *fp);

BYTE *read_data(FILE *fp);
int write_data(BYTE *buffer, FILE *fp);

int read_gif_header(gif_header *gh, FILE *fp);
int write_gif_header(gif_header *gh, FILE *fp);

int read_gif_colour_table(gif_colour *gct, int size, FILE *fp);
int write_gif_colour_table(gif_colour *gct, int size, FILE *fp);

int read_gif_img_desc(gif_img_desc *gid, FILE *fp);
int write_gif_img_desc(gif_img_desc *gid, FILE *fp);

int read_gif_graphic_control(gif_graphic_control *ggc, FILE *fp);
int write_gif_graphic_control(gif_graphic_control *ggc, FILE *fp);

int read_gif_plain_text(gif_plain_text *gpt, FILE *fp);
int write_gif_plain_text(gif_plain_text *gpt, FILE *fp);

int read_gif_app_ext(gif_app_ext *gae, FILE *fp);
int write_gif_app_ext(gif_app_ext *gae, FILE *fp);

int read_gif_comment(gif_comment *gc, FILE *fp);
int write_gif_comment(gif_comment *gc, FILE *fp);


#endif /* GIFIO_H */
