NAME
get_target_region_list - Gets target region list.
SYNOPSIS
#include "seg/seg_connected_components.h"
Example compile flags (system dependent):
-DLINUX_X86_64 -DLINUX_X86_64_OPTERON -DGNU_COMPILER
-I/home/kobus/include
-L/home/kobus/misc/load/linux_x86_64_opteron -L/usr/lib/x86_64-linux-gnu
-lKJB -lfftw3 -lgsl -lgslcblas -ljpeg -lSVM -lstdc++ -lpthread -lSLATEC -lg2c -lacml -lacml_mv -lblas -lg2c -lncursesw
int get_target_region_list
(
KJB_region_list **target_rlpp,
int num_regions
);
DESCRIPTION
This routine implements the creation/over-writing semantics used in the KJB
library in the case of region list. If *target_rlpp is NULL, then this
routine creates the region list. If it is not NULL, and it is the right
size, then this routine does nothing. If it is the wrong size, then it is
resized.
In order to be memory efficient, we free before resizing. If the resizing
fails, then the original contents of the *target_rlpp will be lost.
However,
(*target_rlpp)->regions will be set to NULL, so (*target_rlpp) can be safely
sent to kjb_free(). Note that this is in fact the convention throughout
the KJB library: if destruction on failure is a problem (usually when
*target_rlpp is global) then work on a copy!
DISCLAIMER
This software is not adequatedly tested. It is recomended that
results are checked independantly where appropriate.
AUTHOR
Kobus Barnard
DOCUMENTER
Kobus Barnard
SEE ALSO
free_region_list
,
label_four_connected_regions
,
label_eight_connected_regions