blob: b8900b824f2f9973500bb5bb584c06ce8e207e80 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
#ifndef PGM_H
#define PGM_H
#include <stdio.h>
#include <stdint.h>
typedef struct {
uint8_t r, g, b;
} color_t;
color_t *color_set(color_t *c, uint8_t r, uint8_t g, uint8_t b);
int pgm_write_header(FILE *fp, unsigned int w, unsigned int h);
int pgm_write_pixel(FILE *fp, color_t *c);
#endif
|