Go to the documentation of this file.
30 static unsigned int myrnd(
unsigned int *seed_ptr,
int n)
50 #define FRAC_ONE (1 << FRAC_BITS)
78 static unsigned int seed = 1;
82 int r,
g,
b, x, y,
i, dx, dy, x1, y1;
101 for (y = 0; y <
h; y++) {
102 for (x = 0; x <
w; x++) {
114 for (y = 0; y <
NOISE_W; y++) {
115 for (x = 0; x <
NOISE_W; x++) {
127 for (y = 0; y < p->
h; y++) {
128 for (x = 0; x < p->
w; x++) {
146 printf(
"usage: %s file|dir [w=%i] [h=%i]\n"
147 "generate a test video stream\n",
152 int main(
int argc,
char **argv)
158 if (argc < 2 || argc > 4) {
162 if (!freopen(argv[1],
"wb", stdout))
184 snprintf(buf,
sizeof(buf),
"%s%02d.pgm", argv[1],
i);
it s the only field you need to keep assuming you have a context There is some magic you don t need to care about around this just let it vf default minimum maximum flags name is the option name
int main(int argc, char **argv)
static void gen_image(int num, int w, int h)
static unsigned char * rgb_tab
static VObj objs[NB_OBJS]
static void put_pixel(uint16_t *dst, ptrdiff_t linesize, const int16_t *in, int bits_per_raw_sample)
Add bias value, clamp and output pixels of a slice.
static double val(void *priv, double ch)
printf("static const uint8_t my_array[100] = {\n")
The reader does not expect b to be semantically here and if the code is changed by maybe adding a a division or other the signedness will almost certainly be mistaken To avoid this confusion a new type was SUINT is the C unsigned type but it holds a signed int to use the same example SUINT a
static void pgmyuv_save(const char *filename, int w, int h, const unsigned char *rgb_tab)
void print_help(const char *name)
static int int_cos(int a)
static unsigned int myrnd(unsigned int *seed_ptr, int n)