Next: bpipe_matrix_map_expand, Previous: bpipe_matrix_map_delete, Up: Internal Functions
duplicate an existing matrix map structure
#include <bpipe/bpipe.h>BPMatrixMap *bpipe_matrix_map_dup( BPMatrix *src, BPMatrix *dst, BPMatrixMap *src_map, int create_empty );
BPMatrix *src
- source matrix spec
BPMatrix *dst
- destination matrix spec
BPMatrixMap *src_map
- the matrix map to be duplicated
int create_empty
- if non zero, allocate and clear memory for
NULL
map structure entries
this routine creates a new matrix map structure and duplicates all
available data in the passed matrix map. if the flag
create_empty
is non-zero, memory will be allocated and
cleared for the NULL
entries in the source matrix map.
it returns a pointer to the new matrix structure upon success.
if the passed matrix map pointer is NULL
, it returns NULL
.
upon error bpipe_errno
is set and NULL
is returned.
upon error bpipe_errno
is set to one of the following errors:
BPEBADARG
BPENOMEM