6 xrow_t*r = rfx_calloc(sizeof(xrow_t));
8 r->x = rfx_alloc(sizeof(r->x[0])*r->size);
12 void xrow_add(xrow_t*r, int32_t x)
14 if(r->num >= r->size) {
16 r->x = rfx_realloc(r->x, sizeof(r->x[0])*r->size);
21 int compare_int32(const void*_i1,const void*_i2)
23 int32_t*i1 = (int32_t*)_i1;
24 int32_t*i2 = (int32_t*)_i2;
28 void xrow_sort(xrow_t*r)
32 qsort(r->x, r->num, sizeof(r->x[0]), compare_int32);
35 int32_t lastx=r->x[0];
36 for(t=1;t<r->num;t++) {
38 r->x[pos++] = lastx = r->x[t];
44 void xrow_reset(xrow_t*r)
49 void xrow_destroy(xrow_t*r)