MF_xyzAutoDensityMap MD_xyzAutoDensityMap ME_xyzAutoDensityMap
MI_xyzAutoDensityMapMBI_xyzAutoDensityMapMSI_xyzAutoDensityMapMLI_xyzAutoDensityMapMQI_xyzAutoDensityMap
MU_xyzAutoDensityMapMUB_xyzAutoDensityMapMUS_xyzAutoDensityMapMUL_xyzAutoDensityMapMUQ_xyzAutoDensityMap
Functiondraw an X-Y coordinate system and plot a color-density map for z = f( x, y ) into it
Syntax C/C++#include <Mgraph.h>
void MF_xyzAutoDensityMap( fVector X, fVector Y, fMatrix Z, ui ht, ui len, COLORREF mincolor, COLORREF maxcolor );
C++ MatObj#include <OptiVec.h>
void matrix<T>::xyzAutoDensityMap( const vector<T>& X, const vector<T>& Y, COLORREF mincolor, COLORREF maxcolor );
Pascal/Delphiuses Mgraph;
procedure MF_xyzAutoDensityMap( X, Y:fVector; MZ:fMatrix; ht, len:UIntSize; mincolor, maxcolor: COLORREF );
DescriptionA Cartesian coordinate system is drawn with automatic scaling of the axes and the matrix MZ is plotted as a color-density map against the vectors X and Y. Prior to calling MF_xyzAutoDensityMap, the plotting routines have to be initialized by V_initPlot.

The font of the axis tick labels is the actual text font of the current device context.

All MZ values will be translated into colors by linear interpolation between the parameters mincolor and maxcolor.
The data type COLORREF is unsigned long. The colors BLACK, BLUE, GREEN, CYAN, RED, MAGENTA, BROWN, LIGHTGRAY, DARKGRAY, LIGHTBLUE, LIGHTGREEN, LIGHTCYAN, LIGHTRED, LIGHTMAGENTA, YELLOW, and WHITE are defined in <Vgraph.h> (or the unit Vgraph) by analogy with the COLORS defined decades ago in the DOS BGI routines of Borland. If you wish to have fine-tuned colors, define them by the RGB macro, instead of using these predefined colors.

If you wish to define the boudaries of the coordinate system differently, instead of relying on the automatic range detection and scaling, you may call first M_setDensityMapBounds or (for preserved automatic scaling, but with arbitrary x and y ranges) MF_findDensityMapBounds. Subsequently, call MF_xyzDataDensityMap instead of MF_xyzAutoDensityMap.

See alsoMF_zAutoDensityMap,   MF_xyzDataDensityMap,   VF_xyAutoPlot,   chapter 15

MatrixLib Table of Contents  OptiVec home