The SDL Component Suite is an industry leading collection of components supporting scientific and engineering computing. Please visit the SDL Web site for more information....



OnEstimateZVal


Unit: SDL_rchart
Class: TContourPlot
Declaration: property OnEstimateZVal: TEstimateZValEvent;
TEstimateZValEvent = procedure (Sender: TObject; x, y: double; pivx, pivy: integer; var z: double; var Mask: byte) of object;

The OnEstimateZVal event occurs during the redrawing process when the contour plot component needs to know the z-value at a particular position of the ground plane. The parameters x, y, pivx, and pivy specify the position on the ground plane. Please note, that [x,y] are the coordinates in the coordinate system of the chart, while [pivx,pivy] are the same coordinates in the pivot grid system.

The variable parameter z has to return the altitude at this position. The variable parameter Mask can be used to create a mask which hides the corresponding pixel by drawing a pixel of a predefined color (see MaskPalette). A zero value switches the mask off, all other values select a particular color of the hiding pixel.

Example: This method is used in the following example program (see http://www.lohninger.com/examples.html for downloading the code): contplot



Last Update: 2014-Oct-01