no milestone here
This commit is contained in:
@@ -75,7 +75,9 @@ printf(" pixels@ %p %p %p %p\n",
|
||||
return 0;
|
||||
}
|
||||
/* ---------------------------------------------------------------- */
|
||||
|
||||
/*
|
||||
*
|
||||
*/
|
||||
int fimg_create(FloatImg *fimg, int w, int h, int t)
|
||||
{
|
||||
int surface, size;
|
||||
@@ -146,6 +148,35 @@ if (NULL == fimg->R) {
|
||||
free(fimg->R);
|
||||
memset(fimg, 0, sizeof(FloatImg));
|
||||
|
||||
return 0;
|
||||
}
|
||||
/* --------------------------------------------------------------------- */
|
||||
int fimg_clone(FloatImg *old, FloatImg *new, int flags)
|
||||
{
|
||||
int foo;
|
||||
|
||||
#if DEBUG_LEVEL
|
||||
fprintf(stderr, ">>> %-25s ( %p %p 0x%x)\n", __func__, old, new, flags);
|
||||
#endif
|
||||
|
||||
if ( ! fimg_type_is_valid(old->type) ) {
|
||||
fprintf(stderr, "invalid type %d in %s\n", old->type, __func__);
|
||||
return -2;
|
||||
}
|
||||
|
||||
memset(new, 0, sizeof(FloatImg));
|
||||
|
||||
foo = fimg_create(new, old->width, old->height, old->type);
|
||||
if (foo) {
|
||||
fprintf(stderr, "error %d in %s\n", foo, __func__);
|
||||
return -3;
|
||||
}
|
||||
|
||||
if (flag & 0x01) {
|
||||
/* XXX copy all the pixels's datas */
|
||||
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
/* --------------------------------------------------------------------- */
|
||||
|
||||
6
lib/t.c
6
lib/t.c
@@ -68,9 +68,6 @@ return 0;
|
||||
}
|
||||
/* ---------------------------------------------------------------- */
|
||||
|
||||
int fimg_square_root(FloatImg *s, FloatImg *d, double maxval);
|
||||
int fimg_power_2(FloatImg *s, FloatImg *d, double maxval);
|
||||
|
||||
int essai_contraste(char *fname)
|
||||
{
|
||||
int foo;
|
||||
@@ -113,7 +110,6 @@ while ((opt = getopt(argc, argv, "gn:v")) != -1) {
|
||||
if (verbosity) fimg_print_version(0);
|
||||
|
||||
foo = essai_contraste("src.fimg");
|
||||
|
||||
|
||||
fprintf(stderr, "retour essai contraste -> %d\n",
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user