Wednesday, October 19, 2005

The GTThresh Utility

The GTThresh utility will be included in the next version of GTData, and it is currently available on request. This tool can be used to automatically set the Maximum Display Thresholds for each filter id in a filter (.flt) file. Previously, this task has always been a manual effort and has also been one of the more neglected tasks when configuring data. Setting the maximum display thresholds is also one of the best ways to improve display performance in GTViewer and even more so in Pocket GTViewer.

The GTThresh utility takes a .GTG and a .FLT file as inputs. It will scan through the .GTG file looking to see the maximum size of each element for each filter id used in the file. It then goes through the .FLT file and adjusts the maximum display threshold values (the zoom level at which the elements using that filter id will be automatically turned off). A sensitivity value is provided to specify how quickly filter ids should be turned off. This value is a little arbitrary, but the default is 5, and it means that as soon as the biggest element is smaller than 5 pixels, that zoom level will be the new threshold. The default value of 5 may be a little conservative, and I have been using 10 for most datasets lately.

The GTThresh utility assumes a few things, such as that all items using the same filter id are generally the same size. If you have all point features and one long line, then the threshold will get set for the largest element (the line) and will not be a good max value. However, this generally is not the case and future version of GTThresh may employ some form of averaging to get around anomalies like this one. For Text elements, only the height is considered so that long text string are not artificially inflating the maximum size when they can not be read anyway from a distance. If a .FLT file has a value already set for the maximum display threshold that is smaller than the computed one, it will not adjust the value. You can also specify a maximum value and if a computed value is greater than the maximum, it will be set to 0 (no maximum).

The GTThresh is not perfect. I still believe that a person can visually do a better job given enough time and effort. However, since so many users are skipping the task of setting the maximum display thresholds altogether and letting their display performance suffer, GTThresh can be a tremendous help to data configuration. If you have already set your maximum display thresholds, it may be of some use to run GTThresh anyway just to see if there were any you have missed.

GTThresh is still a new utility, but testing has shown that it can set maximum display values to a good default and even if you have to adjust them manually, it is much better and easier to tweak a few than to set all of them. This utility has been so successful in its testing, that its functionality is going to be implemented into the GTViewer FME Writer so that it will produce .FLT files that are already set to good defaults.

No comments: