Mercurial > hg > wm
diff Meerwald/wang_common.c @ 20:bd669312f068
suppress warnings, fix link errors
author | Peter Meerwald-Stadler <pmeerw@pmeerw.net> |
---|---|
date | Sat, 28 Jan 2023 23:54:58 +0100 |
parents | f83ef905a63d |
children |
line wrap: on
line diff
--- a/Meerwald/wang_common.c Tue Sep 21 13:40:51 2010 +0200 +++ b/Meerwald/wang_common.c Sat Jan 28 23:54:58 2023 +0100 @@ -1,6 +1,9 @@ #include "dwt_util.h" #include "wang_common.h" +Subband_data *subbands; +int n_subbands; + void init_subbands(Image_tree tree) { int levels = 0; int i; @@ -24,7 +27,7 @@ subbands[i++] = alloc_subband(HORIZONTAL, p->horizontal); subbands[i++] = alloc_subband(VERTICAL, p->vertical); subbands[i++] = alloc_subband(DIAGONAL, p->diagonal); - + p = p->coarse; } @@ -44,11 +47,11 @@ p->size = p->height * p->width; p->image = tree->image; p->type = type; - + p->selected = malloc(p->height * sizeof(char *)); p->selected[0] = calloc(p->size, sizeof(char)); for (i = 1; i < p->height; i++) - p->selected[i] = &(p->selected[0][i * p->width]); + p->selected[i] = &(p->selected[0][i * p->width]); return p; }