Setting of HALCON system parameters.
The operator ::set_system allows to change different system parameters with relation to the runlength.
Available system parameters:
'neighborhood'
This parameter is used with all procedures which examine
neighborhood relations: ::connection,
::get_region_contour, ::get_region_chain,
::get_region_polygon, ::get_region_thickness,
::boundary,
::paint_region, ::disp_region,
::fill_up, ::contlength.
Value: 4 or 8
default: 8
'default_font'
Whenever a window is opened, a font will be set for the
text output, whereby the 'default_font' will be used.
If the preset font cannot be found, another fontname can
be set before opening the window.
Value: Filename of the fonts
default: Fixed
'image_dir'
Image files (e.g.\ ::read_image and
::read_sequence) will be looked for in the
currently used directory and in 'image_dir' (if no absolute
paths are indicated). More than one directory name
(searchpaths) can be indicated, seperated by semicolons
(Windows NT) or colons (Unix).
The path can also be determined using the environment variable
HALCONIMAGES.
Value: pathname
default: '/usr/local/halcon/images'
'lut_dir'
Color tables (::set_lut) which are realized as an
ASCII-file will be looked for in the currently used directory
and in 'lut_dir' (if no absolute paths are indicated).
If HALCONROOT is set, HALCON\ will search the color tables in
the subdirectory "lut".
Value: pathname
default: '/usr/local/halcon/lut'
'single_lut'
Beschreibung fehlt.
'update_lut'
Beschreibung fehlt.
'reference_dir'
The HTML and postscript sources of the HALCON\ documentation
will be looked for in the currently used directory or in
'reference_dir'.
This system parameter is necessary for example using
the operator ::disp_info.
This parameter can also be set by the environment variable
HALCONROOT before initializing HALCON. In this case the
variable must indicate the directory above the help
directories (that is the HALCON-Homedirectory):
e.g.: '/usr/local/halcon'
Value: pathname
default: '/usr/local/halcon/doc/ps/reference/c'
'help_dir'
The online textfiles {german, english}.hlp, .sta, .key,
.num and .idx will be looked for in the currently used
directory or in 'help_dir'. This system parameter is necessary
for instance using the operators ::get_operator_info and
::get_param_info.
This parameter can also be set by the environment variable
HALCONROOT before initializing HALCON.
In this case the variable must indicate the directory above
the help directories (that is the HALCON-Homedirectory):
e.g.: '/usr/local/halcon'
Value: pathname
default: '/usr/local/halcon/help'
'user_help_dir'
User defined helpfiles will be looked for in this directory.
Their layout must be the same as the layout of the system
immanent helpfiles and they must also be generated from the
.def-file by using the HComp.
This path may also be set by the environment variable
HALCONHELP. If this path has not been set, the helpfiles will
be searched in the directory 'help_dir'. In this case the
filenames must be marked by .user, otherwise this marking is
optional:
{german or english}[.user].hlp, .sta, .key, .num und .idx
'only_lines'
Beschreibung fehlt.
'init_new_image'
Determines whether new images shall be set to 0 before using
filters. This is not necessary if always the whole image is
filtered or if the data of not filtered image areas are
unimportant.
Value: 'true' or 'false'
default: 'true'
'store_empty_region'
Quite a number of operations will lead to the creation
of objects with an empty region (= no imagepoints)
(e.g.\ ::intersection,::threshold, etc.).
This parameter determines whether the object with
an empty region will be returned as a result ('true')
or whether it will be ignored ('false') that is no result
will be returned.
Value: 'true' or 'false'
default: 'true'
'no_object_result'
Determines how operations processing iconic objects shall
react if the object tuplet is empty (= no objects).
Available values for Value:
'true': the error will be ignored
'false': the procedure returns FALSE
'fail': the procedure returns FAIL
'void': the procedure returns VOID
'exception': an exception is raised
default: 'true'
'empty_region_result'
Controls the reaction of procedures concerning input
objects with empty regions which actually are not
useful for such objects (e.g.\ certain region features,
segmentation, etc.).
Available values for Value:
'true': the error will be ignored if possible
'false': the procedure returns FALSE
'fail': the procedure returns FAIL
'void': the procedure returns VOID
'exception': an exception is raised
default: 'true'
'backing_store'
Determines whether the window content will be
refreshed in case of overlapping of the windows. Some
implementations of X Window are faulty; in order to
avoid these errors, the storing of contents can be
deactivated.
It may be recommendable in some cases to deactivate
the security mechanism, if e.g. performance / memory
is what matters.
Value: true or false
default: true
'flush_graphic'
After each HALCON\ procedure which creates a graphic output,
a flush operation will be executed in order to display the
data immediately on screen. This is not necessary with all
programs (e.g.\ if everything is done with the help of the
mouse). In this case 'flush_graphic' can be set to 'false'
to improve the performance.
Value: 'true' or 'false'
default: 'true'
'flush_file'
This parameter determines whether the output into a file
(also to the terminal) shall be buffered or not.
If the output is to be buffered, in general the data will be
displayed on the terminal only after entering the operator
::fnew_line.
Value: 'true' or 'false'
default: 'true'
'compact_obj'
Some host languages like IF/Prolog offer the possibility
to operate image object processing in two different modes.
The first mode implies that an individual key is used
for each object. Thereby the typical tuplets or lists of
image objects are created. The second mode implies that all
objects which result from a whole procedure will be combined
in one common key (which can be recognized from the bigger
numerical values). As in this mode less data has to be
translated into the host language, the performance can hereby
be improved. As object keys and so called compact keys can
be distinguished quite clearly, the modes can be switched
at the runtime of the program. Please note that
switching the mode is not possible in all host languages
(C and OPS5).
Value: 'true' or 'false'
default: 'false'
'x_package'
The output of image data via the network may cause errors
owing to the heavy load on the computer or on the network.
In order to avoid this, the data is
transmitted in small packages. If the computer is used
locally, these units can be enlarged at will. This can
lead to a notably improved output performance.
Value: package size (in bytes)
default: 4096
'int2_bits'
Number of significant bits of int2 images.
This number is used when scaling the gray values.
If the values is -1 the gray values will be
automatically scaled (default).
Value: -1or 9..15
default: -1
'num_gray_4'
Number of the colors to be reserved under X Window to allow
the output of graylevels (::disp_channel) on a machine
with 4 bitplanes (16 colors).
Please note! This value may only be changed before the first
window has been opened on the machine.
Value: 2 - 12
default: 8
'num_gray_6'
Number of the colors to be reserved under X Window to allow
the output of graylevels (::disp_channel) on a machine
with 6 bitplanes (64 colors).
Please note! This value may only be changed before the first
window has been opened on the machine.
Value: 2 - 62
default: 50
'num_gray_8'
Number of the colors to be reserved under X Window to allow
the output of graylevels (::disp_channel) on a machine
with 8 bitplanes (256 colors).
Please note! This value may only be changed before the first
window has been opened on the machine.
Value: 2 - 254
default: 200
'num_gray_percentage'
Under X Window HALCON\ reserves a part of the available
colors for the representation of gray values
(::disp_channel).
This shall interfere with other X applications as little as
possible. However, if HALCON\ does not succeed in reserving
a miminum percentage of 'num_gray_percentage' of the necessary
colors on the X server, a certain amount of the lookup table
will be claimed for the HALCON\ graylevels regardless of the
consequences. This may result in undesired shifts of color
when switching between HALCON\ windows and windows of other
applications, or (outside HALCON) if a window-dump is
generated.
The number of the real graylevels to be reserved depends on
the number of available bitplanes on the outputmachine (see
also 'num_gray_*'. Naturally no colors will be reserved on
monochrome machines - the graylevels will instead be dithered
when displayed. If graylevel-displays are used, only different
shades of gray will be applied ('black', 'white', 'gray',
etc.). Machines with 2 or 3 bitplanes will be
considered monochrome machines, machines with 5 (7) bitplanes
like machines with 4 (6) bitplanes, and machines having more
than 8 bitplanes like machines with 8 bitplanes. A special
case are machines providing a 24 bit display (true color
machines). Naturally no colors are reserved for the display
of graylevels in this case.
Attention: This value may only be changed before the first
window has been opened on the machine. Before opening the
first window on a machine with x bitplanes, num_gray_x
indicates the number of colors which have to be reserved for
the display of graylevels, afterwards, however, it will
indicate the number of colors which actually have been
reserved.
Value: 0 - 100
default: 60
'num_graphic_percentage'
Beschreibung fehlt.
'draw_mode'
Beschreibung fehlt.
'int_zooming'
Beschreibung fehlt.
'ignore_colormap'
Beschreibung fehlt.
'icon_name'
Beschreibung fehlt.
'num_graphic_2'
Number of the graphic colors to be reserved by HALCON\ under
X Window (concerning the operators ::disp_region
etc.) on a machine with 2 bitplanes (4 colors).
Attention: This value may only be changed before the first
window has been opened on the machine.
Values: 0 - 2
default: 2
'num_graphic_4'
Number of the graphic colors to be reserved by HALCON\ under
X Window (concerning the operators ::disp_region
etc.) on a machine with 4 bitplanes (16 colors).
Attention: This value may only be changed before the first
window has been opened on the machine.
Values: 0 - 14
default: 5
'num_graphic_6'
Number of the graphic colors to be reserved by HALCON\ under
X Window (concerning the operators ::disp_region
etc.) on a machine with 6 bitplanes (64 colors).
Attention: This value may only be changed before the first
window has been opened on the machine.
Values: 0 - 62
default: 10
'num_graphic_8'
Number of the graphic colors to be reserved by HALCON\ under
X Window (concerning the operators ::disp_region
etc.) on a machine with 8 bitplanes (256 colors).
Attention: This value may only be changed before the first
window has been opened on the machine.
Values: 0 - 64
default: 20
'graphic_colors'
HALCON\ reserves the first num_graphic_x colors from this
list of color names as graphic colors. As a default
HALCON\ uses the same list which is also returned by using
::query_all_colors.
However, the list can be changed individually: hereby a
tuplet of color names will be returned as value. It is
recommendable that such a tuplet always includes the colors
'black' and 'white', and optionally also 'red', 'green' and
'blue'. If 'default' is set as value, HALCON\ returns to the
initial setting.
Note: On graylevel machines not the first x colors will be
reserved, but the first x shades of gray from the list.
Attention: This value may only be changed before the first
window has been opened on the machine.
Value: Tuplets of X Window color names
default: see also query_all_colors
'last_pixel'
With some graphic processors (255 colors) not all entries of
the color table can be used, as this would lead to a breakdown
of the program (e.g.\ M-Vax 2000). The value 'last_pixel'
indicates the pixel with the highest index
(0..255) that may still be used.
Value: highest index in the color table
default: 253
'current_runlength_number'
Regions will be stored internally in a certain runlength-code.
This parameter can determine the maximum number of chords
which may be used for representing a region.
Please note that some procedures raise the number on their
own if necessary.
The value can be enlarged as well as reduced.
Value: maximum number of chords
default: 20000
'clip_region'
Determines whether the regions of iconic objects of the
HALCON\ database will be clipped to the currently
used image size or not. This is the case for example
in procedures like ::gen_circle,
::gen_rectangle1 or ::dilation1.
See also: ::reset_obj_db
Value: 'true' or 'false'
default: 'true'
'update_lut'
Determines whether the HALCON\ color lookup tables are adapted
according to their environment or not.
Value: 'true' or 'false'
default: 'true'
'do_low_error'
Determines whether the HALCON\ should print low
level error or not.
Value: 'true' or 'false'
default: 'true'
'language'
Beschreibung fehlt.
|
Systemparameter (input_control) |
string(-array) -> HTuple.char * |
| Name of the system parameter to be changed. | |
| Default value: 'image_dir' | |
| List of values: 'neighborhood', 'default_font', 'image_dir', 'lut_dir', 'single_lut', 'update_lut', 'reference_dir', 'help_dir', 'user_help_dir', 'only_lines', 'init_new_image', 'store_empty_region', 'no_object_result', 'empty_region_result', 'backing_store', 'flush_graphic', 'flush_file', 'compact_object', 'x_package', 'int2_bits', 'num_gray_4', 'num_gray_6', 'num_gray_8', 'num_gray_percentage', 'num_graphic_2', 'num_graphic_4', 'num_graphic_6', 'num_graphic_8', 'num_graphic_percentage', 'draw_mode', 'int_zooming', 'ignore_colormap', 'icon_name', 'graphic_colors', 'last_pixel', 'current_runlength_number', 'clip_region', 'update_lut', 'do_low_error', 'language' | |
|
Value (input_control) |
string(-array) -> HTuple.char * / long / double |
| New value of the system parameter. | |
| Default value: 'true' | |
| Suggested values: 'true', 'false', 0, 4, 8, 100, 140, 255 | |
The operator ::set_system returns the value H_MSG_TRUE if the parameters are correct. Otherwise an exception will be raised.
::reset_obj_db, ::get_system, ::set_check
System