Next: bpipe_matrix_delete, Previous: bpipe_extent_new_va, Up: Utility Functions [Contents]
remove all singleton dimensions
#include <bpipe/bpipe.h> BPMatrix *bpipe_matrix_crunch(BPMatrix *matrix);
BPMatrix *matrix
Not Documented.
This routine returns a copy of the passed matrix with all dimensions of extent one removed. For example, ‘[1][2][1]’ becomes ‘[2]’.
Upon successful completion a pointer to the new matrix is returned.
Upon error bpipe_errno
is set and NULL
is returned.
Upon error bpipe_errno
is set to one of the following errors:
BPENOMEM
a memory allocation failed