#include <errno.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
Go to the source code of this file.
|
static void | rgb24_to_yuv420p (unsigned char *lum, unsigned char *cb, unsigned char *cr, const unsigned char *src, int width, int height) |
|
static void | pgmyuv_save (const char *filename, int w, int h, const unsigned char *rgb_tab) |
|
static void | put_pixel (int x, int y, int r, int g, int b) |
|
◆ SCALEBITS
◆ ONE_HALF
◆ FIX
#define FIX |
( |
|
x | ) |
((int) ((x) * (1 << SCALEBITS) + 0.5)) |
◆ err_if
Value: do { \
if (expr) { \
fprintf(stderr, "%s\n", strerror(errno)); \
exit(1); \
} \
} while (0)
Definition at line 30 of file utils.c.
◆ DEFAULT_WIDTH
#define DEFAULT_WIDTH 352 |
◆ DEFAULT_HEIGHT
#define DEFAULT_HEIGHT 288 |
◆ DEFAULT_NB_PICT
#define DEFAULT_NB_PICT 50 |
◆ rgb24_to_yuv420p()
static void rgb24_to_yuv420p |
( |
unsigned char * |
lum, |
|
|
unsigned char * |
cb, |
|
|
unsigned char * |
cr, |
|
|
const unsigned char * |
src, |
|
|
int |
width, |
|
|
int |
height |
|
) |
| |
|
static |
◆ pgmyuv_save()
static void pgmyuv_save |
( |
const char * |
filename, |
|
|
int |
w, |
|
|
int |
h, |
|
|
const unsigned char * |
rgb_tab |
|
) |
| |
|
static |
◆ put_pixel()
static void put_pixel |
( |
int |
x, |
|
|
int |
y, |
|
|
int |
r, |
|
|
int |
g, |
|
|
int |
b |
|
) |
| |
|
static |
◆ rgb_tab
◆ width
◆ height
◆ wrap