cplot.c

Go to the documentation of this file.
00001 /**
00002 \file    cplot.c
00003 \brief   C functions for 2D plotting directly to a compressed bitmap.
00004 
00005 \author  Glenn D. MacGougan (GDM)
00006 \date    2008-04-18
00007 \since   2007-12-19
00008 
00009 \b "LICENSE INFORMATION" \n
00010 Copyright (c) 2007, refer to 'author' doxygen tags \n
00011 All rights reserved. \n
00012 
00013 Redistribution and use in source and binary forms, with or without
00014 modification, are permitted provided the following conditions are met: \n
00015 
00016 - Redistributions of source code must retain the above copyright
00017   notice, this list of conditions and the following disclaimer. \n
00018 - Redistributions in binary form must reproduce the above copyright
00019   notice, this list of conditions and the following disclaimer in the
00020   documentation and/or other materials provided with the distribution. \n
00021 - The name(s) of the contributor(s) may not be used to endorse or promote 
00022   products derived from this software without specific prior written 
00023   permission. \n
00024 
00025 THIS SOFTWARE IS PROVIDED BY THE CONTRIBUTORS ``AS IS'' AND ANY EXPRESS 
00026 OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED 
00027 WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
00028 DISCLAIMED. IN NO EVENT SHALL THE CONTRIBUTORS BE LIABLE FOR ANY DIRECT,
00029 INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
00030 (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR 
00031 SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER 
00032 CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 
00033 LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 
00034 OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 
00035 SUCH DAMAGE.
00036 */
00037 
00038 #include <stdio.h>  // for FILE*
00039 #include <stdlib.h> // for calloc, malloc, free
00040 #include <string.h> // for strlen, sprintf, strstr, strcmp, and others
00041 #include <ctype.h>  // for isalpha
00042 #include <math.h>
00043 #include <float.h>
00044 #include "cplot.h"
00045 
00046 #if defined _MSC_VER && _MSC_VER < 1400
00047 #define _CRT_SECURE_NO_DEPRECATE
00048 #endif
00049 
00050 #ifndef _MSC_VER
00051 #define _CRT_SECURE_NO_DEPRECATE
00052 #endif
00053 
00054 //#define INTEL_IPPS
00055 
00056 #ifdef INTEL_IPPS // the intel performance primitives acceleration libraries
00057   #include <ippcore.h>    
00058   #include <ipps.h>
00059   #include <ippvm.h>
00060   #include <ippdc.h>
00061   // you must call "ippStaticInit();" before using this class! if IPPS is enabled
00062   // In Windows, for static linking you must include ippcore.lib and ipps.lib
00063   // in your project
00064 #endif
00065 
00066 #define CPLOT_SIZEOF_BITMAPFILEHEADER (14) //!< True size of disk (one byte packing required).
00067 #define CPLOT_SIZEOF_BITMAPINFOHEADER (40) //!< True size of disk (one byte packing required).
00068   
00069 #define CPLOT_RGB_WHITE       { 255, 255, 255, 0 }
00070 #define CPLOT_RGB_BLACK       {   0,   0,   0, 0 }
00071 #define CPLOT_RGB_BLUE        { 255,   0,   0, 0 }
00072 #define CPLOT_RGB_GREEN       {   0, 128,   0, 0 }
00073 #define CPLOT_RGB_CYAN        { 255, 255,   0, 0 }
00074 #define CPLOT_RGB_RED         {   0,   0, 255, 0 }
00075 #define CPLOT_RGB_INDIANRED   {   0,   0, 128, 0 }
00076 #define CPLOT_RGB_YELLOW      {   0, 255, 255, 0 }
00077 #define CPLOT_RGB_LIMEGREEN   {   0, 255,   0, 0 }
00078 #define CPLOT_RGB_DARKBLUE    { 128,  64,   0, 0 }
00079 #define CPLOT_RGB_BABYBLUE    { 255, 128,   0, 0 }
00080 #define CPLOT_RGB_PAISLYBLUE  { 192, 128,   0, 0 }
00081 #define CPLOT_RGB_LIGHTPURPLE { 255,   0, 128, 0 }
00082 #define CPLOT_RGB_PURPLE      { 255,   0, 128, 0 }
00083 #define CPLOT_RGB_DARKPURPLE  { 128,   0,  64, 0 }
00084 #define CPLOT_RGB_PINK        { 255, 128, 255, 0 }
00085 #define CPLOT_RGB_GREYPURPLE  { 192, 128, 128, 0 }
00086 #define CPLOT_RGB_BROWN       {  64,  64, 128, 0 }
00087 #define CPLOT_RGB_GREY        { 128, 128, 128, 0 }
00088 #define CPLOT_RGB_LIGHTGREY   { 192, 192, 192, 0 }
00089 #define CPLOT_RGB_MAGENTA     { 128,   0, 128, 0 }
00090 #define CPLOT_RGB_ORANGE      {   0, 128, 255, 0 }
00091 
00092 #define CPLOT_LARGEFONT        (14)  //!< The width and height of CPLOT's large font.
00093 #define CPLOT_LARGEFONT_NBYTES (196) //!< The number of bytes in a large font letter.
00094 #define CPLOT_SMALLFONT_HGT    (7)  //!< The heigHt of CPLOT's small font.
00095 #define CPLOT_SMALLFONT_WIDTH  (6)  //!< The width of CPLOT's small font.
00096 #define CPLOT_SMALLFONT_NBYTES (42) //!< The number of bytes in a small font letter.
00097 
00098 #define CPLOT_PIXELS_PER_CM    (38) //!< The number of pixels per centimeter.
00099 
00100 #define CPLOT_POINT_SIZE       (5)  //!< The width/height for a point [pixels].
00101 #define CPLOT_LARGEPOINT_SIZE  (8)  //!< The width/height for a large point [pixels].
00102 
00103 #define CPLOT_DEFAULT_PLOT_WIDTH_CM  (15) //!< The default plot width [cm].
00104 #define CPLOT_DEFAULT_PLOT_HEIGHT_CM (13) //!< The default plot height [cm].
00105 
00106 
00107 typedef unsigned char  byte;
00108 
00109 
00110 /*
00111 const CPLOT_structRGB kRGB_White       = CPLOT_RGB_WHITE;
00112 const CPLOT_structRGB kRGB_Black       = CPLOT_RGB_BLACK;
00113 const CPLOT_structRGB kRGB_Blue        = CPLOT_RGB_BLUE;
00114 const CPLOT_structRGB kRGB_Green       = CPLOT_RGB_GREEN;
00115 const CPLOT_structRGB kRGB_Cyan        = CPLOT_RGB_CYAN;
00116 const CPLOT_structRGB kRGB_Red         = CPLOT_RGB_RED;
00117 const CPLOT_structRGB kRGB_IndianRed   = CPLOT_RGB_INDIANRED;
00118 const CPLOT_structRGB kRGB_Yellow      = CPLOT_RGB_YELLOW;
00119 const CPLOT_structRGB kRGB_LimeGreen   = CPLOT_RGB_LIMEGREEN;
00120 const CPLOT_structRGB kRGB_DarkBlue    = CPLOT_RGB_DARKBLUE;
00121 const CPLOT_structRGB kRGB_BabyBlue    = CPLOT_RGB_BABYBLUE;
00122 const CPLOT_structRGB kRGB_PaislyBlue  = CPLOT_RGB_PAISLYBLUE;
00123 const CPLOT_structRGB kRGB_LightPurple = CPLOT_RGB_LIGHTPURPLE;
00124 const CPLOT_structRGB kRGB_Purple      = CPLOT_RGB_PURPLE;
00125 const CPLOT_structRGB kRGB_DarkPurple  = CPLOT_RGB_DARKPURPLE;
00126 const CPLOT_structRGB kRGB_Pink        = CPLOT_RGB_PINK;
00127 const CPLOT_structRGB kRGB_GreyPurple  = CPLOT_RGB_GREYPURPLE;
00128 const CPLOT_structRGB kRGB_Brown       = CPLOT_RGB_BROWN;
00129 const CPLOT_structRGB kRGB_Grey        = CPLOT_RGB_GREY;
00130 const CPLOT_structRGB kRGB_LightGrey   = CPLOT_RGB_LIGHTGREY;
00131 const CPLOT_structRGB kRGB_Magenta     = CPLOT_RGB_MAGENTA;
00132 const CPLOT_structRGB kRGB_Orange      = CPLOT_RGB_ORANGE;
00133 */
00134 
00135 const CPLOT_structColorTable CPLOT_DefaultColorTable = {
00136   CPLOT_RGB_WHITE,
00137   CPLOT_RGB_BLACK,
00138   CPLOT_RGB_BLUE,
00139   CPLOT_RGB_GREEN,
00140   CPLOT_RGB_PURPLE,
00141   CPLOT_RGB_MAGENTA,
00142   CPLOT_RGB_DARKBLUE,
00143   CPLOT_RGB_INDIANRED,
00144   CPLOT_RGB_BABYBLUE,
00145   CPLOT_RGB_PAISLYBLUE,
00146   CPLOT_RGB_LIGHTPURPLE,
00147   CPLOT_RGB_DARKPURPLE,
00148   CPLOT_RGB_GREYPURPLE,
00149   CPLOT_RGB_BROWN,
00150   CPLOT_RGB_RED,
00151   CPLOT_RGB_PINK,
00152   CPLOT_RGB_YELLOW,
00153   CPLOT_RGB_ORANGE,
00154   CPLOT_RGB_CYAN,
00155   CPLOT_RGB_LIMEGREEN,
00156   CPLOT_RGB_GREY,
00157   CPLOT_RGB_LIGHTGREY,
00158 };
00159 
00160 
00161 
00162 
00163 
00164 const byte CPLOT_Point[CPLOT_POINT_SIZE][CPLOT_POINT_SIZE] =
00165  {{ 0,0,1,0,0 },
00166   { 0,1,1,1,0 },
00167   { 1,1,1,1,1 },
00168   { 0,1,1,1,0 },
00169   { 0,0,1,0,0 },};      
00170 
00171 const byte CPLOT_LargePoint[CPLOT_LARGEPOINT_SIZE][CPLOT_LARGEPOINT_SIZE] =
00172  {{ 0,0,1,1,0,0 },
00173   { 0,1,1,1,1,0 },
00174   { 1,1,1,1,1,1 },
00175   { 1,1,1,1,1,1 },
00176   { 0,1,1,1,1,0 },
00177   { 0,0,1,1,0,0 },};
00178 
00179 
00180 const byte CPLOT_LARGEFONT_sigma[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00181 {
00182 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00183 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00184 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00185 { 0,0,0,1,1,1,1,1,1,1,1,1,1,1 },
00186 { 0,0,1,1,1,1,1,1,1,1,1,1,1,1 },
00187 { 0,1,1,1,0,0,0,0,1,1,0,0,0,0 },
00188 { 0,1,1,0,0,0,0,0,0,1,1,0,0,0 },
00189 { 0,1,1,0,0,0,0,0,0,1,1,0,0,0 },
00190 { 0,1,1,0,0,0,0,0,0,1,1,0,0,0 },
00191 { 0,0,1,1,0,0,0,0,1,1,1,0,0,0 },
00192 { 0,0,0,1,1,1,1,1,1,1,0,0,0,0 },
00193 { 0,0,0,0,1,1,1,1,1,0,0,0,0,0 },
00194 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00195 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00196 };
00197 
00198 
00199 const byte CPLOT_LARGEFONT_A[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00200 {
00201 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00202 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00203 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00204 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00205 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00206 { 0,1,1,0,0,0,1,1,0,0,0,0,0,0 },
00207 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00208 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00209 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00210 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00211 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00212 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00213 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00214 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00215 };
00216 
00217 const byte CPLOT_LARGEFONT_B[CPLOT_LARGEFONT][CPLOT_LARGEFONT] =  //11
00218 {
00219 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00220 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 }, 
00221 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00222 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00223 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00224 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 }, 
00225 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00226 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00227 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00228 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 }, 
00229 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00230 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00231 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00232 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00233 };
00234 
00235 
00236 const byte CPLOT_LARGEFONT_C[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00237 {
00238 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00239 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00240 { 0,1,1,0,0,0,1,1,1,0,0,0,0,0 },
00241 { 1,1,0,0,0,0,0,1,0,0,0,0,0,0 },
00242 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00243 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00244 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00245 { 1,1,0,0,0,0,0,1,0,0,0,0,0,0 },
00246 { 0,1,1,0,0,0,1,1,1,0,0,0,0,0 },
00247 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00248 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00249 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00250 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00251 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00252 };
00253 
00254 
00255 const byte CPLOT_LARGEFONT_D[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00256 {
00257 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00258 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 }, 
00259 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 }, 
00260 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00261 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00262 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00263 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00264 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 }, 
00265 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 }, 
00266 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 }, 
00267 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00268 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00269 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00270 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00271 };
00272 
00273 
00274 
00275 const byte CPLOT_LARGEFONT_E[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00276 {
00277 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00278 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00279 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00280 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00281 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00282 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00283 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00284 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00285 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00286 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00287 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00288 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00289 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00290 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00291 };
00292 
00293 
00294 const byte CPLOT_LARGEFONT_F[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00295 {
00296 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00297 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00298 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00299 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00300 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00301 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00302 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00303 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00304 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00305 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00306 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00307 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00308 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00309 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00310 };
00311 
00312 
00313 const byte CPLOT_LARGEFONT_G[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00314 {
00315 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00316 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00317 { 0,1,1,0,0,0,1,1,1,0,0,0,0,0 },
00318 { 1,1,0,0,0,0,0,1,0,0,0,0,0,0 },
00319 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00320 { 1,1,0,0,0,1,1,1,1,0,0,0,0,0 },
00321 { 1,1,0,0,0,1,1,1,1,0,0,0,0,0 },
00322 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00323 { 0,1,1,0,0,0,1,1,1,0,0,0,0,0 },
00324 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00325 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00326 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00327 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00328 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00329 };
00330 
00331 
00332 
00333 const byte CPLOT_LARGEFONT_H[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00334 {
00335 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00336 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00337 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00338 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00339 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00340 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00341 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00342 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00343 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00344 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00345 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00346 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00347 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00348 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00349 };
00350 
00351 
00352 const byte CPLOT_LARGEFONT_I[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //3
00353 {
00354 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00355 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00356 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00357 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00358 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00359 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00360 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00361 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00362 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00363 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00364 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00365 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00366 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00367 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00368 };
00369 
00370 
00371 const byte CPLOT_LARGEFONT_J[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00372 {
00373 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00374 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00375 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00376 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00377 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00378 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00379 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00380 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00381 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00382 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00383 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
00384 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00385 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00386 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00387 };
00388 
00389 
00390 const byte CPLOT_LARGEFONT_K[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00391 {
00392 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00393 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00394 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00395 { 1,1,0,0,1,1,1,0,0,0,0,0,0,0 },
00396 { 1,1,0,1,1,1,1,0,0,0,0,0,0,0 },
00397 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00398 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00399 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00400 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00401 { 1,1,0,0,0,0,1,1,1,0,0,0,0,0 },
00402 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00403 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00404 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00405 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00406 };
00407 
00408 
00409 const byte CPLOT_LARGEFONT_L[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00410 {
00411 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00412 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00413 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00414 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00415 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00416 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00417 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00418 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00419 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00420 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00421 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00422 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00423 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00424 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00425 };
00426 
00427 
00428 const byte CPLOT_LARGEFONT_M[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //13
00429 {
00430 { 1,1,1,0,0,0,0,0,1,1,1,0,0,0 },
00431 { 1,1,1,0,0,0,0,0,1,1,1,0,0,0 },
00432 { 1,1,1,1,0,0,0,1,1,1,1,0,0,0 },
00433 { 1,1,1,1,0,0,0,1,1,1,1,0,0,0 },
00434 { 1,1,0,1,1,0,1,1,0,1,1,0,0,0 },
00435 { 1,1,0,1,1,0,1,1,0,1,1,0,0,0 },
00436 { 1,1,0,1,1,0,1,1,0,1,1,0,0,0 },
00437 { 1,1,0,0,1,1,1,0,0,1,1,0,0,0 },
00438 { 1,1,0,0,1,1,1,0,0,1,1,0,0,0 },
00439 { 1,1,0,0,1,1,1,0,0,1,1,0,0,0 },
00440 { 1,1,0,0,0,1,0,0,0,1,1,0,0,0 },
00441 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00442 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00443 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00444 };
00445 
00446 
00447 const byte CPLOT_LARGEFONT_N[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00448 {
00449 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00450 { 1,1,1,0,0,0,0,1,1,0,0,0,0,0 },
00451 { 1,1,1,1,0,0,0,1,1,0,0,0,0,0 },
00452 { 1,1,1,1,0,0,0,1,1,0,0,0,0,0 },
00453 { 1,1,0,1,1,0,0,1,1,0,0,0,0,0 },
00454 { 1,1,0,1,1,1,0,1,1,0,0,0,0,0 },
00455 { 1,1,0,0,1,1,0,1,1,0,0,0,0,0 },
00456 { 1,1,0,0,0,1,1,1,1,0,0,0,0,0 },
00457 { 1,1,0,0,0,1,1,1,1,0,0,0,0,0 },
00458 { 1,1,0,0,0,0,1,1,1,0,0,0,0,0 },
00459 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00460 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00461 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00462 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00463 };
00464 
00465 
00466 const byte CPLOT_LARGEFONT_O[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //12
00467 {
00468 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00469 { 0,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00470 { 0,1,1,0,0,0,0,1,1,0,0,0,0,0 },
00471 { 1,1,0,0,0,0,0,1,1,1,0,0,0,0 },
00472 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00473 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00474 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00475 { 1,1,0,0,0,0,0,1,1,1,0,0,0,0 },
00476 { 0,1,1,0,0,0,0,1,1,0,0,0,0,0 },
00477 { 0,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00478 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00479 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00480 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00481 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00482 };
00483 
00484 
00485 
00486 const byte CPLOT_LARGEFONT_P[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
00487 {
00488 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00489 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00490 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00491 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00492 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00493 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00494 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00495 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00496 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00497 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00498 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00499 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00500 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00501 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00502 };
00503 
00504 
00505 const byte CPLOT_LARGEFONT_Q[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //12
00506 {
00507 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
00508 { 0,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00509 { 0,1,1,0,0,0,0,1,1,0,0,0,0,0 },
00510 { 1,1,0,0,0,0,0,1,1,1,0,0,0,0 },
00511 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00512 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00513 { 1,1,0,0,0,0,0,0,1,1,0,0,0,0 },
00514 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00515 { 0,1,1,0,0,1,1,1,1,0,0,0,0,0 },
00516 { 0,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00517 { 0,0,0,1,1,1,0,1,1,0,0,0,0,0 },
00518 { 0,0,0,0,0,0,0,0,1,1,0,0,0,0 },   
00519 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00520 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00521 };
00522 
00523 
00524 const byte CPLOT_LARGEFONT_R[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
00525 {
00526 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00527 { 1,1,1,1,1,1,1,1,1,0,0,0,0,0 },
00528 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00529 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00530 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00531 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00532 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00533 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00534 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00535 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00536 { 1,1,0,0,0,0,0,1,1,1,0,0,0,0 },
00537 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00538 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00539 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00540 };
00541 
00542 
00543 const byte CPLOT_LARGEFONT_S[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
00544 {
00545 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00546 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00547 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00548 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00549 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
00550 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00551 { 0,0,0,0,1,1,1,1,0,0,0,0,0,0 },
00552 { 0,0,0,0,0,0,1,1,0,0,0,0,0,0 },
00553 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00554 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00555 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00556 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00557 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00558 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00559 };
00560 
00561 
00562 const byte CPLOT_LARGEFONT_T[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
00563 {
00564 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00565 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00566 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00567 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00568 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00569 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00570 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00571 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00572 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00573 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00574 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00575 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00576 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00577 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00578 };
00579 
00580 
00581 const byte CPLOT_LARGEFONT_U[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
00582 {
00583 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00584 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00585 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00586 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00587 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00588 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00589 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00590 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00591 { 0,1,1,0,0,0,1,1,1,0,0,0,0,0 },
00592 { 0,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00593 { 0,0,1,1,1,1,1,0,0,0,0,0,0,0 },
00594 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00595 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00596 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00597 };
00598 
00599 
00600 const byte CPLOT_LARGEFONT_V[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00601 {
00602 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00603 { 1,1,0,0,0,0,0,1,1,0,0,0,0,0 },
00604 { 0,1,1,0,0,0,1,1,0,0,0,0,0,0 },
00605 { 0,1,1,0,0,0,1,1,0,0,0,0,0,0 },
00606 { 0,1,1,0,0,0,1,1,0,0,0,0,0,0 },
00607 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00608 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00609 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00610 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00611 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00612 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00613 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00614 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00615 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00616 };
00617 
00618 const byte CPLOT_LARGEFONT_W[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //14
00619 {
00620 { 1,1,0,0,0,1,1,1,0,0,0,1,1,0 },
00621 { 1,1,0,0,0,1,1,1,0,0,0,1,1,0 },
00622 { 1,1,1,0,0,1,1,1,0,0,1,1,1,0 },
00623 { 0,1,1,0,1,1,0,1,1,0,1,1,0,0 },
00624 { 0,1,1,0,1,1,0,1,1,0,1,1,0,0 },
00625 { 0,1,1,0,1,1,0,1,1,0,1,1,0,0 },
00626 { 0,1,1,0,1,1,0,1,1,0,1,1,0,0 },
00627 { 0,1,1,0,1,0,0,0,1,0,1,1,0,0 },
00628 { 0,0,1,1,1,0,0,0,1,1,1,0,0,0 },
00629 { 0,0,1,1,1,0,0,0,1,1,1,0,0,0 },
00630 { 0,0,1,1,1,0,0,0,1,1,1,0,0,0 },
00631 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00632 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00633 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00634 };
00635 
00636 
00637 const byte CPLOT_LARGEFONT_X[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
00638 {
00639 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00640 { 1,1,1,0,0,1,1,1,0,0,0,0,0,0 },
00641 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00642 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00643 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00644 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00645 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00646 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00647 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00648 { 1,1,1,0,0,1,1,1,0,0,0,0,0,0 },
00649 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00650 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00651 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00652 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00653 };
00654 
00655 
00656 const byte CPLOT_LARGEFONT_Y[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00657 {
00658 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00659 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
00660 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00661 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00662 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00663 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00664 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00665 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00666 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00667 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00668 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00669 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00670 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00671 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00672 };
00673 
00674 
00675 const byte CPLOT_LARGEFONT_Z[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00676 {
00677 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00678 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00679 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00680 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
00681 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
00682 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
00683 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00684 { 0,1,1,1,0,0,0,0,0,0,0,0,0,0 },
00685 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00686 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00687 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
00688 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00689 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00690 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00691 };
00692 
00693 
00694 const byte CPLOT_LARGEFONT_a[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
00695 {
00696 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00697 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00698 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00699 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
00700 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00701 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
00702 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00703 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
00704 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
00705 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00706 { 0,1,1,1,0,1,1,0,0,0,0,0,0,0 },
00707 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00708 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00709 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00710 };
00711 
00712 const byte CPLOT_LARGEFONT_b[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00713 {
00714 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00715 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00716 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00717 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00718 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00719 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00720 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00721 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00722 { 1,1,0,0,1,1,1,0,0,0,0,0,0,0 },
00723 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00724 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00725 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00726 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00727 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00728 };
00729 
00730 const byte CPLOT_LARGEFONT_c[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00731 {
00732 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00733 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00734 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00735 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00736 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00737 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00738 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00739 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00740 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00741 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00742 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00743 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00744 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00745 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00746 };
00747 
00748 const byte CPLOT_LARGEFONT_d[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00749 {
00750 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00751 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00752 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00753 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00754 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00755 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00756 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00757 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00758 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00759 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00760 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00761 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00762 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00763 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00764 };
00765 
00766 const byte CPLOT_LARGEFONT_e[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00767 {
00768 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00769 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00770 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00771 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00772 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00773 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00774 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00775 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00776 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00777 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00778 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00779 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00780 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00781 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00782 };
00783 
00784 const byte CPLOT_LARGEFONT_f[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //7
00785 {
00786 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
00787 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00788 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00789 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
00790 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
00791 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00792 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00793 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00794 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00795 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00796 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00797 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00798 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00799 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00800 };
00801 
00802 const byte CPLOT_LARGEFONT_g[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00803 {
00804 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00805 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00806 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00807 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00808 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00809 { 1,1,0,0,1,1,1,0,0,0,0,0,0,0 },
00810 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00811 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00812 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00813 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00814 { 0,1,1,1,0,1,1,0,0,0,0,0,0,0 },
00815 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00816 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00817 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00818 };
00819 
00820 
00821 const byte CPLOT_LARGEFONT_h[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00822 {
00823 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00824 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00825 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },   
00826 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00827 { 1,1,0,1,1,1,0,0,0,0,0,0,0,0 },
00828 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00829 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00830 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00831 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00832 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00833 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00834 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00835 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00836 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00837 };
00838 
00839 const byte CPLOT_LARGEFONT_i[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
00840 {
00841 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00842 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00843 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00844 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00845 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00846 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00847 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00848 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00849 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00850 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00851 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00852 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00853 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00854 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00855 };
00856 
00857 const byte CPLOT_LARGEFONT_j[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
00858 {
00859 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00860 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00861 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00862 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00863 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00864 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00865 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00866 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00867 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00868 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00869 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00870 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
00871 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
00872 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
00873 };
00874 
00875 const byte CPLOT_LARGEFONT_k[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
00876 {
00877 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00878 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00879 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00880 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
00881 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00882 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
00883 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
00884 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
00885 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00886 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
00887 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
00888 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00889 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00890 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00891 };
00892 
00893 const byte CPLOT_LARGEFONT_l[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
00894 {
00895 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00896 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00897 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00898 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00899 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00900 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00901 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00902 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00903 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00904 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00905 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00906 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00907 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00908 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00909 };
00910 
00911 
00912 const byte CPLOT_LARGEFONT_m[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //12
00913 {
00914 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00915 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00916 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00917 { 1,1,0,1,1,0,0,1,1,0,0,0,0,0 },
00918 { 1,1,1,1,1,1,1,1,1,1,0,0,0,0 },
00919 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00920 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00921 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00922 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00923 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00924 { 1,1,0,0,1,1,0,0,1,1,0,0,0,0 },
00925 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },   
00926 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },  
00927 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00928 };
00929 
00930 const byte CPLOT_LARGEFONT_n[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00931 {
00932 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00933 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00934 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00935 { 1,1,0,1,1,1,0,0,0,0,0,0,0,0 },
00936 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00937 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
00938 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00939 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00940 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00941 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00942 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00943 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00944 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00945 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00946 };
00947 
00948 
00949 const byte CPLOT_LARGEFONT_o[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00950 {
00951 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00952 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00953 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00954 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
00955 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00956 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00957 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00958 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00959 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00960 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00961 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
00962 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00963 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00964 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00965 };
00966 
00967 const byte CPLOT_LARGEFONT_p[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00968 {
00969 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00970 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00971 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00972 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00973 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00974 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00975 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00976 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00977 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00978 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
00979 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
00980 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00981 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00982 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
00983 };
00984 
00985 const byte CPLOT_LARGEFONT_q[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
00986 {
00987 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00988 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00989 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
00990 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00991 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00992 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00993 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00994 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
00995 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
00996 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
00997 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
00998 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
00999 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01000 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01001 };
01002 
01003 const byte CPLOT_LARGEFONT_r[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01004 {
01005 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01006 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01007 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01008 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
01009 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01010 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01011 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01012 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01013 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01014 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01015 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01016 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01017 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01018 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01019 };
01020 
01021 const byte CPLOT_LARGEFONT_s[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //7
01022 {
01023 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01024 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01025 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01026 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01027 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01028 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01029 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01030 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01031 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01032 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01033 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01034 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01035 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01036 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01037 };
01038 
01039 const byte CPLOT_LARGEFONT_t[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01040 {
01041 { 0,0,1,0,0,0,0,0,0,0,0,0,0,0 },
01042 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01043 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01044 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01045 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01046 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01047 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01048 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01049 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01050 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01051 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01052 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01053 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01054 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01055 };
01056 
01057 
01058 const byte CPLOT_LARGEFONT_u[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01059 {
01060 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01061 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01062 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01063 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01064 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01065 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01066 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01067 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01068 { 1,1,0,0,1,1,1,0,0,0,0,0,0,0 },
01069 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01070 { 0,1,1,1,0,1,1,0,0,0,0,0,0,0 },
01071 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01072 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01073 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01074 };
01075 
01076 const byte CPLOT_LARGEFONT_v[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01077 {
01078 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01079 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01080 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01081 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01082 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01083 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01084 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01085 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01086 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01087 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01088 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01089 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01090 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01091 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01092 };
01093 
01094 const byte CPLOT_LARGEFONT_w[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //12
01095 {
01096 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01097 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01098 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01099 { 1,1,0,0,0,1,0,0,0,1,1,0,0,0 },
01100 { 1,1,0,0,1,1,1,0,0,1,1,0,0,0 },
01101 { 0,1,1,0,1,1,1,0,1,1,0,0,0,0 },
01102 { 0,1,1,0,1,0,1,0,1,1,0,0,0,0 },
01103 { 0,1,1,0,1,0,1,0,1,1,0,0,0,0 },
01104 { 0,0,1,1,1,0,1,1,1,0,0,0,0,0 },
01105 { 0,0,1,1,1,0,1,1,1,0,0,0,0,0 },
01106 { 0,0,1,1,0,0,0,1,1,0,0,0,0,0 },
01107 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },   
01108 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },  
01109 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01110 };
01111 
01112 const byte CPLOT_LARGEFONT_x[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //7
01113 {
01114 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01115 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01116 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01117 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
01118 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
01119 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01120 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01121 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01122 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01123 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
01124 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
01125 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01126 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01127 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01128 };
01129 
01130 const byte CPLOT_LARGEFONT_y[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01131 {
01132 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01133 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01134 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01135 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01136 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01137 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01138 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01139 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01140 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01141 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01142 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01143 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01144 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01145 { 0,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01146 };
01147 
01148 
01149 const byte CPLOT_LARGEFONT_z[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01150 {
01151 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01152 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01153 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01154 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01155 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01156 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01157 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01158 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01159 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01160 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01161 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01162 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01163 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01164 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01165 };
01166 
01167 
01168 const byte CPLOT_LARGEFONT_tilda[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
01169 {
01170 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01171 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01172 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01173 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01174 { 0,1,1,1,0,0,0,1,0,0,0,0,0,0 },
01175 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01176 { 1,0,0,0,1,1,1,0,0,0,0,0,0,0 },
01177 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01178 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01179 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01180 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01181 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01182 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01183 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01184 };
01185 
01186 const byte CPLOT_LARGEFONT_exclamation[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01187 {
01188 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01189 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01190 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01191 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01192 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01193 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01194 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01195 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01196 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01197 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01198 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01199 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01200 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01201 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01202 };
01203 
01204 const byte CPLOT_LARGEFONT_at[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //12
01205 {
01206 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01207 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01208 { 0,0,0,1,1,1,1,1,0,0,0,0,0,0 },
01209 { 0,0,1,1,0,0,0,0,1,1,0,0,0,0 },
01210 { 0,1,0,0,1,1,0,1,1,0,1,0,0,0 },
01211 { 0,1,0,1,1,1,1,1,1,0,1,0,0,0 },
01212 { 1,0,1,1,0,0,0,1,1,0,1,0,0,0 },
01213 { 1,0,1,1,0,0,0,1,1,0,1,0,0,0 },
01214 { 1,0,1,1,0,0,0,1,1,0,1,0,0,0 },
01215 { 1,0,1,1,1,1,1,1,1,1,0,0,0,0 },
01216 { 1,0,0,1,1,0,1,1,1,0,0,0,0,0 },
01217 { 0,1,0,0,0,0,0,0,0,0,1,0,0,0 },
01218 { 0,0,1,0,0,0,0,0,0,1,0,0,0,0 },
01219 { 0,0,0,1,1,1,1,1,1,0,0,0,0,0 },
01220 };
01221 
01222 const byte CPLOT_LARGEFONT_hash[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01223 {
01224 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
01225 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
01226 { 0,0,1,1,0,1,1,0,0,0,0,0,0,0 },
01227 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01228 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01229 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01230 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01231 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01232 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01233 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
01234 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
01235 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01236 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01237 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01238 };
01239 
01240 const byte CPLOT_LARGEFONT_dollarsign[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
01241 {
01242 { 0,0,0,1,0,0,0,0,0,0,0,0,0,0 },
01243 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01244 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01245 { 1,1,0,1,0,1,1,0,0,0,0,0,0,0 },
01246 { 1,1,0,1,0,0,0,0,0,0,0,0,0,0 },
01247 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01248 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01249 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
01250 { 1,1,0,1,0,1,1,0,0,0,0,0,0,0 },
01251 { 1,1,0,1,0,1,1,0,0,0,0,0,0,0 },
01252 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01253 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01254 { 0,0,0,1,0,0,0,0,0,0,0,0,0,0 },
01255 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01256 };
01257 
01258 const byte CPLOT_LARGEFONT_percent[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //14
01259 {
01260 { 0,1,1,1,0,0,0,0,1,1,0,0,0,0 },
01261 { 1,1,0,1,1,0,0,1,1,0,0,0,0,0 },
01262 { 1,1,0,1,1,0,0,1,1,0,0,0,0,0 },
01263 { 1,1,0,1,1,0,1,1,0,0,0,0,0,0 },
01264 { 0,1,1,1,0,0,1,1,0,0,0,0,0,0 },
01265 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01266 { 0,0,0,0,0,1,1,0,1,1,1,0,0,0 },
01267 { 0,0,0,0,1,1,0,1,1,0,1,1,0,0 },
01268 { 0,0,0,0,1,1,0,1,1,0,1,1,0,0 },
01269 { 0,0,0,1,1,0,0,1,1,0,1,1,0,0 },
01270 { 0,0,0,1,1,0,0,0,1,1,1,0,0,0 },
01271 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01272 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01273 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01274 };
01275 
01276 const byte CPLOT_LARGEFONT_raiseto[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
01277 {
01278 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01279 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01280 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01281 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01282 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01283 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
01284 { 1,1,0,0,0,0,1,1,0,0,0,0,0,0 },
01285 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01286 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01287 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01288 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01289 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01290 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01291 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01292 };
01293 
01294 const byte CPLOT_LARGEFONT_andsign[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //11
01295 {
01296 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01297 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01298 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01299 { 0,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01300 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01301 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01302 { 1,1,0,0,1,1,0,1,1,0,0,0,0,0 },
01303 { 1,1,0,0,1,1,1,1,1,0,0,0,0,0 },
01304 { 1,1,0,0,0,1,1,1,1,0,0,0,0,0 },
01305 { 1,1,1,1,1,1,1,1,1,1,0,0,0,0 },
01306 { 0,1,1,1,1,1,0,0,1,0,0,0,0,0 },
01307 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01308 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01309 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01310 };
01311 
01312 const byte CPLOT_LARGEFONT_star[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01313 {
01314 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01315 { 0,0,0,1,0,0,0,0,0,0,0,0,0,0 },
01316 { 0,1,0,1,0,1,0,0,0,0,0,0,0,0 },
01317 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01318 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01319 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01320 { 0,1,0,1,0,1,0,0,0,0,0,0,0,0 },
01321 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01322 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01323 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01324 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01325 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01326 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01327 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01328 };
01329 
01330 const byte CPLOT_LARGEFONT_leftbracket[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01331 {
01332 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01333 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01334 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01335 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01336 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01337 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01338 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01339 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01340 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01341 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01342 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01343 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01344 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01345 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01346 };
01347 
01348 const byte CPLOT_LARGEFONT_rightbracket[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01349 {
01350 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01351 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01352 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01353 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01354 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01355 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01356 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01357 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01358 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01359 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01360 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01361 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01362 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01363 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01364 };
01365 
01366 const byte CPLOT_LARGEFONT_dash[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01367 {
01368 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01369 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01370 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01371 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01372 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01373 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01374 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01375 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01376 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01377 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01378 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01379 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01380 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01381 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01382 };
01383 
01384 const byte CPLOT_LARGEFONT_underscore[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01385 {
01386 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01387 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01388 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01389 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01390 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01391 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01392 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01393 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01394 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01395 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01396 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01397 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01398 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01399 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01400 };
01401 
01402 const byte CPLOT_LARGEFONT_plus[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
01403 {
01404 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01405 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01406 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01407 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01408 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01409 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01410 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01411 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01412 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01413 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01414 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01415 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01416 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01417 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01418 };
01419 
01420 const byte CPLOT_LARGEFONT_equals[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //10
01421 {
01422 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01423 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01424 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01425 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01426 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01427 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01428 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01429 { 1,1,1,1,1,1,1,1,0,0,0,0,0,0 },
01430 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01431 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01432 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01433 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01434 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01435 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01436 };
01437 
01438 const byte CPLOT_LARGEFONT_leftcurly[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01439 {
01440 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01441 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01442 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01443 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01444 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01445 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01446 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01447 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01448 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01449 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01450 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01451 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01452 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01453 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01454 };
01455 
01456 const byte CPLOT_LARGEFONT_rightcurly[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01457 {
01458 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01459 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01460 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01461 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01462 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01463 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01464 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01465 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01466 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01467 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01468 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01469 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01470 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01471 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01472 };
01473 
01474 const byte CPLOT_LARGEFONT_vert[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01475 {
01476 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01477 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01478 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01479 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01480 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01481 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01482 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01483 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01484 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01485 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01486 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01487 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01488 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01489 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01490 };
01491 
01492 const byte CPLOT_LARGEFONT_leftsquare[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01493 {
01494 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01495 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01496 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01497 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01498 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01499 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01500 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01501 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01502 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01503 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01504 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01505 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01506 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01507 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01508 };
01509 
01510 const byte CPLOT_LARGEFONT_rightsquare[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //5
01511 {
01512 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01513 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01514 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01515 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01516 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01517 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01518 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01519 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01520 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01521 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01522 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01523 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01524 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01525 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01526 };
01527 
01528 const byte CPLOT_LARGEFONT_backslash[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01529 {
01530 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01531 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01532 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01533 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01534 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01535 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01536 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01537 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01538 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01539 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01540 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01541 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01542 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01543 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01544 };
01545 
01546 const byte CPLOT_LARGEFONT_forwardslash[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //6
01547 {
01548 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01549 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01550 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01551 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01552 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01553 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01554 { 0,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01555 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01556 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01557 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01558 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01559 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01560 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01561 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01562 };
01563 
01564 const byte CPLOT_LARGEFONT_semicolon[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01565 {
01566 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01567 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01568 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01569 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01570 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01571 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01572 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01573 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01574 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01575 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01576 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01577 { 0,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01578 { 1,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01579 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01580 };
01581 
01582 const byte CPLOT_LARGEFONT_colon[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01583 {
01584 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01585 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01586 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01587 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01588 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01589 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01590 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01591 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01592 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01593 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01594 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01595 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01596 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01597 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01598 };
01599 
01600 const byte CPLOT_LARGEFONT_singlequote[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01601 {
01602 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01603 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01604 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01605 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01606 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01607 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01608 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01609 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01610 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01611 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01612 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01613 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01614 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01615 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01616 };
01617 
01618 const byte CPLOT_LARGEFONT_comma[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01619 {
01620 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01621 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01622 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01623 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01624 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01625 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01626 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01627 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01628 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01629 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01630 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01631 { 0,0,1,0,0,0,0,0,0,0,0,0,0,0 },
01632 { 0,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01633 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01634 };
01635 
01636 const byte CPLOT_LARGEFONT_point[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //4
01637 {
01638 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01639 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01640 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01641 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01642 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01643 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01644 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01645 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01646 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01647 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01648 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01649 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01650 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01651 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01652 };
01653 
01654 
01655 
01656 const byte CPLOT_LARGEFONT_doublequote[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01657 {
01658 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01659 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01660 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01661 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01662 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01663 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01664 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01665 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01666 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01667 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01668 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01669 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01670 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01671 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01672 };
01673 
01674 const byte CPLOT_LARGEFONT_lessthan[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01675 {
01676 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01677 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01678 { 0,0,0,0,0,0,1,0,0,0,0,0,0,0 },
01679 { 0,0,0,0,1,1,1,0,0,0,0,0,0,0 },
01680 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01681 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01682 { 1,1,1,1,0,0,0,0,0,0,0,0,0,0 },
01683 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01684 { 0,0,0,0,1,1,1,0,0,0,0,0,0,0 },
01685 { 0,0,0,0,0,0,1,0,0,0,0,0,0,0 },
01686 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01687 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01688 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01689 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01690 };
01691 
01692 const byte CPLOT_LARGEFONT_morethan[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01693 {
01694 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01695 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01696 { 1,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01697 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01698 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01699 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
01700 { 0,0,0,1,1,1,1,0,0,0,0,0,0,0 },
01701 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01702 { 1,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01703 { 1,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01704 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01705 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01706 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01707 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01708 };
01709 
01710 
01711 const byte CPLOT_LARGEFONT_questionmark[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //9
01712 {
01713 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01714 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01715 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01716 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01717 { 0,0,0,0,1,1,1,0,0,0,0,0,0,0 },
01718 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
01719 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01720 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01721 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01722 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01723 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01724 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01725 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01726 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01727 };
01728 
01729 
01730 
01731 const byte CPLOT_LARGEFONT_One[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //7
01732 {
01733 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01734 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01735 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01736 { 1,1,0,1,1,0,0,0,0,0,0,0,0,0 },
01737 { 1,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01738 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01739 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01740 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01741 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01742 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01743 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01744 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01745 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01746 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01747 };
01748 
01749 const byte CPLOT_LARGEFONT_Two[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01750 {
01751 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01752 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01753 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01754 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01755 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01756 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01757 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01758 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01759 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01760 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01761 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01762 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01763 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01764 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01765 };
01766 
01767 const byte CPLOT_LARGEFONT_Three[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01768 {
01769 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01770 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01771 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01772 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01773 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
01774 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
01775 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01776 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01777 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01778 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01779 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01780 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01781 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01782 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01783 };
01784 
01785 const byte CPLOT_LARGEFONT_Four[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01786 {
01787 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01788 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
01789 { 0,0,0,1,1,1,0,0,0,0,0,0,0,0 },
01790 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01791 { 0,0,1,0,1,1,0,0,0,0,0,0,0,0 },
01792 { 0,1,1,0,1,1,0,0,0,0,0,0,0,0 },
01793 { 1,1,0,0,1,1,0,0,0,0,0,0,0,0 },
01794 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01795 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01796 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01797 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01798 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01799 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01800 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01801 };
01802 
01803 const byte CPLOT_LARGEFONT_Five[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01804 {
01805 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01806 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01807 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01808 { 1,1,1,1,1,0,0,0,0,0,0,0,0,0 },
01809 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01810 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01811 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01812 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01813 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01814 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01815 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01816 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01817 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01818 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01819 };
01820 
01821 const byte CPLOT_LARGEFONT_Six[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01822 {
01823 { 0,0,1,1,1,1,0,0,0,0,0,0,0,0 },
01824 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01825 { 1,1,1,0,0,1,1,0,0,0,0,0,0,0 },
01826 { 1,1,0,0,0,0,0,0,0,0,0,0,0,0 },
01827 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01828 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01829 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01830 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01831 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01832 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01833 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01834 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01835 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01836 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01837 };
01838 
01839 const byte CPLOT_LARGEFONT_Seven[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01840 {
01841 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01842 { 1,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01843 { 0,0,0,0,1,1,0,0,0,0,0,0,0,0 },
01844 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01845 { 0,0,0,1,1,0,0,0,0,0,0,0,0,0 },
01846 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01847 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01848 { 0,0,1,1,0,0,0,0,0,0,0,0,0,0 },
01849 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01850 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01851 { 0,1,1,0,0,0,0,0,0,0,0,0,0,0 },
01852 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01853 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01854 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01855 };
01856 
01857 const byte CPLOT_LARGEFONT_Eight[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01858 {
01859 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01860 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01861 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01862 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01863 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01864 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01865 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01866 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01867 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01868 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01869 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01870 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01871 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01872 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01873 };
01874 
01875 const byte CPLOT_LARGEFONT_Nine[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01876 {
01877 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01878 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01879 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01880 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01881 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01882 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01883 { 0,1,1,1,1,1,1,0,0,0,0,0,0,0 },
01884 { 0,0,0,0,0,1,1,0,0,0,0,0,0,0 },
01885 { 1,1,0,0,1,1,1,0,0,0,0,0,0,0 },
01886 { 1,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01887 { 0,1,1,1,1,0,0,0,0,0,0,0,0,0 },   
01888 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01889 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01890 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01891 };
01892 
01893 const byte CPLOT_LARGEFONT_Zero[CPLOT_LARGEFONT][CPLOT_LARGEFONT] = //8
01894 {
01895 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },
01896 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01897 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
01898 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01899 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01900 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01901 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01902 { 1,1,0,0,0,1,1,0,0,0,0,0,0,0 },
01903 { 1,1,1,0,1,1,1,0,0,0,0,0,0,0 },
01904 { 0,1,1,1,1,1,0,0,0,0,0,0,0,0 },
01905 { 0,0,1,1,1,0,0,0,0,0,0,0,0,0 },   
01906 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01907 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01908 { 0,0,0,0,0,0,0,0,0,0,0,0,0,0 },
01909 };
01910 
01911 
01912 const byte CPLOT_SMALLFONT_A[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01913 {{ 0,0,1,0,0,0 },
01914  { 0,0,1,0,0,0 },
01915  { 0,1,0,1,0,0 },
01916  { 0,1,0,1,0,0 },
01917  { 0,1,1,1,0,0 },
01918  { 1,0,0,0,1,0 },
01919  { 1,0,0,0,1,0 },};
01920 
01921 const byte CPLOT_SMALLFONT_B[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01922 {{ 1,1,1,1,0,0 },
01923  { 1,0,0,0,1,0 },
01924  { 1,0,0,0,1,0 },
01925  { 1,1,1,1,0,0 },
01926  { 1,0,0,0,1,0 },
01927  { 1,0,0,0,1,0 },
01928  { 1,1,1,1,0,0 },};
01929 
01930 const byte CPLOT_SMALLFONT_C[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01931 {{ 0,1,1,1,0,0 },
01932  { 1,0,0,0,1,0 },
01933  { 1,0,0,0,0,0 },
01934  { 1,0,0,0,0,0 },
01935  { 1,0,0,0,0,0 },
01936  { 1,0,0,0,1,0 },
01937  { 0,1,1,1,0,0 },};
01938 
01939 const byte CPLOT_SMALLFONT_D[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01940 {{ 1,1,1,1,0,0 },
01941  { 1,0,0,0,1,0 },
01942  { 1,0,0,0,1,0 },
01943  { 1,0,0,0,1,0 },
01944  { 1,0,0,0,1,0 },
01945  { 1,0,0,0,1,0 },
01946  { 1,1,1,1,0,0 },};
01947 
01948 const byte CPLOT_SMALLFONT_E[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01949 {{ 1,1,1,1,1,0 },
01950  { 1,0,0,0,0,0 },
01951  { 1,0,0,0,0,0 },
01952  { 1,1,1,1,0,0 },
01953  { 1,0,0,0,0,0 },
01954  { 1,0,0,0,0,0 },
01955  { 1,1,1,1,1,0 },};
01956 
01957 const byte CPLOT_SMALLFONT_F[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01958 {{ 1,1,1,1,1,0 },
01959  { 1,0,0,0,0,0 },
01960  { 1,0,0,0,0,0 },
01961  { 1,1,1,1,0,0 },
01962  { 1,0,0,0,0,0 },
01963  { 1,0,0,0,0,0 },
01964  { 1,0,0,0,0,0 },};
01965 
01966 const byte CPLOT_SMALLFONT_G[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01967 {{ 0,1,1,1,0,0 },
01968  { 1,0,0,0,1,0 },
01969  { 1,0,0,0,0,0 },
01970  { 1,0,1,1,1,0 },
01971  { 1,0,0,0,1,0 },
01972  { 1,0,0,0,1,0 },
01973  { 0,1,1,1,0,0 },};
01974 
01975 const byte CPLOT_SMALLFONT_H[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01976 {{ 1,0,0,0,1,0 },
01977  { 1,0,0,0,1,0 },
01978  { 1,0,0,0,1,0 },
01979  { 1,1,1,1,1,0 },
01980  { 1,0,0,0,1,0 },
01981  { 1,0,0,0,1,0 },
01982  { 1,0,0,0,1,0 },};
01983 
01984 
01985 const byte CPLOT_SMALLFONT_I[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01986 {{ 1,1,1,1,1,0 },
01987  { 0,0,1,0,0,0 },
01988  { 0,0,1,0,0,0 },
01989  { 0,0,1,0,0,0 },
01990  { 0,0,1,0,0,0 },
01991  { 0,0,1,0,0,0 },
01992  { 1,1,1,1,1,0 },};
01993 
01994 const byte CPLOT_SMALLFONT_J[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
01995 {{ 0,1,1,1,1,0 },
01996  { 0,0,0,1,0,0 },
01997  { 0,0,0,1,0,0 },
01998  { 0,0,0,1,0,0 },
01999  { 0,0,0,1,0,0 },
02000  { 1,0,0,1,0,0 },
02001  { 0,1,1,0,0,0 },};
02002 
02003 const byte CPLOT_SMALLFONT_K[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02004 {{ 1,0,0,1,0,0 },
02005  { 1,0,0,1,0,0 },
02006  { 1,0,1,0,0,0 },
02007  { 1,1,0,0,0,0 },
02008  { 1,1,0,0,0,0 },
02009  { 1,0,1,0,0,0 },
02010  { 1,0,0,1,0,0 },};
02011 
02012 const byte CPLOT_SMALLFONT_L[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02013 {{ 1,0,0,0,0,0 },
02014  { 1,0,0,0,0,0 },
02015  { 1,0,0,0,0,0 },
02016  { 1,0,0,0,0,0 },
02017  { 1,0,0,0,0,0 },
02018  { 1,0,0,0,0,0 },
02019  { 1,1,1,1,1,0 },};
02020 
02021 const byte CPLOT_SMALLFONT_M[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02022 {{ 1,0,0,0,1,0 },
02023  { 1,1,0,1,1,0 },
02024  { 1,0,1,0,1,0 },
02025  { 1,0,1,0,1,0 },
02026  { 1,0,0,0,1,0 },
02027  { 1,0,0,0,1,0 },
02028  { 1,0,0,0,1,0 },};
02029 
02030 const byte CPLOT_SMALLFONT_N[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02031 {{ 1,0,0,0,1,0 },
02032  { 1,1,0,0,1,0 },
02033  { 1,1,1,0,1,0 },
02034  { 1,0,1,0,1,0 },
02035  { 1,0,0,1,1,0 },
02036  { 1,0,0,1,1,0 },
02037  { 1,0,0,0,1,0 },};
02038 
02039 const byte CPLOT_SMALLFONT_O[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02040 {{ 0,1,1,1,0,0 },
02041  { 1,0,0,0,1,0 },
02042  { 1,0,0,0,1,0 },
02043  { 1,0,0,0,1,0 },
02044  { 1,0,0,0,1,0 },
02045  { 1,0,0,0,1,0 },
02046  { 0,1,1,1,0,0 },};
02047 
02048 const byte CPLOT_SMALLFONT_P[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02049 {{ 1,1,1,1,0,0 },
02050  { 1,0,0,0,1,0 },
02051  { 1,0,0,0,1,0 },
02052  { 1,1,1,1,0,0 },
02053  { 1,0,0,0,0,0 },
02054  { 1,0,0,0,0,0 },
02055  { 1,0,0,0,0,0 },};
02056 
02057 const byte CPLOT_SMALLFONT_Q[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02058 {{ 0,1,1,1,0,0 },
02059  { 1,0,0,0,1,0 },
02060  { 1,0,0,0,1,0 },
02061  { 1,0,0,0,1,0 },
02062  { 1,0,1,0,1,0 },
02063  { 1,0,0,1,0,0 },
02064  { 0,1,1,0,1,0 },};
02065 
02066 const byte CPLOT_SMALLFONT_R[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02067 {{ 1,1,1,0,0,0 },
02068  { 1,0,0,1,0,0 },
02069  { 1,0,0,1,0,0 },
02070  { 1,1,1,0,0,0 },
02071  { 1,0,1,0,0,0 },
02072  { 1,0,0,1,0,0 },
02073  { 1,0,0,1,0,0 },};
02074 
02075 const byte CPLOT_SMALLFONT_S[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02076 {{ 0,1,1,1,0,0 },
02077  { 1,0,0,0,1,0 },
02078  { 1,0,0,0,0,0 },
02079  { 0,1,1,1,0,0 },
02080  { 0,0,0,0,1,0 },
02081  { 1,0,0,0,1,0 },
02082  { 0,1,1,1,0,0 },};
02083 
02084 const byte CPLOT_SMALLFONT_T[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02085 {{ 1,1,1,1,1,0 },
02086  { 0,0,1,0,0,0 },
02087  { 0,0,1,0,0,0 },
02088  { 0,0,1,0,0,0 },
02089  { 0,0,1,0,0,0 },
02090  { 0,0,1,0,0,0 },
02091  { 0,0,1,0,0,0 },};
02092 
02093 const byte CPLOT_SMALLFONT_U[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02094 {{ 1,0,0,0,1,0 },
02095  { 1,0,0,0,1,0 },
02096  { 1,0,0,0,1,0 },
02097  { 1,0,0,0,1,0 },
02098  { 1,0,0,0,1,0 },
02099  { 1,0,0,0,1,0 },
02100  { 0,1,1,1,0,0 },};
02101 
02102 const byte CPLOT_SMALLFONT_V[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02103 {{ 1,0,0,0,1,0 },
02104  { 1,0,0,0,1,0 },
02105  { 1,0,0,0,1,0 },
02106  { 0,1,0,1,0,0 },
02107  { 0,1,0,1,0,0 },
02108  { 0,0,1,0,0,0 },
02109  { 0,0,1,0,0,0 },};
02110 
02111 const byte CPLOT_SMALLFONT_W[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02112 {{ 1,0,0,0,1,0 },
02113  { 1,0,0,0,1,0 },
02114  { 1,0,0,0,1,0 },
02115  { 1,0,1,0,1,0 },
02116  { 1,0,1,0,1,0 },
02117  { 1,0,1,0,1,0 },
02118  { 0,1,0,1,0,0 },};
02119 
02120 const byte CPLOT_SMALLFONT_X[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02121 {{ 1,0,0,0,1,0 },
02122  { 0,1,0,1,0,0 },
02123  { 0,1,0,1,0,0 },
02124  { 0,0,1,0,0,0 },
02125  { 0,1,0,1,0,0 },
02126  { 0,1,0,1,0,0 },
02127  { 1,0,0,0,1,0 },};
02128 
02129 const byte CPLOT_SMALLFONT_Y[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02130 {{ 1,0,0,0,1,0 },
02131  { 0,1,0,1,0,0 },
02132  { 0,1,0,1,0,0 },
02133  { 0,0,1,0,0,0 },
02134  { 0,0,1,0,0,0 },
02135  { 0,0,1,0,0,0 },
02136  { 0,0,1,0,0,0 },};
02137 
02138 const byte CPLOT_SMALLFONT_Z[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02139 {{ 1,1,1,1,1,0 },
02140  { 0,0,0,1,0,0 },
02141  { 0,0,0,1,0,0 },
02142  { 0,0,1,0,0,0 },
02143  { 0,1,0,0,0,0 },
02144  { 0,1,0,0,0,0 },
02145  { 1,1,1,1,1,0 },};
02146 
02147 const byte CPLOT_SMALLFONT_a[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02148 {{ 0,0,0,0,0,0 },
02149  { 0,0,0,0,0,0 },
02150  { 0,1,1,1,1,0 },
02151  { 0,0,0,0,1,0 },
02152  { 0,1,1,1,1,0 },
02153  { 1,0,0,0,1,0 },
02154  { 0,1,1,1,1,0 },};
02155 
02156 const byte CPLOT_SMALLFONT_b[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02157 {{ 1,0,0,0,0,0 },
02158  { 1,0,0,0,0,0 },
02159  { 1,0,0,0,0,0 },
02160  { 1,1,1,1,0,0 },
02161  { 1,0,0,0,1,0 },
02162  { 1,0,0,0,1,0 },
02163  { 1,1,1,1,0,0 },};
02164 
02165 const byte CPLOT_SMALLFONT_c[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02166 {{ 0,0,0,0,0,0 },
02167  { 0,0,0,0,0,0 },
02168  { 0,1,1,1,0,0 },
02169  { 1,0,0,0,1,0 },
02170  { 1,0,0,0,0,0 },
02171  { 1,0,0,0,1,0 },
02172  { 0,1,1,1,0,0 },};
02173 
02174 const byte CPLOT_SMALLFONT_d[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02175 {{ 0,0,0,0,1,0 },
02176  { 0,0,0,0,1,0 },
02177  { 0,0,0,0,1,0 },
02178  { 0,1,1,1,1,0 },
02179  { 1,0,0,0,1,0 },
02180  { 1,0,0,0,1,0 },
02181  { 0,1,1,1,1,0 },};
02182 
02183 const byte CPLOT_SMALLFONT_e[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02184 {{ 0,0,0,0,0,0 },
02185  { 0,0,0,0,0,0 },
02186  { 0,1,1,1,0,0 },
02187  { 1,0,0,0,1,0 },
02188  { 1,1,1,1,0,0 },
02189  { 1,0,0,0,0,0 },
02190  { 0,1,1,1,0,0 },};
02191 
02192 const byte CPLOT_SMALLFONT_f[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02193 {{ 0,0,1,0,0,0 },
02194  { 0,1,0,0,0,0 },
02195  { 0,1,0,0,0,0 },
02196  { 1,1,1,1,0,0 },
02197  { 0,1,0,0,0,0 },
02198  { 0,1,0,0,0,0 },
02199  { 0,1,0,0,0,0 },};
02200 
02201 const byte CPLOT_SMALLFONT_g[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02202 {{ 0,0,0,0,0,0 },
02203  { 0,0,0,0,0,0 },
02204  { 0,0,1,1,1,0 },
02205  { 0,1,0,0,1,0 },
02206  { 0,1,1,1,1,0 },
02207  { 0,0,0,0,1,0 },
02208  { 0,0,1,1,0,0 },};
02209 
02210 const byte CPLOT_SMALLFONT_h[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02211 {{ 1,0,0,0,0,0 },
02212  { 1,0,0,0,0,0 },
02213  { 1,0,0,0,0,0 },
02214  { 1,1,1,1,0,0 },
02215  { 1,0,0,0,1,0 },
02216  { 1,0,0,0,1,0 },
02217  { 1,0,0,0,1,0 },};
02218 
02219 const byte CPLOT_SMALLFONT_i[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02220 {{ 0,0,0,0,0,0 },
02221  { 0,0,1,0,0,0 },
02222  { 0,0,0,0,0,0 },
02223  { 0,0,1,0,0,0 },
02224  { 0,0,1,0,0,0 },
02225  { 0,0,1,0,0,0 },
02226  { 0,0,1,0,0,0 },};
02227 
02228 const byte CPLOT_SMALLFONT_j[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02229 {{ 0,0,0,0,0,0 },
02230  { 0,0,1,0,0,0 },
02231  { 0,0,0,0,0,0 },
02232  { 0,0,1,0,0,0 },
02233  { 0,0,1,0,0,0 },
02234  { 1,0,1,0,0,0 },
02235  { 0,1,0,0,0,0 },};
02236 
02237 const byte CPLOT_SMALLFONT_k[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02238 {{ 0,0,0,0,0,0 },
02239  { 1,0,0,0,0,0 },
02240  { 1,0,0,0,0,0 },
02241  { 1,0,1,0,0,0 },
02242  { 1,1,0,0,0,0 },
02243  { 1,1,0,0,0,0 },
02244  { 1,0,1,1,0,0 },};
02245 
02246 const byte CPLOT_SMALLFONT_l[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02247 {{ 0,0,1,0,0,0 },
02248  { 0,0,1,0,0,0 },
02249  { 0,0,1,0,0,0 },
02250  { 0,0,1,0,0,0 },
02251  { 0,0,1,0,0,0 },
02252  { 0,0,1,0,0,0 },
02253  { 0,0,1,0,0,0 },};
02254 
02255 const byte CPLOT_SMALLFONT_m[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02256 {{ 0,0,0,0,0,0 },
02257  { 0,0,0,0,0,0 },
02258  { 1,1,1,1,0,0 },
02259  { 1,0,1,0,1,0 },
02260  { 1,0,1,0,1,0 },
02261  { 1,0,1,0,1,0 },
02262  { 1,0,1,0,1,0 },};
02263 
02264 const byte CPLOT_SMALLFONT_n[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02265 {{ 0,0,0,0,0,0 },
02266  { 0,0,0,0,0,0 },
02267  { 1,1,1,1,0,0 },
02268  { 1,0,0,0,1,0 },
02269  { 1,0,0,0,1,0 },
02270  { 1,0,0,0,1,0 },
02271  { 1,0,0,0,1,0 },};
02272 
02273 const byte CPLOT_SMALLFONT_o[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02274 {{ 0,0,0,0,0,0 },
02275  { 0,0,0,0,0,0 },
02276  { 0,1,1,1,0,0 },
02277  { 1,0,0,0,1,0 },
02278  { 1,0,0,0,1,0 },
02279  { 1,0,0,0,1,0 },
02280  { 0,1,1,1,0,0 },};
02281 
02282 const byte CPLOT_SMALLFONT_p[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02283 {{ 0,0,0,0,0,0 },
02284  { 1,1,1,0,0,0 },
02285  { 1,0,0,1,0,0 },
02286  { 1,0,0,1,0,0 },
02287  { 1,1,1,0,0,0 },
02288  { 1,0,0,0,0,0 },
02289  { 1,0,0,0,0,0 },};
02290 
02291 const byte CPLOT_SMALLFONT_q[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02292 {{ 0,0,0,0,0,0 },
02293  { 0,0,1,1,1,0 },
02294  { 0,1,0,0,1,0 },
02295  { 0,1,0,0,1,0 },
02296  { 0,0,1,1,1,0 },
02297  { 0,0,0,0,1,0 },
02298  { 0,0,0,0,1,0 },};
02299 
02300 const byte CPLOT_SMALLFONT_r[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02301 {{ 0,0,0,0,0,0 },
02302  { 0,0,0,0,0,0 },
02303  { 1,0,1,1,0,0 },
02304  { 0,1,0,0,0,0 },
02305  { 0,1,0,0,0,0 },
02306  { 0,1,0,0,0,0 },
02307  { 0,1,0,0,0,0 },};
02308 
02309 const byte CPLOT_SMALLFONT_s[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02310 {{ 0,0,0,0,0,0 },
02311  { 0,0,0,0,0,0 },
02312  { 0,0,1,1,1,0 },
02313  { 0,1,0,0,0,0 },
02314  { 0,1,1,1,1,0 },
02315  { 0,0,0,0,1,0 },
02316  { 0,1,1,1,0,0 },};
02317 
02318 const byte CPLOT_SMALLFONT_t[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02319 {{ 0,0,1,0,0,0 },
02320  { 0,0,1,0,0,0 },
02321  { 1,1,1,1,1,0 },
02322  { 0,0,1,0,0,0 },
02323  { 0,0,1,0,0,0 },
02324  { 0,0,1,0,0,0 },
02325  { 0,0,1,0,0,0 },};
02326 
02327 const byte CPLOT_SMALLFONT_u[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02328 {{ 0,0,0,0,0,0 },
02329  { 0,0,0,0,0,0 },
02330  { 1,0,0,0,1,0 },
02331  { 1,0,0,0,1,0 },
02332  { 1,0,0,0,1,0 },
02333  { 1,0,0,0,1,0 },
02334  { 0,1,1,1,0,0 },};
02335 
02336 const byte CPLOT_SMALLFONT_v[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02337 {{ 0,0,0,0,0,0 },
02338  { 0,0,0,0,0,0 },
02339  { 0,0,0,0,0,0 },
02340  { 1,0,0,0,1,0 },
02341  { 1,0,0,0,1,0 },
02342  { 0,1,0,1,0,0 },
02343  { 0,0,1,0,0,0 },};
02344 
02345 const byte CPLOT_SMALLFONT_w[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02346 {{ 0,0,0,0,0,0 },
02347  { 0,0,0,0,0,0 },
02348  { 0,0,0,0,0,0 },
02349  { 1,0,1,0,1,0 },
02350  { 1,0,1,0,1,0 },
02351  { 1,0,1,0,1,0 },
02352  { 0,1,0,1,0,0 },};
02353 
02354 const byte CPLOT_SMALLFONT_x[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02355 {{ 0,0,0,0,0,0 },
02356  { 0,0,0,0,0,0 },
02357  { 1,0,0,0,1,0 },
02358  { 0,1,0,1,0,0 },
02359  { 0,0,1,0,0,0 },
02360  { 0,1,0,1,0,0 },
02361  { 1,0,0,0,1,0 },};
02362 
02363 const byte CPLOT_SMALLFONT_y[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02364 {{ 0,0,0,0,0,0 },
02365  { 0,0,0,0,0,0 },
02366  { 1,0,0,0,1,0 },
02367  { 0,1,0,1,0,0 },
02368  { 0,0,1,0,0,0 },
02369  { 0,1,0,0,0,0 },
02370  { 1,0,0,0,0,0 },};
02371 
02372 const byte CPLOT_SMALLFONT_z[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02373 {{ 0,0,0,0,0,0 },
02374  { 0,0,0,0,0,0 },
02375  { 0,0,0,0,0,0 },
02376  { 1,1,1,1,0,0 },
02377  { 0,0,1,0,0,0 },
02378  { 0,1,0,0,0,0 },
02379  { 1,1,1,1,1,0 },};
02380 
02381 const byte CPLOT_SMALLFONT_colon[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02382 {{ 0,0,0,0,0,0 },
02383  { 0,0,1,1,0,0 },
02384  { 0,0,1,1,0,0 },
02385  { 0,0,0,0,0,0 },
02386  { 0,0,0,0,0,0 },
02387  { 0,0,1,1,0,0 },
02388  { 0,0,1,1,0,0 },};
02389 
02390 const byte CPLOT_SMALLFONT_backslash[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02391 {{ 1,0,0,0,0,0 },
02392  { 0,1,0,0,0,0 },
02393  { 0,0,1,0,0,0 },
02394  { 0,0,1,0,0,0 },
02395  { 0,0,0,1,0,0 },
02396  { 0,0,0,0,1,0 },
02397  { 0,0,0,0,0,1 },};
02398 
02399 const byte CPLOT_SMALLFONT_forwardslash[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02400 {{ 0,0,0,0,0,1 },
02401  { 0,0,0,0,1,0 },
02402  { 0,0,0,1,0,0 },
02403  { 0,0,1,0,0,0 },
02404  { 0,1,1,0,0,0 },
02405  { 0,1,0,0,0,0 },
02406  { 1,0,0,0,0,0 },};
02407 
02408 const byte CPLOT_SMALLFONT_percent[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02409 {{ 0,0,0,0,0,0 },
02410  { 1,1,0,0,1,0 },
02411  { 1,1,0,0,1,0 },
02412  { 0,0,0,1,0,0 },
02413  { 0,0,1,0,0,0 },
02414  { 0,1,0,1,1,0 },
02415  { 1,0,0,1,1,0 },};
02416 
02417 const byte CPLOT_SMALLFONT_raiseto[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02418 {{ 0,0,1,0,0,0 },
02419  { 0,1,0,1,0,0 },
02420  { 1,0,0,0,1,0 },
02421  { 0,0,0,0,0,0 },
02422  { 0,0,0,0,0,0 },
02423  { 0,0,0,0,0,0 },
02424  { 0,0,0,0,0,0 },};
02425 
02426 const byte CPLOT_SMALLFONT_dollarsign[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02427 {{ 0,1,1,1,0,0 },
02428  { 1,0,1,0,1,0 },
02429  { 1,0,1,0,0,0 },
02430  { 0,1,1,1,0,0 },
02431  { 0,0,1,0,1,0 },
02432  { 1,0,1,0,1,0 },
02433  { 0,1,1,1,0,0 },};
02434 
02435 const byte CPLOT_SMALLFONT_andsign[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02436 {{ 0,1,1,0,0,0 },
02437  { 1,0,0,1,0,0 },
02438  { 1,0,0,1,0,0 },
02439  { 0,1,1,0,0,0 },
02440  { 1,0,1,0,1,0 },
02441  { 1,0,0,1,0,0 },
02442  { 0,1,1,0,1,0 },};
02443 
02444 const byte CPLOT_SMALLFONT_star[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02445 {{ 0,0,0,0,0,0 },
02446  { 1,0,1,0,1,0 },
02447  { 0,1,1,1,0,0 },
02448  { 0,0,1,0,0,0 },
02449  { 0,1,0,1,0,0 },
02450  { 1,0,0,0,1,0 },
02451  { 0,0,0,0,0,0 },};
02452 
02453 const byte CPLOT_SMALLFONT_leftbracket[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02454 {{ 0,0,1,0,0,0 },
02455  { 0,1,0,0,0,0 },
02456  { 1,0,0,0,0,0 },
02457  { 1,0,0,0,0,0 },
02458  { 1,0,0,0,0,0 },
02459  { 0,1,0,0,0,0 },
02460  { 0,0,1,0,0,0 },};
02461 
02462 const byte CPLOT_SMALLFONT_rightbracket[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02463 {{ 0,0,1,0,0,0 },
02464  { 0,0,0,1,0,0 },
02465  { 0,0,0,0,1,0 },
02466  { 0,0,0,0,1,0 },
02467  { 0,0,0,0,1,0 },
02468  { 0,0,0,1,0,0 },
02469  { 0,0,1,0,0,0 },};
02470 
02471 const byte CPLOT_SMALLFONT_leftsquare[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02472 {{ 1,1,1,0,0,0 },
02473  { 1,0,0,0,0,0 },
02474  { 1,0,0,0,0,0 },
02475  { 1,0,0,0,0,0 },
02476  { 1,0,0,0,0,0 },
02477  { 1,0,0,0,0,0 },
02478  { 1,1,1,0,0,0 },};
02479 
02480 const byte CPLOT_SMALLFONT_rightsquare[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02481 {{ 0,0,1,1,1,0 },
02482  { 0,0,0,0,1,0 },
02483  { 0,0,0,0,1,0 },
02484  { 0,0,0,0,1,0 },
02485  { 0,0,0,0,1,0 },
02486  { 0,0,0,0,1,0 },
02487  { 0,0,1,1,1,0 },};
02488 
02489 const byte CPLOT_SMALLFONT_dash[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02490 {{ 0,0,0,0,0,0 },
02491  { 0,0,0,0,0,0 },
02492  { 0,0,0,0,0,0 },
02493  { 1,1,1,1,1,0 },
02494  { 0,0,0,0,0,0 },
02495  { 0,0,0,0,0,0 },
02496  { 0,0,0,0,0,0 },};
02497 
02498 const byte CPLOT_SMALLFONT_equals[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02499 {{ 0,0,0,0,0,0 },
02500  { 0,0,0,0,0,0 },
02501  { 1,1,1,1,1,0 },
02502  { 0,0,0,0,0,0 },
02503  { 0,0,0,0,0,0 },
02504  { 1,1,1,1,1,0 },
02505  { 0,0,0,0,0,0 },};
02506 
02507 const byte CPLOT_SMALLFONT_plus[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02508 {{ 0,0,1,0,0,0 },
02509  { 0,0,1,0,0,0 },
02510  { 0,0,1,0,0,0 },
02511  { 1,1,1,1,1,0 },
02512  { 0,0,1,0,0,0 },
02513  { 0,0,1,0,0,0 },
02514  { 0,0,1,0,0,0 },};
02515 
02516 const byte CPLOT_SMALLFONT_semicolon[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =   
02517 {{ 0,0,0,0,0,0 },
02518  { 0,1,1,0,0,0 },
02519  { 0,1,1,0,0,0 },
02520  { 0,0,0,0,0,0 },
02521  { 0,0,1,0,0,0 },
02522  { 0,1,0,0,0,0 },
02523  { 1,0,0,0,0,0 },};
02524 
02525 const byte CPLOT_SMALLFONT_singlequote[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02526 {{ 0,0,1,0,0,0 },
02527  { 0,0,1,0,0,0 },
02528  { 0,0,1,0,0,0 },
02529  { 0,0,0,0,0,0 },
02530  { 0,0,0,0,0,0 },
02531  { 0,0,0,0,0,0 },
02532  { 0,0,0,0,0,0 },};
02533 
02534 const byte CPLOT_SMALLFONT_doublequote[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02535 {{ 0,1,0,1,0,0 },
02536  { 0,1,0,1,0,0 },
02537  { 0,1,0,1,0,0 },
02538  { 0,0,0,0,0,0 },
02539  { 0,0,0,0,0,0 },
02540 
02541  { 0,0,0,0,0,0 },
02542  { 0,0,0,0,0,0 },};
02543 
02544 const byte CPLOT_SMALLFONT_lessthan[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02545 {{ 0,0,0,0,1,0 },
02546  { 0,0,0,1,0,0 },
02547  { 0,0,1,0,0,0 },
02548  { 0,1,0,0,0,0 },
02549  { 0,0,1,0,0,0 },
02550  { 0,0,0,1,0,0 },
02551  { 0,0,0,0,1,0 },};
02552 
02553 const byte CPLOT_SMALLFONT_morethan[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02554 {{ 1,0,0,0,0,0 },
02555  { 0,1,0,0,0,0 },
02556  { 0,0,1,0,0,0 },
02557  { 0,0,0,1,0,0 },
02558  { 0,0,1,0,0,0 },
02559  { 0,1,0,0,0,0 },
02560  { 1,0,0,0,0,0 },};
02561 
02562 const byte CPLOT_SMALLFONT_comma[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02563 {{ 0,0,0,0,0,0 },
02564  { 0,0,0,0,0,0 },
02565  { 0,0,0,0,0,0 },
02566  { 0,0,0,0,0,0 },
02567  { 0,0,1,0,0,0 },
02568  { 0,1,0,0,0,0 },
02569  { 1,0,0,0,0,0 },};
02570 
02571 const byte CPLOT_SMALLFONT_point[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02572 {{ 0,0,0,0,0,0 },
02573  { 0,0,0,0,0,0 },
02574  { 0,0,0,0,0,0 },
02575  { 0,0,0,0,0,0 },
02576  { 0,0,0,0,0,0 },
02577  { 0,0,1,1,0,0 },
02578  { 0,0,1,1,0,0 },};
02579 
02580 const byte CPLOT_SMALLFONT_exclamation[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02581 {{ 0,0,1,1,0,0 },
02582  { 0,0,1,1,0,0 },
02583  { 0,0,1,1,0,0 },
02584  { 0,0,1,1,0,0 },
02585  { 0,0,0,0,0,0 },
02586  { 0,0,1,1,0,0 },
02587  { 0,0,1,1,0,0 },};
02588 
02589 
02590 const byte CPLOT_SMALLFONT_vert[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02591 {{ 0,0,1,0,0,0 },
02592  { 0,0,1,0,0,0 },
02593  { 0,0,1,0,0,0 },
02594  { 0,0,1,0,0,0 },
02595  { 0,0,1,0,0,0 },
02596  { 0,0,1,0,0,0 },
02597  { 0,0,1,0,0,0 },};
02598 
02599 const byte CPLOT_SMALLFONT_tilda[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02600 {{ 0,0,0,0,0,0 },
02601  { 0,0,0,0,0,0 },
02602  { 0,1,1,0,0,0 },
02603  { 1,0,1,0,1,0 },
02604  { 0,0,0,1,1,0 },
02605  { 0,0,0,0,0,0 },
02606  { 0,0,0,0,0,0 },};
02607 
02608 
02609 const byte CPLOT_SMALLFONT_Zero[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02610 {{ 0,1,1,1,0,0 },
02611 { 1,0,0,0,1,0 },
02612 { 1,0,0,1,1,0 },
02613 { 1,0,1,0,1,0 },
02614 { 1,1,0,0,1,0 },
02615 { 1,0,0,0,1,0 },
02616 { 0,1,1,1,0,0 }};
02617 
02618 const byte CPLOT_SMALLFONT_One[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02619 {{ 0,0,1,0,0,0 },
02620 { 0,1,1,0,0,0 },
02621 { 0,0,1,0,0,0 },
02622 { 0,0,1,0,0,0 },
02623 { 0,0,1,0,0,0 },
02624 { 0,0,1,0,0,0 },
02625 { 0,1,1,1,0,0 }};
02626 
02627 const byte CPLOT_SMALLFONT_Two[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02628 {{ 0,1,1,1,0,0 },
02629 { 1,0,0,0,1,0 },
02630 { 0,0,0,0,1,0 },
02631 { 0,0,0,1,0,0 },
02632 { 0,0,1,0,0,0 },
02633 { 0,1,0,0,0,0 },
02634 { 1,1,1,1,1,0 }};
02635 
02636 const byte CPLOT_SMALLFONT_Three[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02637 {{ 1,1,1,1,1,0 },
02638 { 0,0,0,1,0,0 },
02639 { 0,0,1,0,0,0 },
02640 { 0,0,0,1,0,0 },
02641 { 0,0,0,0,1,0 },
02642 { 1,0,0,0,1,0 },
02643 { 0,1,1,1,0,0 }};
02644 
02645 const byte CPLOT_SMALLFONT_Four[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02646 {{ 0,0,0,1,0,0 },
02647 { 0,0,1,1,0,0 },
02648 { 0,1,0,1,0,0 },
02649 { 1,0,0,1,0,0 },
02650 { 1,1,1,1,1,0 },
02651 { 0,0,0,1,0,0 },
02652 { 0,0,0,1,0,0 }};
02653 
02654 const byte CPLOT_SMALLFONT_Five[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02655 {{ 1,1,1,1,1,0 },
02656 { 1,0,0,0,0,0 },
02657 { 1,1,1,1,0,0 },
02658 { 0,0,0,0,1,0 },
02659 { 0,0,0,0,1,0 },
02660 { 1,0,0,0,1,0 },
02661 { 0,1,1,1,0,0 }};
02662 
02663 const byte CPLOT_SMALLFONT_Six[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] = 
02664 {{ 0,0,1,1,0,0 },
02665 { 0,1,0,0,0,0 },
02666 { 1,0,0,0,0,0 },
02667 { 1,1,1,1,0,0 },
02668 { 1,0,0,0,1,0 },
02669 { 1,0,0,0,1,0 },
02670 { 0,1,1,1,0,0 }};
02671 
02672 const byte CPLOT_SMALLFONT_Seven[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02673 {{ 1,1,1,1,1,0 },
02674 { 0,0,0,0,1,0 },
02675 { 0,0,0,1,0,0 },
02676 { 0,0,1,0,0,0 },
02677 { 0,0,1,0,0,0 },
02678 { 0,0,1,0,0,0 },
02679 { 0,0,1,0,0,0 }};
02680 
02681 const byte CPLOT_SMALLFONT_Eight[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02682 {{ 0,1,1,1,0,0 },
02683 { 1,0,0,0,1,0 },
02684 { 1,0,0,0,1,0 },
02685 { 0,1,1,1,0,0 },
02686 { 1,0,0,0,1,0 },
02687 { 1,0,0,0,1,0 },
02688 { 0,1,1,1,0,0 }};
02689 
02690 const byte CPLOT_SMALLFONT_Nine[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH] =
02691 {{ 0,1,1,1,0,0 },
02692 { 1,0,0,0,1,0 },
02693 { 1,0,0,0,1,0 },
02694 { 0,1,1,1,1,0 },
02695 { 0,0,0,0,1,0 },
02696 { 0,0,0,1,0,0 },
02697 { 0,1,1,0,0,0 }};
02698 
02699 
02700 
02701 
02702 BOOL CPLOT_BYTE_MTX_Init( CPLOT_structByteMatrix *M )
02703 {
02704   if( !M )
02705     return FALSE;
02706 
02707   M->ncols = 0;
02708   M->nrows = 0;
02709   M->data = NULL;
02710   
02711   return TRUE;
02712 }
02713 
02714 BOOL CPLOT_BYTE_MTX_isNull( const CPLOT_structByteMatrix *M )
02715 {
02716   if( !M )
02717     return TRUE;
02718 
02719   if( M->data == NULL )
02720     return TRUE;
02721 
02722   return FALSE;
02723 }
02724 
02725 /// zero the entire matrix
02726 BOOL CPLOT_BYTE_MTX_Zero( CPLOT_structByteMatrix *dst )
02727 {
02728   unsigned i = 0;  
02729   
02730   if( CPLOT_BYTE_MTX_isNull( dst ) )  
02731     return FALSE;
02732 
02733   for( i = 0; i < dst->nrows; i++ )
02734   {    
02735 #ifdef INTEL_IPPS    
02736     if( ippsZero_8u( (Ipp8u*)(dst->data[i]), dst->ncols ) != ippStsNoErr )
02737       return FALSE;
02738 #else
02739     memset( &(dst->data[i]), 0, dst->ncols );
02740 #endif
02741   }
02742   return TRUE;
02743 }
02744 
02745 BOOL CPLOT_BYTE_MTX_Free( CPLOT_structByteMatrix *M )
02746 {
02747   unsigned i = 0;
02748 
02749   if( !M )
02750     return FALSE;
02751 
02752   if( M->data == NULL )  
02753   {
02754     M->nrows = 0;
02755     M->ncols = 0;
02756     return TRUE;
02757   } 
02758 
02759   // free the data
02760   for( i = 0; i < M->nrows; i++ )
02761   {
02762 #ifdef INTEL_IPPS
02763     ippsFree( M->data[i] );
02764 #else
02765     free( M->data[i] );
02766 #endif
02767   }
02768 
02769   // free the array of pointers
02770   free( M->data );
02771   
02772   M->nrows = 0;
02773   M->ncols = 0;   
02774   M->data = NULL;
02775   
02776   return TRUE;
02777 }
02778 
02779 
02780 BOOL CPLOT_BYTE_MTX_calloc( CPLOT_structByteMatrix *M, const unsigned nrows, const unsigned ncols )
02781 { 
02782   unsigned i = 0;
02783   
02784   // invalid call
02785   if( nrows == 0 || ncols == 0 ) 
02786     return FALSE;   
02787   if( !M )
02788     return FALSE;
02789 
02790   // Check if the matrix is already the right size and type.
02791   if( M->nrows > 0 && M->ncols > 0 )
02792   {
02793     if( M->nrows == nrows && M->ncols == ncols )
02794     {
02795       // already the right size and type
02796       if( !CPLOT_BYTE_MTX_Zero( M ) )
02797         return FALSE;
02798 
02799       return TRUE;
02800     }
02801   }
02802   
02803   // check if we still need to deallocate memory
02804   if( M->data != NULL )
02805   {
02806     // free the data
02807     if( !CPLOT_BYTE_MTX_Free( M ) )
02808       return FALSE;
02809   }
02810 
02811   M->nrows = 0;
02812   M->ncols = ncols;
02813 
02814   // allocate the column array
02815   M->data = (byte**)malloc( nrows*sizeof(byte*) );
02816   if( !M->data )
02817     return FALSE;
02818   
02819   // for each column allocate the rows
02820   for( i = 0; i < nrows; i++ )
02821   {
02822 #ifdef INTEL_IPPS  
02823     M->data[i] = ippsMalloc_8u( ncols );
02824     if( !(M->data[i]) )
02825     {
02826       // this is most likely to occur if allocating more memory than available
02827       CPLOT_BYTE_MTX_Free( M );
02828       return FALSE;
02829     }
02830     if( ippsZero_8u( (Ipp8u*)(M->data[i]), ncols ) != ippStsNoErr )
02831       return FALSE;
02832 #else
02833     M->data[i] = (byte*)calloc( ncols, sizeof(byte) );    
02834     if( !M->data[i] )
02835     {
02836       // this is most likely to occur if allocating more memory than available
02837       CPLOT_BYTE_MTX_Free( M );
02838       return FALSE;
02839     }
02840 #endif
02841     M->nrows++;
02842   }      
02843 
02844   return TRUE; 
02845 }
02846 
02847 /// fills the matrix with the given value
02848 BOOL CPLOT_BYTE_MTX_Fill( CPLOT_structByteMatrix *dst, const byte value )
02849 {
02850   unsigned i = 0;
02851   
02852   if( CPLOT_BYTE_MTX_isNull( dst ) )
02853     return FALSE;
02854 
02855   for( i = 0; i < dst->nrows; i++ )
02856   {
02857 #ifdef INTEL_IPPS        
02858     if( ippsSet_8u( (Ipp8u)(value), (Ipp8u*)(dst->data[i]), dst->ncols ) != ippStsNoErr )
02859       return FALSE;
02860 #else
02861     memset( dst->data[i], value, dst->ncols );
02862 #endif
02863   }
02864   return TRUE;
02865 }
02866 
02867 BOOL CPLOT_PlotOptionsInit( CPLOT_structPlotOptions *Opt )
02868 {
02869   if( !Opt )
02870     return FALSE;
02871   memset( Opt, 0, sizeof(CPLOT_structPlotOptions) );
02872   Opt->y_label_right_scale_factor = 1.0;
02873   Opt->RightYLabelColor = CPLOT_BLACK;
02874   Opt->numberOfSeries = 1;
02875   Opt->plotLabelOnRight = TRUE;
02876   Opt->endOfWarmupEpoch = -DBL_MAX;    
02877   Opt->PlotSize_Width_cm  = CPLOT_DEFAULT_PLOT_WIDTH_CM;  // cm
02878   Opt->PlotSize_Height_cm = CPLOT_DEFAULT_PLOT_HEIGHT_CM; // cm
02879   return TRUE;
02880 }
02881 
02882 BOOL CPLOT_Init( CPLOT* P )
02883 {
02884   int rem = 0;
02885   if( !P )
02886     return FALSE;
02887 
02888   P->mIsAxesDrawn  = FALSE;
02889   P->mSeriesIndex = 0;
02890   P->mFootNoteIndex = 0;
02891 
02892   P->mStatsValueHeight     = 15;
02893   P->mYLabelAllowance      = 106;
02894   P->mRightYLabelAllowance = 80;
02895   P->mTitleAllowance       = 50;
02896   P->mXLabelAllowance      = 56;
02897   
02898   P->mImage.Height = CPLOT_DEFAULT_PLOT_HEIGHT_CM * CPLOT_PIXELS_PER_CM;
02899   P->mImage.Width  = CPLOT_DEFAULT_PLOT_WIDTH_CM  * CPLOT_PIXELS_PER_CM;
02900 
02901   // The width must be evely divisible by four
02902   rem = P->mImage.Width%4;
02903   P->mImage.Width += rem;
02904 
02905 
02906   P->mAxes.StartX  = 100;
02907   P->mAxes.StartY  = 40;
02908   P->mAxes.FinishX = 530;
02909   P->mAxes.FinishY = 440;
02910   P->mAxes.Width  = P->mAxes.FinishX - P->mAxes.StartX;
02911   P->mAxes.Height = P->mAxes.FinishY - P->mAxes.StartY; 
02912   P->mAxes.TickDashInPixels = 4;
02913 
02914   // pointer to special color table if any
02915   P->mColorTable = NULL;
02916 
02917   // this is the default color order
02918   P->mDefaultColorTable = CPLOT_DefaultColorTable;
02919 
02920   P->mData.xtickstart = 0.0;
02921   P->mData.xtickend = 0.0;
02922   P->mData.xticksize = 0.0;
02923   P->mData.ytickstart = 0.0;
02924   P->mData.ytickend = 0.0;
02925   P->mData.yticksize = 0.0;
02926   P->mData.RangeX = 0.0;
02927   P->mData.RangeY = 0.0;
02928   P->mData.OnePercentRangeX = 0.0;
02929   P->mData.OnePercentRangeY = 0.0;
02930   P->mData.ScaleX = 0.0;
02931   P->mData.ScaleY = 0.0;
02932   P->mData.MinX = 0.0;
02933   P->mData.MaxX = 0.0;
02934   P->mData.MinY = 0.0;
02935   P->mData.MaxY = 0.0;
02936 
02937   P->mLabelWidth = 80; //kSmallFontWidth*mStatsValueHeight;  80*8/32 must be evely divisible
02938 
02939   memset( &(P->mOptions), 0, sizeof(CPLOT_structPlotOptions) );
02940   P->mOptions.y_label_right_scale_factor = 1.0;
02941   P->mOptions.RightYLabelColor = CPLOT_BLACK;
02942   P->mOptions.numberOfSeries = 1;
02943   P->mOptions.plotLabelOnRight = TRUE;
02944   P->mOptions.endOfWarmupEpoch = -DBL_MAX;
02945   P->mOptions.PlotSize_Width_cm = 19;  // cm
02946   P->mOptions.PlotSize_Height_cm = 14; // cm
02947 
02948   if( !CPLOT_BYTE_MTX_Init( &(P->mPlotData) ) )
02949     return FALSE;
02950   if( !CPLOT_BYTE_MTX_calloc( &(P->mPlotData), P->mImage.Height, P->mImage.Width ) )
02951     return FALSE;  
02952 
02953   return TRUE;
02954 }
02955 
02956 
02957 BOOL CPLOT_SetPlottingOptions( CPLOT *P, CPLOT_structPlotOptions Options )
02958 {
02959   if( !P )
02960     return FALSE;
02961 
02962   P->mOptions = Options;
02963   return TRUE;
02964 }
02965 
02966 
02967 BOOL CPLOT_DrawLine( 
02968   CPLOT *P,
02969   const int x, 
02970   const int y, 
02971   const int to_x, 
02972   const int to_y,
02973   const CPLOT_enumColor color 
02974   )
02975 {
02976   int row    = 0,
02977     row_last = 0,
02978     halfway  = 0,
02979     col      = 0;
02980 
02981   double m = 0.0,
02982     b = 0.0;
02983 
02984   if( !P )
02985     return FALSE;
02986 
02987   if( x >= P->mImage.Width || to_x >= P->mImage.Width )
02988     return TRUE;
02989   if( y >= P->mImage.Height || to_y >= P->mImage.Height )
02990     return TRUE;
02991 
02992   if( to_x - x == 0 ) // vertical line
02993   {      
02994     if( y < to_y )
02995     {
02996       for( row=y; row<=to_y; row++ )
02997       {
02998         P->mPlotData.data[row][x] = color;
02999       }
03000     }
03001     else
03002     {
03003       for( row=to_y; row<=y; row++ )
03004       {
03005         P->mPlotData.data[row][x] = color;
03006       }
03007     }
03008     return TRUE;
03009   }
03010 
03011   if( to_x > x )
03012   {
03013     m = (double)(to_y - y) / (double)(to_x - x);
03014     b = y - m*x;
03015 
03016     col = x;
03017     row_last = (int)(m*col + b);      
03018     for( col=x; col<=to_x; col++ )
03019     {
03020       row = (int)(m*col + b);
03021 
03022       halfway = abs(row_last - row) / 2;
03023       while( abs(row_last - row) > 1 ) // must draw a vertical line
03024       {
03025         if( row_last > row )
03026           row_last--;
03027         else
03028           row_last++;
03029 
03030         // draw vertical halfway up col-1 and halfway up col
03031         if( abs(row_last - row) > halfway )
03032           P->mPlotData.data[row_last][col-1] = color;          
03033         else
03034           P->mPlotData.data[row_last][col] = color;          
03035       }
03036 
03037       P->mPlotData.data[row][col] = color;                    
03038       row_last = row;
03039     }
03040   }
03041   else
03042   {
03043     m = (double)(y - to_y) / (double)(x - to_x);
03044     b = y - m*x;
03045 
03046     col = to_x;
03047     row_last = (int)(m*col + b);      
03048     for( col=to_x; col<=x; col++ )
03049     {
03050       row = (int)(m*col + b);
03051 
03052       halfway = abs(row_last - row) / 2;
03053       while( abs(row_last - row) > 1 ) // must draw a vertical line
03054       {
03055         if( row_last > row )
03056           row_last--;
03057         else
03058           row_last++;
03059 
03060         // draw vertical halfway up col-1 and halfway up col
03061         if( abs(row_last - row) > halfway )
03062           P->mPlotData.data[row_last][col-1] = color;
03063         else
03064           P->mPlotData.data[row_last][col] = color;
03065       }
03066 
03067       P->mPlotData.data[row][col] = color;      
03068       row_last = row;
03069     }
03070   }
03071   return TRUE;
03072 }
03073 
03074 
03075 BOOL CPLOT_DrawDashedLine( 
03076   CPLOT *P,
03077   const int x, 
03078   const int y, 
03079   const int to_x, 
03080   const int to_y,
03081   const int kDashSize,
03082   const CPLOT_enumColor color )
03083 {
03084   int row    = 0,
03085     row_last = 0,
03086     halfway  = 0,
03087     col      = 0,
03088     dash     = 0;
03089 
03090   double m = 0.0,
03091     b = 0.0;
03092 
03093   if( !P )
03094     return FALSE;
03095 
03096   if( x >= P->mImage.Width || to_x >= P->mImage.Width )
03097     return TRUE;
03098   if( y >= P->mImage.Height || to_y >= P->mImage.Height )
03099     return TRUE;
03100 
03101 
03102   // y = mx + b
03103   if( to_x - x == 0 ) // m = 0
03104   {
03105     for( row=y; row<=to_y; row++ )
03106     {
03107       if( dash < kDashSize )
03108         P->mPlotData.data[row][x] = color;
03109 
03110       dash++;
03111       if( dash == kDashSize*2 )
03112         dash = 0;
03113     }
03114     return TRUE;
03115   }
03116 
03117   if( to_x > x )
03118   {
03119     dash = 0;
03120     m = (double)(to_y - y) / (double)(to_x - x);
03121     b = y - m*x;
03122 
03123     col = x;
03124     row_last = (int)(m*col + b);      
03125     for( col=x; col<=to_x; col++ )
03126     {
03127       row = (int)(m*col + b);
03128 
03129       halfway = abs(row_last - row) / 2;
03130       while( abs(row_last - row) > 1 ) // must draw a vertical line
03131       {
03132         if( row_last > row )
03133           row_last--;
03134         else
03135           row_last++;
03136 
03137         // draw vertical halfway up col-1 and halfway up col
03138         if( abs(row_last - row) > halfway )
03139         {
03140           if( dash < kDashSize )
03141             P->mPlotData.data[row_last][col-1] = color;
03142         }
03143         else
03144         {
03145           if( dash < kDashSize )
03146             P->mPlotData.data[row_last][col] = color;            
03147         }
03148 
03149         dash++;
03150         if( dash == kDashSize*2 )
03151           dash = 0;
03152 
03153       }
03154 
03155       if( dash < kDashSize )
03156         P->mPlotData.data[row][col] = color;
03157 
03158       dash++;
03159       if( dash == kDashSize*2 )
03160         dash = 0;         
03161     }
03162   }
03163   else
03164   {
03165     dash = 0;
03166     m = (double)(y - to_y) / (double)(x - to_x);
03167     b = y - m*x;
03168 
03169     col = to_x;
03170     row_last = (int)(m*col + b);      
03171     for( col=to_x; col<=x; col++ )
03172     {         
03173       row = (int)(m*col + b);
03174 
03175       halfway = abs(row_last - row) / 2;
03176       while( abs(row_last - row) > 1 ) // must draw a vertical line
03177       {
03178         if( row_last > row )
03179           row_last--;
03180         else
03181           row_last++;
03182 
03183         // draw vertical halfway up col-1 and halfway up col
03184         if( abs(row_last - row) > halfway )
03185         {
03186           if( dash < kDashSize )
03187             P->mPlotData.data[row_last][col-1] = color;            
03188         }
03189         else
03190         {
03191           if( dash < kDashSize )
03192             P->mPlotData.data[row_last][col] = color;                        
03193         }
03194         dash++;
03195         if( dash == kDashSize*2 )
03196           dash = 0;
03197       }
03198 
03199       if( dash < kDashSize )
03200         P->mPlotData.data[row][col] = color;                                
03201 
03202       dash++;
03203       if( dash == kDashSize*2 )
03204         dash = 0;
03205 
03206 
03207       row_last = row;
03208     }
03209   }
03210 
03211   return TRUE;
03212 }
03213 
03214 
03215 
03216 
03217 int CPLOT_DrawSmallLetter( 
03218   CPLOT *P,
03219   const char Letter, 
03220   const int x, 
03221   const int y,                                  
03222   BOOL isRotatedLeft,
03223   const CPLOT_enumColor color 
03224   )
03225 {
03226   const int klH = CPLOT_SMALLFONT_HGT;   // letter height
03227   const int klW = CPLOT_SMALLFONT_WIDTH; // letter width
03228 
03229   int row = 0;
03230   int col = 0;
03231 
03232   byte rotatedleft[CPLOT_SMALLFONT_WIDTH][CPLOT_SMALLFONT_HGT];
03233   byte temp[CPLOT_SMALLFONT_HGT][CPLOT_SMALLFONT_WIDTH];
03234 
03235   if( !P )
03236     return FALSE;
03237 
03238   if( y < klH )
03239     return 0;
03240 
03241   if( x + klW >= P->mImage.Width )
03242     return 0;
03243 
03244   memset( &rotatedleft, 0, CPLOT_SMALLFONT_WIDTH*CPLOT_SMALLFONT_HGT );
03245   memset( &temp, 0, CPLOT_SMALLFONT_WIDTH*CPLOT_SMALLFONT_HGT );
03246 
03247   switch( Letter )
03248   {
03249   case 'A':  memcpy( &temp, CPLOT_SMALLFONT_A, CPLOT_SMALLFONT_NBYTES ); break;        
03250   case 'B':  memcpy( &temp, CPLOT_SMALLFONT_B, CPLOT_SMALLFONT_NBYTES ); break;        
03251   case 'C':  memcpy( &temp, CPLOT_SMALLFONT_C, CPLOT_SMALLFONT_NBYTES ); break;        
03252   case 'D':  memcpy( &temp, CPLOT_SMALLFONT_D, CPLOT_SMALLFONT_NBYTES ); break;        
03253   case 'E':  memcpy( &temp, CPLOT_SMALLFONT_E, CPLOT_SMALLFONT_NBYTES ); break;        
03254   case 'F':  memcpy( &temp, CPLOT_SMALLFONT_F, CPLOT_SMALLFONT_NBYTES ); break;        
03255   case 'G':  memcpy( &temp, CPLOT_SMALLFONT_G, CPLOT_SMALLFONT_NBYTES ); break;        
03256   case 'H':  memcpy( &temp, CPLOT_SMALLFONT_H, CPLOT_SMALLFONT_NBYTES ); break;        
03257   case 'I':  memcpy( &temp, CPLOT_SMALLFONT_I, CPLOT_SMALLFONT_NBYTES ); break;        
03258   case 'J':  memcpy( &temp, CPLOT_SMALLFONT_J, CPLOT_SMALLFONT_NBYTES ); break;        
03259   case 'K':  memcpy( &temp, CPLOT_SMALLFONT_K, CPLOT_SMALLFONT_NBYTES ); break;        
03260   case 'L':  memcpy( &temp, CPLOT_SMALLFONT_L, CPLOT_SMALLFONT_NBYTES ); break;        
03261   case 'M':  memcpy( &temp, CPLOT_SMALLFONT_M, CPLOT_SMALLFONT_NBYTES ); break;        
03262   case 'N':  memcpy( &temp, CPLOT_SMALLFONT_N, CPLOT_SMALLFONT_NBYTES ); break;        
03263   case 'O':  memcpy( &temp, CPLOT_SMALLFONT_O, CPLOT_SMALLFONT_NBYTES ); break;        
03264   case 'P':  memcpy( &temp, CPLOT_SMALLFONT_P, CPLOT_SMALLFONT_NBYTES ); break;        
03265   case 'Q':  memcpy( &temp, CPLOT_SMALLFONT_Q, CPLOT_SMALLFONT_NBYTES ); break;
03266   case 'R':  memcpy( &temp, CPLOT_SMALLFONT_R, CPLOT_SMALLFONT_NBYTES ); break;
03267   case 'S':  memcpy( &temp, CPLOT_SMALLFONT_S, CPLOT_SMALLFONT_NBYTES ); break;
03268   case 'T':  memcpy( &temp, CPLOT_SMALLFONT_T, CPLOT_SMALLFONT_NBYTES ); break;
03269   case 'U':  memcpy( &temp, CPLOT_SMALLFONT_U, CPLOT_SMALLFONT_NBYTES ); break;
03270   case 'V':  memcpy( &temp, CPLOT_SMALLFONT_V, CPLOT_SMALLFONT_NBYTES ); break;
03271   case 'W':  memcpy( &temp, CPLOT_SMALLFONT_W, CPLOT_SMALLFONT_NBYTES ); break;
03272   case 'X':  memcpy( &temp, CPLOT_SMALLFONT_X, CPLOT_SMALLFONT_NBYTES ); break;
03273   case 'Y':  memcpy( &temp, CPLOT_SMALLFONT_Y, CPLOT_SMALLFONT_NBYTES ); break;
03274   case 'Z':  memcpy( &temp, CPLOT_SMALLFONT_Z, CPLOT_SMALLFONT_NBYTES ); break;
03275 
03276 
03277   case 'a':  memcpy( &temp, CPLOT_SMALLFONT_a, CPLOT_SMALLFONT_NBYTES ); break;
03278   case 'b':  memcpy( &temp, CPLOT_SMALLFONT_b, CPLOT_SMALLFONT_NBYTES ); break;
03279   case 'c':  memcpy( &temp, CPLOT_SMALLFONT_c, CPLOT_SMALLFONT_NBYTES ); break;
03280   case 'd':  memcpy( &temp, CPLOT_SMALLFONT_d, CPLOT_SMALLFONT_NBYTES ); break;
03281   case 'e':  memcpy( &temp, CPLOT_SMALLFONT_e, CPLOT_SMALLFONT_NBYTES ); break;
03282   case 'f':  memcpy( &temp, CPLOT_SMALLFONT_f, CPLOT_SMALLFONT_NBYTES ); break;
03283   case 'g':  memcpy( &temp, CPLOT_SMALLFONT_g, CPLOT_SMALLFONT_NBYTES ); break;
03284   case 'h':  memcpy( &temp, CPLOT_SMALLFONT_h, CPLOT_SMALLFONT_NBYTES ); break;
03285   case 'i':  memcpy( &temp, CPLOT_SMALLFONT_i, CPLOT_SMALLFONT_NBYTES ); break;
03286   case 'j':  memcpy( &temp, CPLOT_SMALLFONT_j, CPLOT_SMALLFONT_NBYTES ); break;
03287   case 'k':  memcpy( &temp, CPLOT_SMALLFONT_k, CPLOT_SMALLFONT_NBYTES ); break;
03288   case 'l':  memcpy( &temp, CPLOT_SMALLFONT_l, CPLOT_SMALLFONT_NBYTES ); break;
03289   case 'm':  memcpy( &temp, CPLOT_SMALLFONT_m, CPLOT_SMALLFONT_NBYTES ); break;
03290   case 'n':  memcpy( &temp, CPLOT_SMALLFONT_n, CPLOT_SMALLFONT_NBYTES ); break;
03291   case 'o':  memcpy( &temp, CPLOT_SMALLFONT_o, CPLOT_SMALLFONT_NBYTES ); break;
03292   case 'p':  memcpy( &temp, CPLOT_SMALLFONT_p, CPLOT_SMALLFONT_NBYTES ); break;
03293   case 'q':  memcpy( &temp, CPLOT_SMALLFONT_q, CPLOT_SMALLFONT_NBYTES ); break;
03294   case 'r':  memcpy( &temp, CPLOT_SMALLFONT_r, CPLOT_SMALLFONT_NBYTES ); break;
03295   case 's':  memcpy( &temp, CPLOT_SMALLFONT_s, CPLOT_SMALLFONT_NBYTES ); break;
03296   case 't':  memcpy( &temp, CPLOT_SMALLFONT_t, CPLOT_SMALLFONT_NBYTES ); break;
03297   case 'u':  memcpy( &temp, CPLOT_SMALLFONT_u, CPLOT_SMALLFONT_NBYTES ); break;
03298   case 'v':  memcpy( &temp, CPLOT_SMALLFONT_v, CPLOT_SMALLFONT_NBYTES ); break;
03299   case 'w':  memcpy( &temp, CPLOT_SMALLFONT_w, CPLOT_SMALLFONT_NBYTES ); break;
03300   case 'x':  memcpy( &temp, CPLOT_SMALLFONT_x, CPLOT_SMALLFONT_NBYTES ); break;
03301   case 'y':  memcpy( &temp, CPLOT_SMALLFONT_y, CPLOT_SMALLFONT_NBYTES ); break;
03302   case 'z':  memcpy( &temp, CPLOT_SMALLFONT_z, CPLOT_SMALLFONT_NBYTES ); break;
03303 
03304   case '~':  memcpy( &temp, CPLOT_SMALLFONT_tilda, CPLOT_SMALLFONT_NBYTES ); break;
03305   case '!':  memcpy( &temp, CPLOT_SMALLFONT_exclamation, CPLOT_SMALLFONT_NBYTES ); break;        
03306   // case '@':  memcpy( &temp, CPLOT_SMALLFONT_at, CPLOT_SMALLFONT_NBYTES ); break; // GDM_TODO - add
03307   //case '#':  memcpy( &temp, CPLOT_SMALLFONT_hash, CPLOT_SMALLFONT_NBYTES ); break; // GDM_TODO - add 
03308   case '$':  memcpy( &temp, CPLOT_SMALLFONT_dollarsign, CPLOT_SMALLFONT_NBYTES ); break;
03309   case '%':  memcpy( &temp, CPLOT_SMALLFONT_percent, CPLOT_SMALLFONT_NBYTES ); break;
03310   case '^':  memcpy( &temp, CPLOT_SMALLFONT_raiseto, CPLOT_SMALLFONT_NBYTES ); break;
03311   case '&':  memcpy( &temp, CPLOT_SMALLFONT_andsign, CPLOT_SMALLFONT_NBYTES ); break;
03312   case '*':  memcpy( &temp, CPLOT_SMALLFONT_star, CPLOT_SMALLFONT_NBYTES ); break;
03313   case '(':  memcpy( &temp, CPLOT_SMALLFONT_leftbracket, CPLOT_SMALLFONT_NBYTES ); break;
03314   case ')':  memcpy( &temp, CPLOT_SMALLFONT_rightbracket, CPLOT_SMALLFONT_NBYTES ); break;
03315   case '-':  memcpy( &temp, CPLOT_SMALLFONT_dash, CPLOT_SMALLFONT_NBYTES ); break;
03316   // case '_':  memcpy( &temp, CPLOT_SMALLFONT_underscore, CPLOT_SMALLFONT_NBYTES ); break; // GDM_TODO - add 
03317   case '+':  memcpy( &temp, CPLOT_SMALLFONT_plus, CPLOT_SMALLFONT_NBYTES ); break;
03318   case '=':  memcpy( &temp, CPLOT_SMALLFONT_equals, CPLOT_SMALLFONT_NBYTES ); break;
03319   // case '{':  memcpy( &temp, CPLOT_SMALLFONT_leftcurly, CPLOT_SMALLFONT_NBYTES ); break; // GDM_TODO - add 
03320   // case '}':  memcpy( &temp, CPLOT_SMALLFONT_rightcurly, CPLOT_SMALLFONT_NBYTES ); break; // GDM_TODO - add 
03321   case '|':  memcpy( &temp, CPLOT_SMALLFONT_vert, CPLOT_SMALLFONT_NBYTES ); break;
03322   case '[':  memcpy( &temp, CPLOT_SMALLFONT_leftsquare, CPLOT_SMALLFONT_NBYTES ); break;
03323   case ']':  memcpy( &temp, CPLOT_SMALLFONT_rightsquare, CPLOT_SMALLFONT_NBYTES ); break;
03324   case '\\': memcpy( &temp, CPLOT_SMALLFONT_backslash, CPLOT_SMALLFONT_NBYTES ); break;
03325   case '/':  memcpy( &temp, CPLOT_SMALLFONT_forwardslash, CPLOT_SMALLFONT_NBYTES ); break;
03326   case ';':  memcpy( &temp, CPLOT_SMALLFONT_semicolon, CPLOT_SMALLFONT_NBYTES ); break;
03327   case ':':  memcpy( &temp, CPLOT_SMALLFONT_colon, CPLOT_SMALLFONT_NBYTES ); break;
03328   case '\'': memcpy( &temp, CPLOT_SMALLFONT_singlequote, CPLOT_SMALLFONT_NBYTES ); break;
03329   case ',':  memcpy( &temp, CPLOT_SMALLFONT_comma, CPLOT_SMALLFONT_NBYTES ); break;
03330   case '.':  memcpy( &temp, CPLOT_SMALLFONT_point, CPLOT_SMALLFONT_NBYTES ); break;
03331   case '"':  memcpy( &temp, CPLOT_SMALLFONT_doublequote, CPLOT_SMALLFONT_NBYTES ); break;
03332   case '<':  memcpy( &temp, CPLOT_SMALLFONT_lessthan, CPLOT_SMALLFONT_NBYTES ); break;
03333   case '>':  memcpy( &temp, CPLOT_SMALLFONT_morethan, CPLOT_SMALLFONT_NBYTES ); break;
03334   // case '?':  memcpy( &temp, CPLOT_SMALLFONT_questionmark, CPLOT_SMALLFONT_NBYTES ); break;// GDM_TODO - add 
03335 
03336   case '1':  memcpy( &temp, CPLOT_SMALLFONT_One, CPLOT_SMALLFONT_NBYTES ); break;
03337   case '2':  memcpy( &temp, CPLOT_SMALLFONT_Two, CPLOT_SMALLFONT_NBYTES ); break;
03338   case '3':  memcpy( &temp, CPLOT_SMALLFONT_Three, CPLOT_SMALLFONT_NBYTES ); break;
03339   case '4':  memcpy( &temp, CPLOT_SMALLFONT_Four, CPLOT_SMALLFONT_NBYTES ); break;
03340   case '5':  memcpy( &temp, CPLOT_SMALLFONT_Five, CPLOT_SMALLFONT_NBYTES ); break;
03341   case '6':  memcpy( &temp, CPLOT_SMALLFONT_Six, CPLOT_SMALLFONT_NBYTES ); break;
03342   case '7':  memcpy( &temp, CPLOT_SMALLFONT_Seven, CPLOT_SMALLFONT_NBYTES ); break;
03343   case '8':  memcpy( &temp, CPLOT_SMALLFONT_Eight, CPLOT_SMALLFONT_NBYTES ); break;
03344   case '9':  memcpy( &temp, CPLOT_SMALLFONT_Nine, CPLOT_SMALLFONT_NBYTES ); break;
03345   case '0':  memcpy( &temp, CPLOT_SMALLFONT_Zero, CPLOT_SMALLFONT_NBYTES ); break;
03346 
03347   default: break;
03348   }
03349 
03350 
03351   if( isRotatedLeft )
03352   {  
03353     for( row = 0; row < klH; row++ )
03354     {      
03355       for( col = 0; col < klW; col++ )
03356       {  
03357         rotatedleft[5-col][row] = temp[row][col];
03358       }      
03359     }
03360   }
03361 
03362   // plot the letters
03363   if( isRotatedLeft )
03364   {
03365     for( row = 0; row < klW; row++ )
03366     {
03367       for( col = 0; col < klH; col++ )
03368       {  
03369         if( rotatedleft[row][col] )
03370           P->mPlotData.data[y-row][x+col] = rotatedleft[row][col] * color;         
03371       }         
03372     }      
03373   }
03374   else
03375   {
03376     for( row = 0; row < klH; row++ )
03377     {
03378       for( col = 0; col < klW; col++ )
03379       {  
03380         if( temp[row][col] )
03381           P->mPlotData.data[y-row][x+col] = temp[row][col] * color;          
03382       }
03383     }      
03384   }
03385   return klW;
03386 }
03387 
03388 
03389 
03390 
03391 
03392 
03393 int CPLOT_DrawLargeLetter( 
03394   CPLOT *P,
03395   const char Letter, 
03396   const int x, 
03397   const int y,
03398   BOOL isRotatedLeft,
03399   const CPLOT_enumColor color 
03400   )
03401 {
03402   int row = 0;
03403   int col = 0;
03404   int numCols = 0;
03405   char letter = Letter;
03406   const int kSize = CPLOT_LARGEFONT;
03407 
03408   byte temp[CPLOT_LARGEFONT][CPLOT_LARGEFONT];
03409   byte rotatedleft[CPLOT_LARGEFONT][CPLOT_LARGEFONT];
03410 
03411   if( !P )
03412     return FALSE;
03413 
03414   memset( &temp, 0, CPLOT_LARGEFONT*CPLOT_LARGEFONT );
03415   memset( &rotatedleft, 0, CPLOT_LARGEFONT*CPLOT_LARGEFONT );
03416   
03417   switch( letter )
03418   {
03419   case 'A':   numCols = 11; break;
03420   case 'B':   numCols = 11; break;
03421   case 'C':   numCols = 11; break;
03422   case 'D':   numCols = 11; break;
03423   case 'E':   numCols = 11; break;
03424   case 'F':   numCols = 11; break;
03425   case 'G':   numCols = 11; break;
03426   case 'H':   numCols = 11; break;
03427   case 'I':   numCols =  3; break;   
03428   case 'J':   numCols =  9; break;
03429   case 'K':   numCols = 11; break;
03430   case 'L':   numCols =  9; break;
03431   case 'M':   numCols = 13; break;
03432   case 'N':   numCols = 11; break;
03433   case 'O':   numCols = 12; break;
03434   case 'P':   numCols = 10; break;
03435   case 'Q':   numCols = 12; break;
03436   case 'R':   numCols = 11; break;
03437   case 'S':   numCols = 10; break;   
03438   case 'T':   numCols = 10; break;
03439   case 'U':   numCols = 10; break;
03440   case 'V':   numCols =  9; break;
03441   case 'W':   numCols = 14; break;
03442   case 'X':   numCols = 10; break;
03443   case 'Y':   numCols =  9; break;
03444   case 'Z':   numCols =  9; break;
03445 
03446   case 'a':   numCols =  8; break;
03447   case 'b':   numCols =  9; break;
03448   case 'c':   numCols =  9; break;   
03449   case 'd':   numCols =  9; break;
03450   case 'e':   numCols =  9; break;
03451   case 'f':   numCols =  7; break;
03452   case 'g':   numCols =  9; break;
03453   case 'h':   numCols =  9; break;
03454   case 'i':   numCols =  4; break;
03455   case 'j':   numCols =  6; break;
03456   case 'k':   numCols =  8; break;
03457   case 'l':   numCols =  4; break;
03458   case 'm':   numCols = 12; break;   
03459   case 'n':   numCols =  9; break;
03460   case 'o':   numCols =  9; break;
03461   case 'p':   numCols =  9; break;
03462   case 'q':   numCols =  9; break;
03463   case 'r':   numCols =  6; break;
03464   case 's':   numCols =  7; break;
03465   case 't':   numCols =  6; break;
03466   case 'u':   numCols =  9; break;
03467   case 'v':   numCols =  8; break;
03468   case 'w':   numCols = 12; break;   
03469   case 'x':   numCols =  7; break;
03470   case 'y':   numCols =  8; break;
03471   case 'z':   numCols =  8; break;
03472 
03473   case '~':   numCols = 10; break;
03474   case '!':   numCols =  4; break;
03475   case '@':   numCols = 12; break;
03476   case '#':   numCols =  9; break;
03477   case '$':   numCols = 10; break;
03478   case '%':   numCols = 14; break;
03479   case '^':   numCols = 10; break;
03480   case '&':   numCols = 11; break;
03481   case '*':   numCols =  8; break;
03482   case '(':   numCols =  5; break;
03483   case ')':   numCols =  5; break;
03484   case '-':   numCols =  5; break;
03485   case '_':   numCols =  9; break;
03486   case '+':   numCols = 10; break;
03487   case '=':   numCols = 10; break;   
03488   case '{':   numCols =  6; break;
03489   case '}':   numCols =  6; break;   
03490   case '|':   numCols =  5; break;
03491   case '[':   numCols =  5; break;
03492   case ']':   numCols =  5; break;
03493   case '\\':  numCols =  6; break;
03494   case '/':   numCols =  6; break;   
03495   case ';':   numCols =  4; break;
03496   case ':':   numCols =  4; break;   
03497   case '\'':  numCols =  4; break;
03498   case ',':   numCols =  4; break;
03499   case '.':   numCols =  4; break;   
03500   case '"':   numCols =  8; break;
03501   case '<':   numCols =  9; break;
03502   case '>':   numCols =  9; break;
03503   case '?':   numCols =  9; break;
03504 
03505   case '1':   numCols =  7; break;
03506   case '2':
03507   case '3':
03508   case '4':
03509   case '5':
03510   case '6':
03511   case '7':
03512   case '8':
03513   case '9':
03514   case '0':   numCols =  8; break;                  
03515 
03516   case -1:  numCols =  12; break;
03517   
03518   default: numCols = 5; break;
03519   }
03520 
03521   
03522   switch( letter )
03523   {
03524   case 'A':  memcpy( &temp, CPLOT_LARGEFONT_A, CPLOT_LARGEFONT_NBYTES ); break;        
03525   case 'B':  memcpy( &temp, CPLOT_LARGEFONT_B, CPLOT_LARGEFONT_NBYTES ); break;        
03526   case 'C':  memcpy( &temp, CPLOT_LARGEFONT_C, CPLOT_LARGEFONT_NBYTES ); break;        
03527   case 'D':  memcpy( &temp, CPLOT_LARGEFONT_D, CPLOT_LARGEFONT_NBYTES ); break;        
03528   case 'E':  memcpy( &temp, CPLOT_LARGEFONT_E, CPLOT_LARGEFONT_NBYTES ); break;        
03529   case 'F':  memcpy( &temp, CPLOT_LARGEFONT_F, CPLOT_LARGEFONT_NBYTES ); break;        
03530   case 'G':  memcpy( &temp, CPLOT_LARGEFONT_G, CPLOT_LARGEFONT_NBYTES ); break;        
03531   case 'H':  memcpy( &temp, CPLOT_LARGEFONT_H, CPLOT_LARGEFONT_NBYTES ); break;        
03532   case 'I':  memcpy( &temp, CPLOT_LARGEFONT_I, CPLOT_LARGEFONT_NBYTES ); break;        
03533   case 'J':  memcpy( &temp, CPLOT_LARGEFONT_J, CPLOT_LARGEFONT_NBYTES ); break;        
03534   case 'K':  memcpy( &temp, CPLOT_LARGEFONT_K, CPLOT_LARGEFONT_NBYTES ); break;        
03535   case 'L':  memcpy( &temp, CPLOT_LARGEFONT_L, CPLOT_LARGEFONT_NBYTES ); break;        
03536   case 'M':  memcpy( &temp, CPLOT_LARGEFONT_M, CPLOT_LARGEFONT_NBYTES ); break;        
03537   case 'N':  memcpy( &temp, CPLOT_LARGEFONT_N, CPLOT_LARGEFONT_NBYTES ); break;        
03538   case 'O':  memcpy( &temp, CPLOT_LARGEFONT_O, CPLOT_LARGEFONT_NBYTES ); break;        
03539   case 'P':  memcpy( &temp, CPLOT_LARGEFONT_P, CPLOT_LARGEFONT_NBYTES ); break;        
03540   case 'Q':  memcpy( &temp, CPLOT_LARGEFONT_Q, CPLOT_LARGEFONT_NBYTES ); break;
03541   case 'R':  memcpy( &temp, CPLOT_LARGEFONT_R, CPLOT_LARGEFONT_NBYTES ); break;
03542   case 'S':  memcpy( &temp, CPLOT_LARGEFONT_S, CPLOT_LARGEFONT_NBYTES ); break;
03543   case 'T':  memcpy( &temp, CPLOT_LARGEFONT_T, CPLOT_LARGEFONT_NBYTES ); break;
03544   case 'U':  memcpy( &temp, CPLOT_LARGEFONT_U, CPLOT_LARGEFONT_NBYTES ); break;
03545   case 'V':  memcpy( &temp, CPLOT_LARGEFONT_V, CPLOT_LARGEFONT_NBYTES ); break;
03546   case 'W':  memcpy( &temp, CPLOT_LARGEFONT_W, CPLOT_LARGEFONT_NBYTES ); break;
03547   case 'X':  memcpy( &temp, CPLOT_LARGEFONT_X, CPLOT_LARGEFONT_NBYTES ); break;
03548   case 'Y':  memcpy( &temp, CPLOT_LARGEFONT_Y, CPLOT_LARGEFONT_NBYTES ); break;
03549   case 'Z':  memcpy( &temp, CPLOT_LARGEFONT_Z, CPLOT_LARGEFONT_NBYTES ); break;
03550 
03551 
03552   case 'a':  memcpy( &temp, CPLOT_LARGEFONT_a, CPLOT_LARGEFONT_NBYTES ); break;
03553   case 'b':  memcpy( &temp, CPLOT_LARGEFONT_b, CPLOT_LARGEFONT_NBYTES ); break;
03554   case 'c':  memcpy( &temp, CPLOT_LARGEFONT_c, CPLOT_LARGEFONT_NBYTES ); break;
03555   case 'd':  memcpy( &temp, CPLOT_LARGEFONT_d, CPLOT_LARGEFONT_NBYTES ); break;
03556   case 'e':  memcpy( &temp, CPLOT_LARGEFONT_e, CPLOT_LARGEFONT_NBYTES ); break;
03557   case 'f':  memcpy( &temp, CPLOT_LARGEFONT_f, CPLOT_LARGEFONT_NBYTES ); break;
03558   case 'g':  memcpy( &temp, CPLOT_LARGEFONT_g, CPLOT_LARGEFONT_NBYTES ); break;
03559   case 'h':  memcpy( &temp, CPLOT_LARGEFONT_h, CPLOT_LARGEFONT_NBYTES ); break;
03560   case 'i':  memcpy( &temp, CPLOT_LARGEFONT_i, CPLOT_LARGEFONT_NBYTES ); break;
03561   case 'j':  memcpy( &temp, CPLOT_LARGEFONT_j, CPLOT_LARGEFONT_NBYTES ); break;
03562   case 'k':  memcpy( &temp, CPLOT_LARGEFONT_k, CPLOT_LARGEFONT_NBYTES ); break;
03563   case 'l':  memcpy( &temp, CPLOT_LARGEFONT_l, CPLOT_LARGEFONT_NBYTES ); break;
03564   case 'm':  memcpy( &temp, CPLOT_LARGEFONT_m, CPLOT_LARGEFONT_NBYTES ); break;
03565   case 'n':  memcpy( &temp, CPLOT_LARGEFONT_n, CPLOT_LARGEFONT_NBYTES ); break;
03566   case 'o':  memcpy( &temp, CPLOT_LARGEFONT_o, CPLOT_LARGEFONT_NBYTES ); break;
03567   case 'p':  memcpy( &temp, CPLOT_LARGEFONT_p, CPLOT_LARGEFONT_NBYTES ); break;
03568   case 'q':  memcpy( &temp, CPLOT_LARGEFONT_q, CPLOT_LARGEFONT_NBYTES ); break;
03569   case 'r':  memcpy( &temp, CPLOT_LARGEFONT_r, CPLOT_LARGEFONT_NBYTES ); break;
03570   case 's':  memcpy( &temp, CPLOT_LARGEFONT_s, CPLOT_LARGEFONT_NBYTES ); break;
03571   case 't':  memcpy( &temp, CPLOT_LARGEFONT_t, CPLOT_LARGEFONT_NBYTES ); break;
03572   case 'u':  memcpy( &temp, CPLOT_LARGEFONT_u, CPLOT_LARGEFONT_NBYTES ); break;
03573   case 'v':  memcpy( &temp, CPLOT_LARGEFONT_v, CPLOT_LARGEFONT_NBYTES ); break;
03574   case 'w':  memcpy( &temp, CPLOT_LARGEFONT_w, CPLOT_LARGEFONT_NBYTES ); break;
03575   case 'x':  memcpy( &temp, CPLOT_LARGEFONT_x, CPLOT_LARGEFONT_NBYTES ); break;
03576   case 'y':  memcpy( &temp, CPLOT_LARGEFONT_y, CPLOT_LARGEFONT_NBYTES ); break;
03577   case 'z':  memcpy( &temp, CPLOT_LARGEFONT_z, CPLOT_LARGEFONT_NBYTES ); break;
03578 
03579   case '~':  memcpy( &temp, CPLOT_LARGEFONT_tilda, CPLOT_LARGEFONT_NBYTES ); break;
03580   case '!':  memcpy( &temp, CPLOT_LARGEFONT_exclamation, CPLOT_LARGEFONT_NBYTES ); break;        
03581   case '@':  memcpy( &temp, CPLOT_LARGEFONT_at, CPLOT_LARGEFONT_NBYTES ); break;
03582   case '#':  memcpy( &temp, CPLOT_LARGEFONT_hash, CPLOT_LARGEFONT_NBYTES ); break;
03583   case '$':  memcpy( &temp, CPLOT_LARGEFONT_dollarsign, CPLOT_LARGEFONT_NBYTES ); break;
03584   case '%':  memcpy( &temp, CPLOT_LARGEFONT_percent, CPLOT_LARGEFONT_NBYTES ); break;
03585   case '^':  memcpy( &temp, CPLOT_LARGEFONT_raiseto, CPLOT_LARGEFONT_NBYTES ); break;
03586   case '&':  memcpy( &temp, CPLOT_LARGEFONT_andsign, CPLOT_LARGEFONT_NBYTES ); break;
03587   case '*':  memcpy( &temp, CPLOT_LARGEFONT_star, CPLOT_LARGEFONT_NBYTES ); break;
03588   case '(':  memcpy( &temp, CPLOT_LARGEFONT_leftbracket, CPLOT_LARGEFONT_NBYTES ); break;
03589   case ')':  memcpy( &temp, CPLOT_LARGEFONT_rightbracket, CPLOT_LARGEFONT_NBYTES ); break;
03590   case '-':  memcpy( &temp, CPLOT_LARGEFONT_dash, CPLOT_LARGEFONT_NBYTES ); break;
03591   case '_':  memcpy( &temp, CPLOT_LARGEFONT_underscore, CPLOT_LARGEFONT_NBYTES ); break;
03592   case '+':  memcpy( &temp, CPLOT_LARGEFONT_plus, CPLOT_LARGEFONT_NBYTES ); break;
03593   case '=':  memcpy( &temp, CPLOT_LARGEFONT_equals, CPLOT_LARGEFONT_NBYTES ); break;
03594   case '{':  memcpy( &temp, CPLOT_LARGEFONT_leftcurly, CPLOT_LARGEFONT_NBYTES ); break;
03595   case '}':  memcpy( &temp, CPLOT_LARGEFONT_rightcurly, CPLOT_LARGEFONT_NBYTES ); break;
03596   case '|':  memcpy( &temp, CPLOT_LARGEFONT_vert, CPLOT_LARGEFONT_NBYTES ); break;
03597   case '[':  memcpy( &temp, CPLOT_LARGEFONT_leftsquare, CPLOT_LARGEFONT_NBYTES ); break;
03598   case ']':  memcpy( &temp, CPLOT_LARGEFONT_rightsquare, CPLOT_LARGEFONT_NBYTES ); break;
03599   case '\\': memcpy( &temp, CPLOT_LARGEFONT_backslash, CPLOT_LARGEFONT_NBYTES ); break;
03600   case '/':  memcpy( &temp, CPLOT_LARGEFONT_forwardslash, CPLOT_LARGEFONT_NBYTES ); break;
03601   case ';':  memcpy( &temp, CPLOT_LARGEFONT_semicolon, CPLOT_LARGEFONT_NBYTES ); break;
03602   case ':':  memcpy( &temp, CPLOT_LARGEFONT_colon, CPLOT_LARGEFONT_NBYTES ); break;
03603   case '\'': memcpy( &temp, CPLOT_LARGEFONT_singlequote, CPLOT_LARGEFONT_NBYTES ); break;
03604   case ',':  memcpy( &temp, CPLOT_LARGEFONT_comma, CPLOT_LARGEFONT_NBYTES ); break;
03605   case '.':  memcpy( &temp, CPLOT_LARGEFONT_point, CPLOT_LARGEFONT_NBYTES ); break;
03606   case '"':  memcpy( &temp, CPLOT_LARGEFONT_doublequote, CPLOT_LARGEFONT_NBYTES ); break;
03607   case '<':  memcpy( &temp, CPLOT_LARGEFONT_lessthan, CPLOT_LARGEFONT_NBYTES ); break;
03608   case '>':  memcpy( &temp, CPLOT_LARGEFONT_morethan, CPLOT_LARGEFONT_NBYTES ); break;
03609   case '?':  memcpy( &temp, CPLOT_LARGEFONT_questionmark, CPLOT_LARGEFONT_NBYTES ); break;
03610 
03611   case '1':  memcpy( &temp, CPLOT_LARGEFONT_One, CPLOT_LARGEFONT_NBYTES ); break;
03612   case '2':  memcpy( &temp, CPLOT_LARGEFONT_Two, CPLOT_LARGEFONT_NBYTES ); break;
03613   case '3':  memcpy( &temp, CPLOT_LARGEFONT_Three, CPLOT_LARGEFONT_NBYTES ); break;
03614   case '4':  memcpy( &temp, CPLOT_LARGEFONT_Four, CPLOT_LARGEFONT_NBYTES ); break;
03615   case '5':  memcpy( &temp, CPLOT_LARGEFONT_Five, CPLOT_LARGEFONT_NBYTES ); break;
03616   case '6':  memcpy( &temp, CPLOT_LARGEFONT_Six, CPLOT_LARGEFONT_NBYTES ); break;
03617   case '7':  memcpy( &temp, CPLOT_LARGEFONT_Seven, CPLOT_LARGEFONT_NBYTES ); break;
03618   case '8':  memcpy( &temp, CPLOT_LARGEFONT_Eight, CPLOT_LARGEFONT_NBYTES ); break;
03619   case '9':  memcpy( &temp, CPLOT_LARGEFONT_Nine, CPLOT_LARGEFONT_NBYTES ); break;
03620   case '0':  memcpy( &temp, CPLOT_LARGEFONT_Zero, CPLOT_LARGEFONT_NBYTES ); break;
03621 
03622   case -1:  memcpy( &temp, CPLOT_LARGEFONT_sigma, CPLOT_LARGEFONT_NBYTES ); break;
03623 
03624   default: break;
03625   }
03626 
03627   if( isRotatedLeft )
03628   {
03629     for( row = 0; row < kSize; row++ )
03630     {      
03631       for( col = 0; col < kSize; col++ )
03632       {  
03633         rotatedleft[kSize - row - 1][col] = temp[col][row];
03634       }      
03635     }
03636   }
03637 
03638   // plot the letters
03639   if( isRotatedLeft )
03640   {
03641     if( y < kSize )
03642       return 0;
03643 
03644     if( x + kSize >= P->mImage.Width )
03645       return 0;
03646 
03647     for( row = kSize - numCols; row < kSize; row++ )
03648     {
03649       for( col = 0; col < kSize; col++ )
03650       {  
03651         if( rotatedleft[row][col] )
03652           P->mPlotData.data[y-row][x+col] = (rotatedleft[row][col]) * color;            
03653       }         
03654     }      
03655   }
03656   else
03657   {
03658     if( y < kSize )
03659       return 0;
03660 
03661     if( x + numCols >= P->mImage.Width )
03662       return 0;
03663 
03664     for( row = 0; row < kSize; row++ )
03665     {
03666       for( col = 0; col < numCols; col++ )
03667       {            
03668         if( temp[row][col] )
03669           P->mPlotData.data[y-row][x+col] = (temp[row][col]) * color;
03670       }
03671     }
03672   }
03673 
03674   return numCols;
03675 }
03676 
03677 BOOL CPLOT_DrawString( 
03678   CPLOT *P,
03679   const char* str, 
03680   const int left, 
03681   const int top,
03682   const BOOL useLargeFont,
03683   const BOOL isRotatedLeft,
03684   const CPLOT_enumColor color 
03685   )
03686 { 
03687   int length;
03688 
03689   int offset = 0,
03690     i      = 0,
03691     letterWidth = 0;
03692 
03693   if( str == NULL )
03694     return TRUE; // nothing to draw
03695 
03696   length = (int)strlen(str);
03697 
03698   if( !P )
03699     return FALSE;
03700   if( !str )
03701     return FALSE;
03702 
03703   if( left >= P->mImage.Width )
03704     return TRUE;
03705   if( top >= P->mImage.Height )
03706     return TRUE;
03707 
03708   if( strstr( str, "\\sigma" ) )
03709   {
03710     letterWidth = CPLOT_DrawLargeLetter( P, -1, left, top + offset, isRotatedLeft, color );  // GDM_HACK - a hack for now.
03711   }
03712   else
03713   {
03714     for( i = 0; i < length; i++ )      
03715     {
03716       if( isRotatedLeft )
03717       {
03718         if( top + offset > P->mImage.Height )
03719           break;
03720 
03721         if( useLargeFont )
03722           letterWidth = CPLOT_DrawLargeLetter( P, str[i], left, top + offset, isRotatedLeft, color );          
03723         else
03724           letterWidth = CPLOT_DrawSmallLetter( P, str[i], left, top + offset, isRotatedLeft, color );
03725       }
03726       else
03727       {
03728         if( left + offset > P->mImage.Width )
03729           break;
03730 
03731         if( useLargeFont )
03732           letterWidth = CPLOT_DrawLargeLetter( P, str[i], left + offset, top, isRotatedLeft, color );
03733         else
03734           letterWidth = CPLOT_DrawSmallLetter( P, str[i], left + offset, top, isRotatedLeft, color );
03735 
03736       }
03737       offset += letterWidth;      
03738     }
03739   }
03740   return TRUE;
03741 }
03742 
03743 
03744 
03745 
03746 BOOL CPLOT_DrawValue( 
03747   CPLOT *P,
03748   const BOOL leftalign,
03749   double value, 
03750   const int left, 
03751   const int top,
03752   const CPLOT_enumColor color 
03753   )
03754 {
03755   const int kTextWidth = 6*13;
03756   char ValueBuffer[48];
03757   size_t length = 0;
03758 
03759   if( !P )
03760     return FALSE;
03761 
03762   ValueBuffer[0] = '\0';
03763 
03764   if( leftalign )
03765   {
03766 #ifndef _CRT_SECURE_NO_DEPRECATE
03767     sprintf_s( ValueBuffer, 48, "%-13.7g", value );
03768 #else
03769     sprintf( ValueBuffer, "%-13.7g", value );
03770 #endif
03771   }
03772   else
03773   {
03774 #ifndef _CRT_SECURE_NO_DEPRECATE
03775     sprintf_s( ValueBuffer, 48, "%13.7g", value );
03776 #else
03777     sprintf( ValueBuffer, "%13.7g", value );
03778 #endif
03779   }
03780 
03781   
03782   if( (left + kTextWidth) >= P->mImage.Width )
03783     return TRUE;
03784   if( top >= P->mImage.Height )
03785     return TRUE;
03786 
03787   length = strlen(ValueBuffer);
03788 
03789   if( !CPLOT_DrawString( P, ValueBuffer, left, top, TRUE, FALSE, color ) )
03790     return FALSE;
03791 
03792   return TRUE;
03793 }
03794 
03795 
03796 
03797 BOOL CPLOT_ResizePlot( CPLOT *P  )
03798 {
03799   //---------------------------mImage.Width--------------------------------//
03800   //|               |                                |                    |
03801   //|               mTitleAllowance                  |                    |
03802   //|               |                                |                    |
03803   //|               |--------------------------------+                    |
03804   //|<-mYLabelAll.->|                                |<-mRightYLabelAll.->|
03805   //|               |                                |                    |
03806   //|               |                                |                    |
03807   //|               |                                |                    |
03808   //mImage.Height   |                              mAxes.Height           |
03809   //|               |                                |                    |
03810   //|               |                                |                    |
03811   //|               |                                |                    |
03812   //|               +--------mAxes.Width-------------+                    |
03813   //|               |                                |                    |
03814   //|               mXLabelAllowance                 |                    |
03815   //|               |                                |                    |
03816   //|               |                                |                    |
03817   //---------------------------mImage.Width--------------------------------//
03818   int previousWidth = 0;
03819   int rem = 0;
03820 
03821   if( !P )
03822     return FALSE;
03823 
03824   if( P->mOptions.PlotSize_Width_cm % 2 ) 
03825     P->mAxes.Width = P->mOptions.PlotSize_Width_cm*CPLOT_PIXELS_PER_CM + 2;
03826   else
03827     P->mAxes.Width = P->mOptions.PlotSize_Width_cm*CPLOT_PIXELS_PER_CM;
03828 
03829   P->mAxes.Height = P->mOptions.PlotSize_Height_cm*CPLOT_PIXELS_PER_CM;
03830 
03831   if( P->mOptions.title == NULL )
03832     P->mTitleAllowance = 50;
03833 
03834   if( P->mOptions.x.label == NULL )
03835     P->mXLabelAllowance = 15;
03836 
03837   if( P->mOptions.y_label_right != NULL )
03838     P->mRightYLabelAllowance = 112;
03839 
03840   previousWidth = P->mImage.Width;
03841   P->mImage.Width  = P->mAxes.Width  + P->mRightYLabelAllowance + P->mYLabelAllowance;
03842 
03843   // The width must be evely divisible by four
03844   rem = P->mImage.Width%4;
03845   P->mImage.Width += rem;  
03846 
03847   P->mImage.Height = P->mAxes.Height + P->mXLabelAllowance + P->mTitleAllowance;
03848 
03849   if( P->mImage.Width < 700 &&
03850     P->mOptions.plotStatistics &&
03851     P->mOptions.plotLabelOnRight == FALSE )
03852   {
03853     P->mImage.Width = 700;
03854   }
03855 
03856   // define the start and end of the plot window
03857   P->mAxes.StartX    = P->mYLabelAllowance; // fixed
03858   P->mAxes.FinishX   = P->mAxes.StartX + P->mAxes.Width;   
03859 
03860   P->mAxes.StartY     = P->mXLabelAllowance;
03861   P->mAxes.FinishY    = P->mAxes.StartY + P->mAxes.Height;   
03862 
03863 
03864   // increase the Figure height or width for
03865   // labeling only or
03866   // stats box on right or
03867   // stats box on bottom
03868   if( P->mOptions.plotLabelOnRight )
03869   {
03870     if( P->mOptions.plotStatistics )
03871     {
03872       P->mLabelWidth = 112;
03873       switch( P->mOptions.numberOfSeries )
03874       {
03875       case 1:
03876       case 2:
03877       case 3: P->mImage.Width += P->mOptions.numberOfSeries*P->mLabelWidth + 44; break;    
03878       case 4: 
03879       case 5: 
03880       case 6: 
03881       case 7:
03882       case 8:
03883       case 9: 
03884       case 10:
03885       case 11:
03886       case 12: P->mImage.Width += 3*P->mLabelWidth + 44; break;
03887       default: break;
03888       }         
03889     }
03890     else
03891     {
03892       P->mImage.Width += 120;
03893     }
03894   }
03895   else
03896   {
03897     P->mImage.Height += P->mOptions.numberOfSeries*20 + 20;
03898     P->mAxes.StartY  += P->mOptions.numberOfSeries*20 + 20;
03899     P->mAxes.FinishY += P->mOptions.numberOfSeries*20 + 20;
03900   }
03901 
03902   if( previousWidth > P->mImage.Width )
03903     P->mImage.Width = previousWidth;
03904 
03905   // The width must be evely divisible by four
03906   rem = P->mImage.Width%4;
03907   P->mImage.Width += rem;  
03908 
03909 
03910   if( !CPLOT_BYTE_MTX_calloc( &(P->mPlotData), P->mImage.Height, P->mImage.Width ) )
03911     return FALSE;
03912 
03913   return TRUE;  
03914 }
03915 
03916 
03917 BOOL CPLOT_IsNAN( double value )
03918 {
03919 #ifdef WIN32
03920   if( _isnan( value ) )
03921     return TRUE;  
03922   else
03923     return FALSE;  
03924 #else
03925   if( isnan( value ) )
03926     return TRUE;  
03927   else
03928     return FALSE;  
03929 #endif
03930 }
03931 
03932 
03933 
03934 BOOL CPLOT_IsPostiveINF( double value )
03935 {
03936 #ifdef WIN32
03937   if( _finite( value ) )
03938   {
03939     return FALSE;
03940   }
03941   else
03942   {
03943     if( value > 0 )
03944       return TRUE;
03945     else
03946       return FALSE;
03947   }    
03948 #else
03949   if( isfinite( value ) )
03950   {
03951     return FALSE;
03952   }
03953   else
03954   {
03955     if( value > 0 )
03956       return TRUE;
03957     else
03958       return FALSE;
03959   }    
03960 #endif
03961 }
03962 
03963 
03964 BOOL CPLOT_IsNegativeINF( double value )
03965 {
03966 #ifdef WIN32
03967   if( _finite( value ) )
03968   {
03969     return FALSE;
03970   }
03971   else
03972   {
03973     if( value < 0 )
03974       return TRUE;
03975     else
03976       return FALSE;
03977   }    
03978 #else
03979   if( isfinite( value ) )
03980   {
03981     return FALSE;
03982   }
03983   else
03984   {
03985     if( value < 0 )
03986       return TRUE;
03987     else
03988       return FALSE;
03989   }    
03990 #endif
03991 }
03992 
03993 
03994 
03995 
03996 BOOL CPLOT_DetermineSeriesStatistics( CPLOT_structSeries *series )
03997 {
03998   int i;
03999   int n; // the number of items in the series.
04000   int n_tmp; // the number of items that are not NaN.
04001   int index_a;
04002   int index_b;
04003   double sumx2 = 0;
04004   double sumx = 0;
04005   BOOL isIPPSEnabled = FALSE;
04006   BOOL computeStats = TRUE;
04007   
04008   if( !series )
04009     return FALSE;
04010 
04011   index_a = index_b = 0;
04012   n = series->n;
04013 
04014   memset( &(series->xStats), 0, sizeof(CPLOT_structStats) );
04015   memset( &(series->yStats), 0, sizeof(CPLOT_structStats) );
04016     
04017   if( n == 0 )
04018   {
04019     return TRUE;
04020   }
04021 
04022   if( n == 1 )
04023   {
04024     series->xStats.min   = series->X[0];
04025     series->xStats.max   = series->X[0];
04026     series->xStats.mean  = series->X[0];
04027     series->xStats.stdev = 0.0;
04028     series->xStats.rms   = series->X[0];
04029     series->xStats.range = 0.0;
04030 
04031     series->yStats.min   = series->Y[0];
04032     series->yStats.max   = series->Y[0];
04033     series->yStats.mean  = series->Y[0];
04034     series->yStats.stdev = 0.0;
04035     series->yStats.rms   = series->Y[0];
04036     series->yStats.range = 0.0;
04037     return TRUE;
04038   }
04039 
04040 #ifdef INTEL_IPPS
04041 
04042   isIPPSEnabled = TRUE;
04043   
04044   if( ippsMinMaxIndx_64f( series->X, n, &(series->xStats.min), &index_a, &(series->xStats.max), &index_b ) != ippStsNoErr )
04045     return FALSE;
04046   if( series->xStats.min > series->X[index_a] ) // possible IPPS bug due to NaN or INF
04047     series->xStats.min = series->X[index_a];
04048   if( series->xStats.max < series->X[index_b] ) // possible IPPS bug due to NaN or INF
04049     series->xStats.max = series->X[index_b];
04050 
04051   if( ippsMinMaxIndx_64f( series->Y, n, &(series->yStats.min), &index_a, &(series->yStats.max), &index_b ) != ippStsNoErr )
04052     return FALSE;
04053   if( series->yStats.min > series->Y[index_a] ) // possible IPPS bug due to NaN or INF
04054     series->yStats.min = series->Y[index_a];
04055   if( series->yStats.max < series->Y[index_b] ) // possible IPPS bug due to NaN or INF
04056     series->yStats.max = series->Y[index_b];
04057 
04058   series->xStats.range = series->xStats.max - series->xStats.min;
04059   series->yStats.range = series->yStats.max - series->yStats.min;
04060 
04061   if( ippsSum_64f( series->X, n, &(series->xStats.mean) ) != ippStsNoErr )  
04062     return FALSE;
04063   series->xStats.mean /= (double)(n);
04064 
04065   if( ippsSum_64f( series->Y, n, &(series->yStats.mean) ) != ippStsNoErr )  
04066     return FALSE;
04067   series->yStats.mean /= (double)(n);
04068 
04069   // Compute RMS
04070   if( ippsNorm_L2_64f( series->X, n, &(series->xStats.rms) ) != ippStsNoErr )  
04071     return FALSE;
04072   series->xStats.rms /= sqrt( (double)(n));
04073   if( ippsNorm_L2_64f( series->Y, n, &(series->yStats.rms) ) != ippStsNoErr )  
04074     return FALSE;
04075   series->yStats.rms /= sqrt( (double)(n));
04076 
04077   computeStats = FALSE;
04078 
04079 #endif
04080 
04081   if( isIPPSEnabled )
04082   {
04083     // Check IPPS for NaN and INF bad values.
04084     do
04085     {
04086       if( CPLOT_IsNAN( series->xStats.min ) || CPLOT_IsPostiveINF( series->xStats.min ) || CPLOT_IsNegativeINF( series->xStats.min ) )
04087       {
04088         computeStats = TRUE;
04089         break;
04090       }
04091       if( CPLOT_IsNAN( series->xStats.max ) || CPLOT_IsPostiveINF( series->xStats.max ) || CPLOT_IsNegativeINF( series->xStats.max ) )
04092       {
04093         computeStats = TRUE;
04094         break;
04095       }
04096       if( CPLOT_IsNAN( series->xStats.mean ) || CPLOT_IsPostiveINF( series->xStats.mean ) || CPLOT_IsNegativeINF( series->xStats.mean ) )
04097       {
04098         computeStats = TRUE;
04099         break;
04100       }
04101       if( CPLOT_IsNAN( series->xStats.rms ) || CPLOT_IsPostiveINF( series->xStats.rms ) || CPLOT_IsNegativeINF( series->xStats.rms ) )
04102       {
04103         computeStats = TRUE;
04104         break;
04105       }
04106     }while(0);
04107   }
04108 
04109   // These statistics ignore NaN and INF values for min, max, range, mean. 
04110   // stdev and RMS will ignore NaN but not INF.
04111   if( computeStats ) 
04112   {
04113     series->xStats.min = DBL_MAX;
04114     series->xStats.max = -DBL_MAX;
04115     n_tmp = 0;
04116     for( i = 0; i < n; i++ )
04117     {
04118       // ignore NaN and INF.
04119       if( CPLOT_IsNAN( series->X[i] ) || CPLOT_IsPostiveINF( series->X[i] ) || CPLOT_IsNegativeINF( series->X[i] ) )
04120         continue;
04121 
04122       if( series->X[i] < series->xStats.min )
04123       {
04124         series->xStats.min = series->X[i];
04125       }
04126       if( series->X[i] > series->xStats.max )
04127       {
04128         series->xStats.max = series->X[i];
04129       }
04130       series->xStats.mean += series->X[i];
04131       n_tmp++;
04132     }
04133     series->xStats.range = series->xStats.max - series->xStats.min;
04134     if( n_tmp )
04135     {
04136       series->xStats.mean /= (double)(n_tmp);
04137     }
04138 
04139 
04140     series->yStats.min = DBL_MAX;
04141     series->yStats.max = -DBL_MAX;
04142     n_tmp = 0;
04143     for( i = 0; i < n; i++ )
04144     {
04145       // ignore NaN and INF.
04146       if( CPLOT_IsNAN( series->Y[i] ) || CPLOT_IsPostiveINF( series->Y[i] ) || CPLOT_IsNegativeINF( series->Y[i] ) )
04147         continue;
04148 
04149       if( series->Y[i] < series->yStats.min )
04150       {
04151         series->yStats.min = series->Y[i];
04152       }
04153       if( series->Y[i] > series->yStats.max )
04154       {
04155         series->yStats.max = series->Y[i];
04156       }
04157       series->yStats.mean += series->Y[i];
04158       n_tmp++;
04159     }
04160     series->yStats.range = series->yStats.max - series->yStats.min;
04161     if( n_tmp )
04162     {
04163       series->yStats.mean /= (double)(n_tmp);
04164     }
04165 
04166     // Compute RMS
04167     series->xStats.rms = 0;
04168     n_tmp = 0;
04169     for( i = 0; i < n; i++ )
04170     {
04171       if( !CPLOT_IsNAN( series->X[i] ) )
04172       {
04173         series->xStats.rms += series->X[i] * series->X[i];    
04174         n_tmp++;
04175       }
04176     }
04177     if( n_tmp )
04178     {
04179       series->xStats.rms /= (double)(n_tmp);
04180       series->xStats.rms = sqrt(series->xStats.rms);
04181     }
04182 
04183     series->yStats.rms = 0;
04184     n_tmp = 0;
04185     for( i = 0; i < n; i++ )
04186     {
04187       if( !CPLOT_IsNAN( series->Y[i] ) )
04188       {
04189         series->yStats.rms += series->Y[i] * series->Y[i];    
04190         n_tmp++;
04191       }
04192     }
04193     if( n_tmp )
04194     {
04195       series->yStats.rms /= (double)(n_tmp);
04196       series->yStats.rms = sqrt(series->yStats.rms);
04197     }
04198   }
04199 
04200   // Always compute stdev 'manually'.
04201   n_tmp = 0;
04202   for( i = 0; i < n; i++ )
04203   {
04204     if( !CPLOT_IsNAN( series->X[i] ) )
04205     {
04206       sumx  += series->X[i];
04207       sumx2 += series->X[i]*series->X[i];
04208       n_tmp++;
04209     }
04210   }  
04211   if( CPLOT_IsPostiveINF( sumx2 ) )
04212   {
04213     series->xStats.stdev = sumx2;
04214   }
04215   else
04216   {
04217     series->xStats.stdev = (n_tmp*sumx2 - sumx*sumx) / (n_tmp*(n_tmp-1.0)); // variance
04218     series->xStats.stdev = sqrt(series->xStats.stdev);  
04219   }
04220 
04221   n_tmp = 0;
04222   sumx = 0;
04223   sumx2 = 0;
04224   for( i = 0; i < n; i++ )
04225   {
04226     if( !CPLOT_IsNAN( series->Y[i] ) )
04227     {
04228       sumx  += series->Y[i];
04229       sumx2 += series->Y[i]*series->Y[i];
04230       n_tmp++;
04231     }
04232   }  
04233   if( CPLOT_IsPostiveINF( sumx2 ) )
04234   {
04235     series->xStats.stdev = sumx2;
04236   }
04237   else
04238   {
04239     series->yStats.stdev = (n_tmp*sumx2 - sumx*sumx) / (n_tmp*(n_tmp-1.0)); // variance
04240     series->yStats.stdev = sqrt(series->yStats.stdev);  
04241   }
04242 
04243   return TRUE;
04244 }
04245 
04246 
04247 BOOL CPLOT_DetermineScaleFactors( CPLOT *P, CPLOT_structSeries *Series )
04248 {
04249   double val = 0;
04250   typedef struct 
04251   {
04252     double lowerlimit;
04253     double upperlimit;
04254     double tickstart;
04255     double ticksize;
04256     double tickend;
04257   } _structAxis;
04258   _structAxis x;
04259   _structAxis y;
04260 
04261   if( !P )
04262     return FALSE;
04263 
04264   // First deal with the upper and lower limits and the tick values.
04265   //
04266 
04267   // Special case - all defaults indicated
04268   if( !P->mOptions.x.lowerlimit.doNotUseDefault &&
04269     !P->mOptions.x.upperlimit.doNotUseDefault &&
04270     !P->mOptions.x.tickstart.doNotUseDefault &&
04271     !P->mOptions.x.tickend.doNotUseDefault )
04272   {
04273     val = Series->xStats.min;
04274     if( val < 0 )
04275     {
04276       val = -ceil( -val * 10.0 ) / 10.0;
04277     }
04278     else
04279     {
04280       val = floor( val * 10.0 ) / 10.0;        
04281     }
04282     x.lowerlimit = val;
04283     
04284     val = Series->xStats.max;
04285     if( val < 0 )
04286     {
04287       val = -floor( -val * 10.0 ) / 10.0;      
04288     }
04289     else
04290     {
04291       val = ceil( val * 10.0 ) / 10.0;        
04292     }
04293     x.upperlimit = val;
04294 
04295     
04296     if( x.lowerlimit == x.upperlimit )
04297     {
04298       x.lowerlimit -= x.lowerlimit/100.0;
04299       x.upperlimit += x.upperlimit/100.0;
04300     }
04301         
04302     x.tickstart = x.lowerlimit;
04303     x.ticksize = (x.upperlimit-x.lowerlimit)/5.0; 
04304     x.tickend = x.upperlimit;
04305   }
04306   else 
04307   {  
04308     // deal with mixed or all user specified case
04309 
04310     if( P->mOptions.x.lowerlimit.doNotUseDefault )
04311       x.lowerlimit = P->mOptions.x.lowerlimit.val;
04312     else
04313       x.lowerlimit = Series->xStats.min;
04314 
04315     if( P->mOptions.x.upperlimit.doNotUseDefault )
04316       x.upperlimit = P->mOptions.x.upperlimit.val;
04317     else
04318       x.upperlimit = Series->xStats.max;
04319 
04320     if( P->mOptions.x.tickstart.doNotUseDefault )
04321       x.tickstart = P->mOptions.x.tickstart.val;
04322     else
04323       x.tickstart = x.lowerlimit;
04324 
04325     if( P->mOptions.x.tickend.doNotUseDefault )
04326       x.tickend = P->mOptions.x.tickend.val;
04327     else
04328       x.tickend = x.upperlimit;
04329 
04330     if( P->mOptions.x.ticksize.doNotUseDefault )
04331       x.ticksize = P->mOptions.x.ticksize.val;
04332     else
04333       x.ticksize = (x.tickend - x.tickstart)/5.0;
04334   }
04335   if( x.lowerlimit == x.upperlimit )
04336     return FALSE;
04337   if( x.tickstart == x.tickend )
04338     return FALSE;
04339   if( x.ticksize <= 0.0 )
04340     return FALSE;
04341 
04342 
04343 
04344   // Special case - all defaults indicated
04345   if( !P->mOptions.y.lowerlimit.doNotUseDefault &&
04346     !P->mOptions.y.upperlimit.doNotUseDefault &&
04347     !P->mOptions.y.tickstart.doNotUseDefault &&
04348     !P->mOptions.y.tickend.doNotUseDefault )
04349   {
04350     val = Series->yStats.min;
04351     if( val < 0 )
04352     {
04353       val = -ceil( -val * 10.0 ) / 10.0;
04354     }
04355     else
04356     {
04357       val = floor( val * 10.0 ) / 10.0;        
04358     }
04359     y.lowerlimit = val;
04360     
04361     val = Series->yStats.max;
04362     if( val < 0 )
04363     {
04364       val = -floor( -val * 10.0 ) / 10.0;      
04365     }
04366     else
04367     {
04368       val = ceil( val * 10.0 ) / 10.0;        
04369     }
04370     y.upperlimit = val;
04371 
04372     
04373     if( y.lowerlimit == y.upperlimit )
04374     {
04375       y.lowerlimit -= y.lowerlimit/100.0;
04376       y.upperlimit += y.upperlimit/100.0;
04377     }
04378         
04379     y.tickstart = y.lowerlimit;
04380     y.ticksize = (y.upperlimit-y.lowerlimit)/10.0; 
04381     y.tickend = y.upperlimit;
04382   }
04383   else 
04384   {  
04385     // deal with mixed or all user specified case
04386 
04387     if( P->mOptions.y.lowerlimit.doNotUseDefault )
04388       y.lowerlimit = P->mOptions.y.lowerlimit.val;
04389     else
04390       y.lowerlimit = Series->yStats.min;
04391 
04392     if( P->mOptions.y.upperlimit.doNotUseDefault )
04393       y.upperlimit = P->mOptions.y.upperlimit.val;
04394     else
04395       y.upperlimit = Series->yStats.max;
04396 
04397     if( P->mOptions.y.tickstart.doNotUseDefault )
04398       y.tickstart = P->mOptions.y.tickstart.val;
04399     else
04400       y.tickstart = y.lowerlimit;
04401 
04402     if( P->mOptions.y.tickend.doNotUseDefault )
04403       y.tickend = P->mOptions.y.tickend.val;
04404     else
04405       y.tickend = y.upperlimit;
04406 
04407     if( P->mOptions.y.ticksize.doNotUseDefault )
04408       y.ticksize = P->mOptions.y.ticksize.val;
04409     else
04410       y.ticksize = (y.tickend - y.tickstart)/10.0;
04411   }
04412   if( y.lowerlimit == y.upperlimit )
04413     return FALSE;
04414   if( y.tickstart == y.tickend )
04415     return FALSE;  
04416   if( y.ticksize <= 0.0 )
04417     return FALSE;
04418 
04419   // All the values for lower, upper, and ticks are now set.
04420 
04421   P->mOptions.x.lowerlimit.val = x.lowerlimit;
04422   P->mOptions.x.upperlimit.val = x.upperlimit;
04423   P->mOptions.x.tickstart.val = x.tickstart;
04424   P->mOptions.x.ticksize.val = x.ticksize;
04425   P->mOptions.x.tickend.val = x.tickend;
04426 
04427   P->mOptions.x.lowerlimit.doNotUseDefault = TRUE;
04428   P->mOptions.x.upperlimit.doNotUseDefault = TRUE;
04429   P->mOptions.x.tickstart.doNotUseDefault = TRUE;
04430   P->mOptions.x.ticksize.doNotUseDefault = TRUE;
04431   P->mOptions.x.tickend.doNotUseDefault = TRUE;
04432 
04433   P->mOptions.y.lowerlimit.val = y.lowerlimit;
04434   P->mOptions.y.upperlimit.val = y.upperlimit;
04435   P->mOptions.y.tickstart.val = y.tickstart;
04436   P->mOptions.y.ticksize.val = y.ticksize;
04437   P->mOptions.y.tickend.val = y.tickend;
04438 
04439   P->mOptions.y.lowerlimit.doNotUseDefault = TRUE;
04440   P->mOptions.y.upperlimit.doNotUseDefault = TRUE;
04441   P->mOptions.y.tickstart.doNotUseDefault = TRUE;
04442   P->mOptions.y.ticksize.doNotUseDefault = TRUE;
04443   P->mOptions.y.tickend.doNotUseDefault = TRUE;
04444 
04445 
04446   P->mData.RangeX = x.upperlimit - x.lowerlimit;
04447   P->mData.RangeY = y.upperlimit - y.lowerlimit;
04448   
04449   if( CPLOT_IsPostiveINF( P->mData.RangeX ) )
04450   {
04451     return FALSE;
04452   }
04453   if( CPLOT_IsPostiveINF( P->mData.RangeY ) )
04454   {
04455     return FALSE;
04456   }
04457 
04458   if( P->mData.RangeX == 0.0 )
04459     P->mData.RangeX = 0.1;
04460   if( P->mData.RangeY == 0.0 )
04461     P->mData.RangeY = 0.1;
04462 
04463   P->mData.OnePercentRangeX = P->mData.RangeX / 100.0;
04464   P->mData.OnePercentRangeY = P->mData.RangeY / 100.0;
04465   P->mData.ScaleX  = P->mAxes.Width  / P->mData.RangeX;
04466   P->mData.ScaleY  = P->mAxes.Height / P->mData.RangeY;
04467 
04468   P->mData.MinX = x.lowerlimit;
04469   P->mData.MaxX = x.upperlimit;
04470   P->mData.MinY = y.lowerlimit;
04471   P->mData.MaxY = y.upperlimit;
04472 
04473   P->mData.xtickstart = x.tickstart;
04474   P->mData.xtickend   = x.tickend;
04475   P->mData.ytickstart = y.tickstart;
04476   P->mData.ytickend   = y.tickend;
04477 
04478   P->mData.xticksize = x.ticksize;
04479   P->mData.yticksize = y.ticksize;
04480 
04481   return TRUE;
04482 }
04483 
04484 
04485 BOOL CPLOT_GPSLabel( CPLOT *P, double tow, const int x )
04486 {
04487   // for gpslabel
04488   int sec_since_midnight = 0,
04489     hour    = 0,
04490     minute  = 0,
04491     second  = 0,
04492     scount  = 0;
04493   char timeString[64];
04494 
04495   if( !P )
04496     return FALSE;
04497 
04498   if( tow < 0 )
04499     return FALSE;
04500 
04501   tow += P->mOptions.UTCOffset;
04502 
04503   sec_since_midnight = (int)floor( fmod( tow, 86400.0 ) );
04504   hour = sec_since_midnight / 3600;
04505   sec_since_midnight -= hour*3600;
04506 
04507   minute = sec_since_midnight / 60;
04508   sec_since_midnight -= minute*60;
04509   second = sec_since_midnight;
04510 
04511   if( hour < 10 )
04512   {
04513 #ifndef _CRT_SECURE_NO_DEPRECATE
04514     scount += sprintf_s( timeString+scount, 64-scount, "0%d:", hour );
04515 #else
04516     scount += sprintf( timeString+scount, "0%d:", hour );
04517 #endif
04518   }
04519   else 
04520   {
04521 #ifndef _CRT_SECURE_NO_DEPRECATE
04522     scount += sprintf_s( timeString+scount, 64-scount, "%d:", hour );
04523 #else
04524     scount += sprintf( timeString+scount, "%d:", hour );
04525 #endif
04526   }
04527   if( minute < 10 )
04528   {
04529 #ifndef _CRT_SECURE_NO_DEPRECATE
04530     scount += sprintf_s( timeString+scount, 64-scount, "0%d:", minute );
04531 #else
04532     scount += sprintf( timeString+scount, "0%d:", minute );
04533 #endif
04534   }
04535   else
04536   {
04537 #ifndef _CRT_SECURE_NO_DEPRECATE
04538     scount += sprintf_s( timeString+scount, 64-scount, "%d:", minute );
04539 #else
04540     scount += sprintf( timeString+scount, "%d:", minute );
04541 #endif
04542   }
04543   if( second < 10 )
04544   {
04545 #ifndef _CRT_SECURE_NO_DEPRECATE
04546     scount += sprintf_s( timeString+scount, 64-scount, "0%d", second );
04547 #else
04548     scount += sprintf( timeString+scount, "0%d", second );
04549 #endif
04550   }
04551   else
04552   {
04553 #ifndef _CRT_SECURE_NO_DEPRECATE
04554     scount += sprintf_s( timeString+scount, 64-scount, "%d", second );
04555 #else
04556     scount += sprintf( timeString+scount, "%d", second );
04557 #endif
04558   }
04559 
04560   if( !CPLOT_DrawString( P, timeString, x, P->mAxes.StartY - 20, TRUE, FALSE, CPLOT_BLACK ) )
04561     return FALSE;
04562 
04563   return TRUE;
04564 }
04565 
04566 
04567 BOOL CPLOT_Title( 
04568   CPLOT *P,
04569   const char* title 
04570   )
04571 {  
04572   int length;
04573   int hpos;
04574 
04575   if( !P )
04576     return FALSE;
04577   if( !title )
04578     return FALSE;
04579 
04580   length = (int)strlen(title)*CPLOT_SMALLFONT_WIDTH;
04581 
04582   hpos = P->mAxes.StartX/2 + (P->mAxes.Width - length) / 2; 
04583 
04584   if( hpos < 0 ) // title is too long    
04585     return TRUE;
04586 
04587   if( !CPLOT_DrawString( P, title, hpos, P->mAxes.FinishY + 30, TRUE, FALSE, CPLOT_BLACK ) )
04588     return FALSE;
04589 
04590   return TRUE;
04591 }
04592 
04593 BOOL CPLOT_xLabel( 
04594   CPLOT *P,
04595   const char* label 
04596   )
04597 {
04598   int length;
04599   int hpos;
04600 
04601   if( !P )
04602     return FALSE;
04603   if( !label )
04604     return FALSE;
04605 
04606   length = (int)strlen(label)*CPLOT_SMALLFONT_WIDTH;
04607 
04608   hpos = P->mAxes.StartX/2 + (P->mAxes.Width - length) / 2; 
04609 
04610   if( hpos < 0 ) // label is too long
04611     return TRUE;
04612 
04613   if( !CPLOT_DrawString( P, label, hpos, P->mAxes.StartY - 35, TRUE, FALSE, CPLOT_BLACK ) )
04614     return FALSE;
04615 
04616   return TRUE;
04617 }
04618 
04619 
04620 BOOL CPLOT_yLabel( 
04621   CPLOT *P,
04622   const char* label, 
04623   BOOL onLeft 
04624   )
04625 {
04626   int length;
04627   int vpos;
04628 
04629   if( !P )
04630     return FALSE;
04631   if( !label )
04632     return FALSE;
04633 
04634   length = (int)strlen(label)*CPLOT_SMALLFONT_WIDTH;   
04635 
04636   vpos = P->mAxes.StartY + (P->mAxes.Height - length) / 2; 
04637 
04638   if( vpos < 0 ) // label is too long
04639     return TRUE;
04640 
04641   if( onLeft )
04642   {
04643     if( !CPLOT_DrawString( P, label, 8, vpos, TRUE, TRUE, CPLOT_BLACK ) )
04644       return FALSE;
04645   }
04646   else
04647   {
04648     if( !CPLOT_DrawString( P, label, P->mAxes.FinishX+80, vpos, TRUE, TRUE, P->mOptions.RightYLabelColor ) )
04649       return FALSE;
04650   }
04651   return TRUE;
04652 }
04653 
04654 
04655 
04656 BOOL CPLOT_DrawPoint( 
04657   CPLOT *P,
04658   const int x, 
04659   const int y,
04660   const CPLOT_enumColor color 
04661   )
04662 {
04663   int i;
04664   int j;
04665 
04666   if( !P )
04667     return FALSE;
04668 
04669   if( y < 3 )
04670     return TRUE;
04671 
04672   if( x + 3 >= P->mImage.Width )
04673     return TRUE;
04674 
04675   for( i = 0; i < CPLOT_POINT_SIZE; i++ )
04676   {
04677     for( j = 0; j < CPLOT_POINT_SIZE; j++ )
04678     {
04679       // Only draw the point, the rest is transparent.
04680       if( CPLOT_Point[i][j] )
04681       {
04682         if( y-i+2 >= (int)P->mPlotData.nrows )
04683           return FALSE;
04684         if( x+j-2 >= (int)P->mPlotData.ncols )
04685           return FALSE;        
04686         P->mPlotData.data[y-i+2][x+j-2] = color;
04687       }
04688     }
04689   }
04690   return TRUE;
04691 }
04692 
04693 
04694 
04695 BOOL CPLOT_DrawLargePoint( 
04696   CPLOT *P,
04697   const int x, 
04698   const int y,
04699   const CPLOT_enumColor color 
04700   )
04701 {
04702   int i;
04703   int j;
04704 
04705   if( !P )
04706     return FALSE;
04707   
04708   if( y < 3 )
04709     return TRUE;
04710   
04711   if( x + 3 >= P->mImage.Width )
04712     return TRUE;
04713 
04714   for( i = 0; i < CPLOT_LARGEPOINT_SIZE; i++ )
04715   {
04716     for( j = 0; j < CPLOT_LARGEPOINT_SIZE; j++ )
04717     {
04718       // Only draw the point, the rest is transparent.
04719       if( CPLOT_LargePoint[i][j] )
04720       {
04721         if( y-i+2 >= (int)P->mPlotData.nrows )
04722           return FALSE;
04723         if( x+j-2 >= (int)P->mPlotData.ncols )
04724           return FALSE;
04725         P->mPlotData.data[y-i+2][x+j-2] = color;
04726       }
04727     }
04728   }
04729   return TRUE;
04730 }
04731 
04732 
04733 
04734 
04735 
04736 BOOL CPLOT_DrawLegendLabel( 
04737   CPLOT *P,
04738   const char* label,
04739   const char* units,
04740   const CPLOT_enumColor color 
04741   )
04742 {
04743   int ypos = 0;
04744   int xpos = 0;
04745   int xoffset = P->mRightYLabelAllowance + 47;
04746   char buffer[128];
04747 
04748   if( !P )
04749     return FALSE;
04750   if( !label )
04751     return FALSE;
04752 
04753   if( strlen(label) < 1 )
04754     return FALSE;
04755   
04756   if( P->mOptions.plotLabelOnRight )
04757   {
04758     if( P->mOptions.plotStatistics )
04759     {
04760       switch( P->mSeriesIndex )
04761       {
04762       case 0:
04763       case 1:
04764       case 2: 
04765         xpos = P->mAxes.FinishX + xoffset + P->mSeriesIndex*P->mLabelWidth;
04766         ypos = P->mAxes.FinishY - 8; 
04767         break;
04768       case 3:
04769       case 4:
04770       case 5: 
04771         xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-3)*P->mLabelWidth;
04772         ypos = P->mAxes.FinishY - 8 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
04773         break;
04774       case 6:
04775       case 7:
04776       case 8: 
04777         xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-6)*P->mLabelWidth;
04778         ypos = P->mAxes.FinishY - 8 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
04779         break;
04780       case 9:
04781       case 10:
04782       case 11: 
04783         xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-9)*P->mLabelWidth;
04784         ypos = P->mAxes.FinishY - 8 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
04785         break;          
04786       default: 
04787         return TRUE; // no more than 12 series possible               
04788       }         
04789       if( !CPLOT_DrawLargePoint( P, xpos - 5, ypos-6, color ) )
04790         return FALSE;
04791       //DrawPoint( xpos - 6, ypos-6, color );
04792       //DrawPoint( xpos - 4, ypos-6, color );
04793       if( !CPLOT_DrawString( P, label, xpos, ypos, TRUE, FALSE, color ) )
04794         return FALSE;
04795       if( !CPLOT_DrawString( P, units, xpos, ypos - P->mStatsValueHeight, TRUE, FALSE, color ) )
04796         return FALSE;
04797     }
04798     else
04799     {
04800       xpos = P->mAxes.FinishX + P->mRightYLabelAllowance;         
04801       ypos = P->mAxes.FinishY - 16*(P->mSeriesIndex) - P->mStatsValueHeight*8;
04802       if( !CPLOT_DrawLargePoint( P, xpos - 8, ypos, color ) )
04803         return FALSE;
04804       //DrawPoint( xpos - 6, ypos, color );
04805       //DrawPoint( xpos - 4, ypos, color );
04806       if( units && label )
04807       {
04808 #ifndef _CRT_SECURE_NO_DEPRECATE
04809         sprintf_s( buffer, 128, "%s %s", label, units );
04810 #else
04811         sprintf( buffer, "%s %s", label, units );
04812 #endif
04813       }
04814       else if ( label )
04815       {
04816 #ifndef _CRT_SECURE_NO_DEPRECATE
04817         sprintf_s( buffer, 128, "%s", label );
04818 #else
04819         sprintf( buffer, "%s", label );
04820 #endif
04821       }
04822       else
04823         buffer[0] = '\0';
04824       if( !CPLOT_DrawString( P, buffer, xpos, ypos + 3, TRUE, FALSE, CPLOT_BLACK ) )
04825         return FALSE;
04826     }
04827   }
04828   else
04829   {
04830     xpos = 16;      
04831     ypos = P->mAxes.StartY - P->mXLabelAllowance - 8 - P->mStatsValueHeight*(P->mSeriesIndex+1);      
04832     if( !CPLOT_DrawLargePoint( P, xpos - 8, ypos - 5, color ) )
04833       return FALSE;
04834     //DrawPoint( xpos - 6, ypos - 5, color );
04835     //DrawPoint( xpos - 4, ypos - 5, color );
04836     if( !CPLOT_DrawString( P, label, xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
04837       return FALSE;
04838     if( !CPLOT_DrawString( P, units, 600, ypos, TRUE, FALSE, color ) )
04839       return FALSE;
04840   }
04841   return TRUE;
04842 }
04843 
04844 
04845 
04846 
04847 
04848 BOOL CPLOT_DrawAxes( 
04849   CPLOT *P,
04850   CPLOT_structSeries *Series,
04851   const CPLOT_enumColor color 
04852   )
04853 {
04854   double x = 0.0;
04855   double y = 0.0;
04856 
04857   double xTickRange = 0;
04858   double yTickRange = 0;
04859   
04860   int xtick;
04861   int ytick;
04862 
04863 
04864   // resize the figure if needed
04865   if( !CPLOT_ResizePlot(P) )
04866     return FALSE;
04867 
04868   // GDM_TODO - What is the point of this part?
04869   if( !P->mOptions.redrawAxes )
04870   {
04871     CPLOT_BYTE_MTX_Fill( &(P->mPlotData), P->mOptions.figureBackgroundColor );
04872   }
04873     
04874 
04875   // first draw the box   
04876   if( !CPLOT_DrawLine( P, P->mAxes.StartX,  P->mAxes.StartY,  P->mAxes.FinishX, P->mAxes.StartY, color) )  //bottom
04877     return FALSE;
04878   if( !CPLOT_DrawLine( P, P->mAxes.StartX,  P->mAxes.StartY,  P->mAxes.StartX,  P->mAxes.FinishY, color) ) //left side
04879     return FALSE;
04880   if( !CPLOT_DrawLine( P, P->mAxes.StartX,  P->mAxes.FinishY, P->mAxes.FinishX, P->mAxes.FinishY, color) ) //top
04881     return FALSE;
04882   if( !CPLOT_DrawLine( P, P->mAxes.FinishX, P->mAxes.StartY,  P->mAxes.FinishX, P->mAxes.FinishY, color) ) //right side
04883     return FALSE;
04884 
04885   // determine the mapping scale factors
04886   if( !CPLOT_DetermineScaleFactors( P, Series ) )
04887     return FALSE;
04888 
04889   xTickRange = P->mData.xtickend - P->mData.xtickstart;
04890   yTickRange = P->mData.ytickend - P->mData.ytickstart;
04891 
04892   // plot the xticks   
04893   for( x = P->mData.xtickstart; x <= P->mData.xtickend + P->mData.OnePercentRangeX; x += P->mData.xticksize )
04894   {
04895     if( Series->xStats.range > 1e-6 )
04896     {
04897       if( fabs(x) < 1e-6 )
04898         x = 0;
04899     }
04900     xtick = (int)( (x   - P->mData.MinX)*P->mData.ScaleX ) + P->mAxes.StartX;
04901 
04902     if( !CPLOT_DrawLine( P, xtick, P->mAxes.StartY,                               xtick, P->mAxes.StartY  + P->mAxes.TickDashInPixels, CPLOT_BLACK ) ) // bottom ticks
04903       return FALSE;
04904     if( !CPLOT_DrawLine( P, xtick, P->mAxes.FinishY - P->mAxes.TickDashInPixels , xtick, P->mAxes.FinishY,                          CPLOT_BLACK ) ) // top ticks      
04905       return FALSE;
04906 
04907     if( P->mOptions.x.label )
04908     {
04909       if( !CPLOT_DrawValue( P, TRUE,  x, xtick - 3, P->mAxes.StartY - 5, color ) )
04910         return FALSE;
04911 
04912       if( P->mOptions.useGPSLabel )
04913         CPLOT_GPSLabel( P, x, xtick - 3  );
04914     }
04915     if( P->mOptions.x.isGridOn )
04916     {
04917       if( !CPLOT_DrawDashedLine( P, xtick, P->mAxes.StartY,  xtick, P->mAxes.FinishY, 2, color ) )
04918         return FALSE;
04919     }
04920   }
04921 
04922   // plot the yticks
04923   for( y = P->mData.ytickstart; y <= P->mData.ytickend + P->mData.OnePercentRangeY; y += P->mData.yticksize )
04924   {
04925     if( Series->yStats.range > 1e-6 )
04926     {
04927       if( fabs(y) < 1e-6 )
04928         y = 0;
04929     }    
04930     ytick = (int)( (y   - P->mData.MinY)*P->mData.ScaleY ) + P->mAxes.StartY;
04931 
04932     if( !CPLOT_DrawLine( P, P->mAxes.StartX,                              ytick, P->mAxes.StartX  + P->mAxes.TickDashInPixels, ytick, color ) )
04933       return FALSE;
04934     if( !CPLOT_DrawLine( P, P->mAxes.FinishX - P->mAxes.TickDashInPixels, ytick, P->mAxes.FinishX,                             ytick, color ) )
04935       return FALSE;
04936 
04937     if( P->mOptions.y.label )         
04938     {
04939       if( !CPLOT_DrawValue( P, FALSE,  y, P->mAxes.StartX - CPLOT_SMALLFONT_WIDTH*15, ytick + 7, color ) )
04940         return FALSE;
04941     }
04942 
04943     if( P->mOptions.y.isGridOn )
04944     {
04945       if( !CPLOT_DrawDashedLine( P, P->mAxes.StartX, ytick, P->mAxes.FinishX, ytick, 2, color ) )
04946         return FALSE;
04947     }
04948 
04949     if( P->mOptions.y_label_right != NULL )
04950     {
04951       double value = y / P->mOptions.y_label_right_scale_factor - P->mOptions.y_label_right_bias;
04952       if( !CPLOT_DrawValue( P, TRUE,  value, P->mAxes.FinishX + 3, ytick + 7, P->mOptions.RightYLabelColor ) )
04953         return FALSE;
04954     }
04955   }
04956 
04957 
04958   // draw title, labels and such
04959   if( P->mOptions.title )
04960     if( !CPLOT_Title( P, P->mOptions.title ) )
04961       return FALSE;
04962   if( P->mOptions.x.label )
04963     if( !CPLOT_xLabel( P, P->mOptions.x.label ) )
04964       return FALSE;
04965   if( P->mOptions.y.label )
04966     if( !CPLOT_yLabel( P, P->mOptions.y.label, TRUE ) )
04967       return FALSE;
04968   if( P->mOptions.y_label_right )
04969     if( !CPLOT_yLabel( P, P->mOptions.y_label_right, FALSE ) )
04970       return FALSE;
04971   
04972   return TRUE;
04973 }
04974 
04975 
04976 
04977 BOOL CPLOT_DrawStatsValue(
04978   CPLOT *P,
04979   double value, 
04980   const int left, 
04981   const int top,
04982   const CPLOT_enumColor color,
04983   const int precision 
04984   )
04985 {
04986   char formatBuffer[48];
04987   char ValueBuffer[48];
04988   ValueBuffer[0] = '\0';
04989 
04990   if( !P )
04991     return FALSE;
04992 
04993 #ifndef _CRT_SECURE_NO_DEPRECATE
04994   sprintf_s( formatBuffer, 48, "%%%d.%dg", P->mLabelWidth/CPLOT_SMALLFONT_WIDTH, precision );
04995   sprintf_s( ValueBuffer, 48, formatBuffer, value );
04996 #else
04997   sprintf( formatBuffer, "%%%d.%dg", P->mLabelWidth/CPLOT_SMALLFONT_WIDTH, precision );
04998   sprintf( ValueBuffer, formatBuffer, value );
04999 #endif
05000 
05001   /*
05002   if( fabs(value) < 1e-12 )
05003     value = 0.0;
05004 
05005   if( fabs(value) > 1.0e+8 || (fabs(value) < 1.0e-8 && value != 0.0) )
05006   {      
05007     sprintf( formatBuffer, "%%-%d.%de", P->mStatsValueHeight, decimalPrecision );
05008     sprintf( ValueBuffer, formatBuffer, value );
05009   }
05010   else
05011   {      
05012     sprintf( formatBuffer, "%%-%d.%df", P->mStatsValueHeight, decimalPrecision );
05013     sprintf( ValueBuffer, formatBuffer, value );
05014   } 
05015   */
05016 
05017   if( (left + P->mLabelWidth) >= P->mImage.Width )
05018     return TRUE;
05019   if( top >= P->mImage.Height )
05020     return TRUE;
05021 
05022   if( !CPLOT_DrawString( P, ValueBuffer, left, top, TRUE, FALSE, color ) )
05023     return FALSE;
05024 
05025   return TRUE;
05026 }
05027 
05028 BOOL CPLOT_DrawStats( 
05029   CPLOT *P,
05030   CPLOT_structSeries* Series 
05031   )
05032 {
05033   int ypos = 0,
05034     xpos = 0,
05035     boxwidth  = 45,
05036     boxheight = 0,
05037     yoffset = 0,
05038     xoffset = 0,
05039     i = 0;
05040 
05041   int high;
05042   int low;
05043 
05044 
05045   if( !P )
05046     return FALSE;
05047   if( !Series )
05048     return FALSE;
05049 
05050   boxheight = P->mStatsValueHeight*7+1;
05051 
05052   if( P->mOptions.plotLabelOnRight )
05053   {
05054     switch( P->mSeriesIndex )
05055     {
05056     case 0:
05057     case 1:
05058     case 2:  ypos = P->mAxes.FinishY - 6; break;
05059     default: ypos = P->mAxes.FinishY - 6 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8); break;
05060       /*
05061       case 3:
05062       case 4:
05063       case 5: ypos = mAxes.FinishY - 6 - (mSeriesIndex/3)*(mStatsValueHeight*8); break;
05064       case 6:
05065       case 7:
05066       case 8: ypos = mAxes.FinishY - 6 - (mSeriesIndex/3)*(mStatsValueHeight*8); break;
05067       case 9:
05068       case 10:
05069       case 11: ypos = mAxes.FinishY - 6 - (mSeriesIndex/3)*(mStatsValueHeight*8); break;
05070       default: return; // no more than 9 series possible
05071       */
05072     }
05073 
05074     // plot the box around the labels (units, min, max, mean, RMS, Stdev)
05075     xpos = P->mAxes.FinishX + P->mRightYLabelAllowance - 10;
05076     if( !CPLOT_DrawLine( P, xpos - 2,        ypos - boxheight, xpos -  2,       ypos,              CPLOT_LIGHTGREY ) )
05077       return FALSE;
05078     if( !CPLOT_DrawLine( P, xpos + boxwidth, ypos - boxheight, xpos + boxwidth, ypos,              CPLOT_LIGHTGREY ) )
05079       return FALSE;
05080     if( !CPLOT_DrawLine( P, xpos - 2,        ypos,             xpos + boxwidth, ypos,              CPLOT_LIGHTGREY ) )
05081       return FALSE;
05082     if( !CPLOT_DrawLine( P, xpos - 2,        ypos - boxheight, xpos + boxwidth, ypos - boxheight,  CPLOT_LIGHTGREY ) )
05083       return FALSE;
05084 
05085     // plot the horizontal lines for the labels on the left
05086     ypos -= 5;
05087     ypos -= P->mStatsValueHeight;
05088     for( i = 0; i < 6; i++ )
05089     {
05090       if( !CPLOT_DrawLine( 
05091         P, 
05092         xpos - 2,      
05093         ypos + 5 - P->mStatsValueHeight*i,
05094         xpos + boxwidth,
05095         ypos + 5 - P->mStatsValueHeight*i,
05096         CPLOT_LIGHTGREY ) )
05097       {
05098         return FALSE;
05099       }
05100     }
05101     ypos += 2;
05102     //if( !CPLOT_DrawString( P, "Units", xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05103     //  return FALSE;
05104     ypos -= P->mStatsValueHeight;
05105     if( !CPLOT_DrawString( P, "Min",   xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05106       return FALSE;
05107     ypos -= P->mStatsValueHeight;
05108     if( !CPLOT_DrawString( P, "Max",   xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05109       return FALSE;
05110     ypos -= P->mStatsValueHeight;
05111     if( !CPLOT_DrawString( P, "Mean",  xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05112       return FALSE;
05113     ypos -= P->mStatsValueHeight;
05114     if( !CPLOT_DrawString( P, "RMS",   xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05115       return FALSE;
05116     ypos -= P->mStatsValueHeight;
05117     if( !CPLOT_DrawString( P, "\\sigma", xpos, ypos, TRUE, FALSE, CPLOT_BLACK ) )
05118       return FALSE;
05119 
05120 
05121     xoffset = P->mRightYLabelAllowance + 37;
05122     switch( P->mSeriesIndex )
05123     {
05124     case 0:
05125     case 1:
05126     case 2:
05127       xpos = P->mAxes.FinishX + xoffset + P->mSeriesIndex*P->mLabelWidth;
05128       ypos = P->mAxes.FinishY - 6; 
05129       break;
05130     case 3:
05131     case 4:
05132     case 5:
05133       xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-3)*P->mLabelWidth;
05134       ypos = P->mAxes.FinishY - 6 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
05135       break;
05136     case 6:
05137     case 7:
05138     case 8:
05139       xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-6)*P->mLabelWidth;
05140       ypos = P->mAxes.FinishY - 6 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
05141       break;
05142     case 9:
05143     case 10:
05144     case 11:
05145       xpos = P->mAxes.FinishX + xoffset + (P->mSeriesIndex-9)*P->mLabelWidth;
05146       ypos = P->mAxes.FinishY - 6 - (P->mSeriesIndex/3)*(P->mStatsValueHeight*8);
05147       break;
05148     default: 
05149       return FALSE; // no more than 12 series possible            
05150     }         
05151 
05152     if( !CPLOT_DrawLine( P, xpos + P->mLabelWidth, ypos - boxheight, xpos + P->mLabelWidth, ypos,             CPLOT_LIGHTGREY ) )
05153       return FALSE;
05154     if( !CPLOT_DrawLine( P, xpos - 2,              ypos,             xpos + P->mLabelWidth, ypos,             CPLOT_LIGHTGREY ) )
05155       return FALSE;
05156     if( !CPLOT_DrawLine( P, xpos - 2,              ypos - boxheight, xpos + P->mLabelWidth, ypos - boxheight, CPLOT_LIGHTGREY ) )
05157       return FALSE;  
05158 
05159     ypos -= P->mStatsValueHeight*2 + 5;
05160     for( i = 0; i < 5; i++ )
05161     {
05162       if( !CPLOT_DrawLine( 
05163         P, 
05164         xpos - 2,       
05165         ypos + 5 - P->mStatsValueHeight*i, 
05166         xpos + P->mLabelWidth, 
05167         ypos + 5 - P->mStatsValueHeight*i,
05168         CPLOT_LIGHTGREY ) )
05169       {
05170         return FALSE;
05171       }
05172     }
05173 
05174     xpos += 3;
05175     ypos += 2;
05176     if( !CPLOT_DrawStatsValue( P, Series->yStats.min, xpos, ypos, Series->color, Series->precision ) )
05177       return FALSE;    
05178     ypos -= P->mStatsValueHeight;         
05179     if( !CPLOT_DrawStatsValue( P, Series->yStats.max, xpos, ypos, Series->color, Series->precision ) )
05180       return FALSE;
05181     ypos -= P->mStatsValueHeight;         
05182     if( !CPLOT_DrawStatsValue( P, Series->yStats.mean, xpos, ypos, Series->color, Series->precision ) )
05183       return FALSE;    
05184     ypos -= P->mStatsValueHeight;         
05185     if( !CPLOT_DrawStatsValue( P, Series->yStats.rms, xpos, ypos, Series->color, Series->precision ) )
05186       return FALSE;    
05187     ypos -= P->mStatsValueHeight;  
05188     if( !CPLOT_DrawStatsValue( P, Series->yStats.stdev, xpos, ypos, Series->color, Series->precision ) )
05189       return FALSE;        
05190   }
05191   else
05192   {
05193     yoffset = P->mXLabelAllowance + 6;
05194     high = P->mAxes.StartY - yoffset;
05195     low  = P->mAxes.StartY - yoffset - P->mStatsValueHeight;
05196 
05197     if( !CPLOT_DrawString( P, "Min",    200, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05198       return FALSE;
05199     if( !CPLOT_DrawLine( P,   6, high, 680, high, CPLOT_LIGHTGREY ) )
05200       return FALSE;
05201     if( !CPLOT_DrawLine( P, 197, low,  197, high, CPLOT_LIGHTGREY ) )
05202       return FALSE;
05203 
05204     if( !CPLOT_DrawString( P, "Max",    280, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05205       return FALSE;
05206     if( !CPLOT_DrawLine( P, 277, low, 277, high, CPLOT_LIGHTGREY ) )
05207       return FALSE;
05208 
05209     if( !CPLOT_DrawString( P, "Mean",   360, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05210       return FALSE;
05211     if( !CPLOT_DrawLine( P, 357, low, 357, high, CPLOT_LIGHTGREY ) )
05212       return FALSE;
05213 
05214     if( !CPLOT_DrawString( P, "RMS",    440, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05215       return FALSE;
05216     if( !CPLOT_DrawLine( P, 437, low, 437, high, CPLOT_LIGHTGREY ) )
05217       return FALSE;
05218 
05219     if( !CPLOT_DrawString( P, "\\sigma",  520, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05220       return FALSE;
05221     if( !CPLOT_DrawLine( P, 517, low, 517, high, CPLOT_LIGHTGREY ) )
05222       return FALSE;
05223 
05224     //if( !CPLOT_DrawString( P, "Units",  600, high-2, TRUE, FALSE, CPLOT_BLACK ) )
05225     //  return FALSE;
05226     if( !CPLOT_DrawLine( P, 597, low, 597, high, CPLOT_LIGHTGREY ) )
05227       return FALSE;
05228 
05229     if( !CPLOT_DrawLine( P, 6, P->mAxes.StartY-yoffset-P->mStatsValueHeight, 680, P->mAxes.StartY-yoffset-P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05230       return FALSE;
05231     if( !CPLOT_DrawLine( P, 6, P->mAxes.StartY-yoffset-P->mStatsValueHeight, 6, P->mAxes.StartY-yoffset, CPLOT_LIGHTGREY ) )
05232       return FALSE;
05233     if( !CPLOT_DrawLine( P, 680, P->mAxes.StartY-yoffset-P->mStatsValueHeight, 680, P->mAxes.StartY-yoffset, CPLOT_LIGHTGREY ) )
05234       return FALSE;
05235 
05236     ypos = P->mAxes.StartY - yoffset - P->mStatsValueHeight*(P->mSeriesIndex+2);
05237 
05238     if( !CPLOT_DrawLine( P, 6,   ypos, 680, ypos, CPLOT_LIGHTGREY ) )
05239       return FALSE;
05240     if( !CPLOT_DrawLine( P, 6,   ypos, 6,   ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05241       return FALSE;
05242     if( !CPLOT_DrawLine( P, 197, ypos, 197, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05243       return FALSE;
05244     if( !CPLOT_DrawLine( P, 277, ypos, 277, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05245       return FALSE;
05246     if( !CPLOT_DrawLine( P, 357, ypos, 357, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05247       return FALSE;
05248     if( !CPLOT_DrawLine( P, 437, ypos, 437, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05249       return FALSE;
05250     if( !CPLOT_DrawLine( P, 517, ypos, 517, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05251       return FALSE;
05252     if( !CPLOT_DrawLine( P, 597, ypos, 597, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05253       return FALSE;
05254     if( !CPLOT_DrawLine( P, 680, ypos, 680, ypos+P->mStatsValueHeight, CPLOT_LIGHTGREY ) )
05255       return FALSE;
05256 
05257     ypos = P->mAxes.StartY - yoffset - 2 - P->mStatsValueHeight*(P->mSeriesIndex+1);
05258 
05259     if( !CPLOT_DrawStatsValue( P, Series->yStats.min, 200, ypos, Series->color, Series->precision ) ) 
05260       return FALSE;
05261     if( !CPLOT_DrawStatsValue( P, Series->yStats.max, 280, ypos, Series->color, Series->precision ) ) 
05262       return FALSE;
05263     if( !CPLOT_DrawStatsValue( P, Series->yStats.mean,   360, ypos, Series->color, Series->precision ) ) 
05264       return FALSE;
05265     if( !CPLOT_DrawStatsValue( P, Series->yStats.rms,    440, ypos, Series->color, Series->precision ) ) 
05266       return FALSE;
05267     if( !CPLOT_DrawStatsValue( P, Series->yStats.stdev,  520, ypos, Series->color, Series->precision ) ) 
05268       return FALSE;
05269 
05270   }
05271   return TRUE;
05272 }
05273 
05274 
05275 
05276 
05277 BOOL CPLOT_FWriteRGB( FILE* out, CPLOT_structRGB val )
05278 {
05279   if( !out )
05280     return FALSE;
05281   fwrite( &val.Blue, sizeof(byte), 1, out ); 
05282   fwrite( &val.Green, sizeof(byte), 1, out ); 
05283   fwrite( &val.Red, sizeof(byte), 1, out ); 
05284   fwrite( &val.Reserved, sizeof(byte), 1, out );
05285   return TRUE;
05286 }
05287 
05288 
05289 /** \brief  The BITMAP file header struct.
05290 
05291 \code
05292 start    size    name       stdvalue    purpose
05293 1        2       Type       19778       must always be set to 'BM' to declare that this is a .bmp-file.
05294 3        4       Size       ??          specifies the size of the file in bytes.
05295 7        2       Reserved1  0           must always be set to zero.
05296 9        2       Reserved2  0           must always be set to zero.
05297 11       4       OffBits    1078        specifies the offset from the beginning of the file to the bitmap data.
05298 \endcode
05299 */
05300 typedef struct 
05301 {
05302   unsigned short  Type;                 // must be BM //0x4D42
05303   unsigned long   Size;                 // size in bytes of the file
05304   unsigned short  Reserved1;            // 0
05305   unsigned short  Reserved2;            // 0
05306   unsigned long   OffsetToBitmapBits;   // offset in bytes from BitmapFileHeader to bitmap bits
05307 } CPLOT_structBitmapFileHeader;
05308 
05309 
05310 /** \brief  The BITMAP file info struct.
05311 
05312 \code
05313 start    size    name            stdvalue  purpose
05314 15       4       Size            40        specifies the size of the BITMAPINFOHEADER structure, in bytes.
05315 19       4       Width           100       specifies the width of the image, in pixels.
05316 23       4       Height          100       specifies the height of the image, in pixels.
05317 27       2       Planes          1         specifies the number of planes of the target device, must be set to zero.
05318 29       2       BitCount        8         specifies the number of bits per pixel.
05319 31       4       Compression     0         Specifies the type of compression, usually set to zero (no compression).
05320 35       4       SizeImage       0         specifies the size of the image data, in bytes. If there is no compression, it is valid to set this member to zero.
05321 39       4       XPelsPerMeter   0         specifies the the horizontal pixels per meter on the designated targer device, usually set to zero.
05322 43       4       YPelsPerMeter   0         specifies the the vertical pixels per meter on the designated targer device, usually set to zero.
05323 47       4       ClrUsed         0         specifies the number of colors used in the bitmap, if set to zero the number of colors is calculated using the biBitCount member.
05324 51       4       ClrImportant    0         specifies the number of color that are 'important' for the bitmap, if set to zero, all colors are important.
05325 \endcode
05326 */
05327 typedef struct 
05328 {
05329   unsigned long   Size; // size of the stBitmapInfoHeader (does not include the color table)
05330   long            Width;
05331   long            Height;
05332   unsigned short  Planes;
05333   unsigned short  BitCount;
05334   unsigned long   Compression;
05335   unsigned long   SizeImage;
05336   long            XPelsPerMeter;
05337   long            YPelsPerMeter;
05338   unsigned long   ClrUsed;
05339   unsigned long   ClrImportant;      
05340 } CPLOT_structBitmapInfoHeader;
05341 
05342 
05343 BOOL CPLOT_SaveToFile( 
05344   CPLOT *P,
05345   const char *FileName 
05346   )
05347 {
05348   int i = 0,
05349     j = 0,
05350     z = 0,
05351     count = 0,    
05352     sizeOfColorTable = 0;
05353   int max_z;
05354 
05355   unsigned compressedSize = 0;
05356 
05357   BOOL first = TRUE;
05358 
05359   byte theByte = 0;
05360   byte last    = 0;
05361 
05362   CPLOT_structByteMatrix CompressedVector;
05363 
05364   FILE* BmpFile = NULL;
05365 
05366   CPLOT_structBitmapFileHeader BitmapFileHeader; 
05367   CPLOT_structBitmapInfoHeader BitmapInfoHeader;
05368   
05369   CPLOT_BYTE_MTX_Init( &CompressedVector );
05370 
05371   // the image width must be divisible by four
05372   if( P->mImage.Width%4 != 0 )
05373     return FALSE;
05374 
05375   memset( &BitmapFileHeader, 0, sizeof(CPLOT_structBitmapFileHeader) ); // don't use preprocesso constants here
05376   memset( &BitmapInfoHeader, 0, sizeof(CPLOT_structBitmapInfoHeader) ); // don't use preprocesso constants here
05377 
05378   BitmapFileHeader.Type = 0x4D42; //BM
05379 
05380   // assuming the default color table
05381   BitmapFileHeader.Size = P->mImage.Width*P->mImage.Height + 
05382     CPLOT_SIZEOF_BITMAPFILEHEADER + 
05383     CPLOT_SIZEOF_BITMAPINFOHEADER +
05384     sizeof(CPLOT_structColorTable); // 22*4, works for 1,2,4,8 byte packing
05385   
05386   BitmapFileHeader.Reserved1 = 0;
05387   BitmapFileHeader.Reserved2 = 0;
05388   BitmapFileHeader.OffsetToBitmapBits = 0; // set later
05389 
05390   BitmapInfoHeader.Size           = CPLOT_SIZEOF_BITMAPINFOHEADER;
05391   BitmapInfoHeader.Width          = P->mImage.Width;  // pixels
05392   BitmapInfoHeader.Height         = P->mImage.Height; // pixels
05393   BitmapInfoHeader.Planes         = 1;
05394   BitmapInfoHeader.BitCount       = 8;
05395   BitmapInfoHeader.Compression    = 0; // set later
05396   BitmapInfoHeader.SizeImage      = P->mImage.Width*P->mImage.Height;
05397   BitmapInfoHeader.XPelsPerMeter  = 0;
05398   BitmapInfoHeader.YPelsPerMeter  = 0;
05399   BitmapInfoHeader.ClrUsed        = 22;
05400   BitmapInfoHeader.ClrImportant   = 22;
05401 
05402 
05403   // compress bitmap using RLE encoding
05404   // possible to be larger than original, so we'll overallocate by 2  
05405   max_z = BitmapInfoHeader.SizeImage*2;
05406   if( max_z > 41943040 ) // about 40 MB 
05407     return FALSE;
05408   CPLOT_BYTE_MTX_calloc( &CompressedVector, 1, max_z );
05409 
05410   // place 2d byte matrix into a vector
05411   for( i = 0; i < (int)P->mPlotData.nrows; i++ )
05412   {      
05413     count = 0;
05414     first = TRUE;
05415     for( j = 0; j < (int)P->mPlotData.ncols; j++ )
05416     {
05417       theByte = P->mPlotData.data[i][j];
05418 
05419       if( first )
05420       {
05421         last = theByte;
05422         count = 1;
05423         first = FALSE;
05424         continue;
05425       }
05426 
05427       if( count == 255 )
05428       {
05429         CompressedVector.data[0][z] = count;
05430         z++;
05431         if( z >= max_z )
05432         {
05433           CPLOT_BYTE_MTX_Free( &CompressedVector );
05434           return FALSE;
05435         }
05436         CompressedVector.data[0][z] = last;
05437         z++;
05438         if( z >= max_z )
05439         {
05440           CPLOT_BYTE_MTX_Free( &CompressedVector );
05441           return FALSE;
05442         }
05443         first = TRUE;
05444         count = 0;
05445         j--;
05446         continue;
05447       }
05448 
05449       if( theByte == last )
05450       {
05451         count++;
05452       }
05453       else
05454       {
05455         CompressedVector.data[0][z] = count;
05456         z++;
05457         if( z >= max_z )
05458         {
05459           CPLOT_BYTE_MTX_Free( &CompressedVector );
05460           return FALSE;
05461         }
05462         CompressedVector.data[0][z] = last;
05463         z++;
05464         if( z >= max_z )
05465         {
05466           CPLOT_BYTE_MTX_Free( &CompressedVector );
05467           return FALSE;
05468         }
05469         count = 1;
05470         last = theByte;
05471       }
05472     }
05473     if( count != 0 )
05474     {
05475       CompressedVector.data[0][z] = count;
05476       z++;
05477       if( z >= max_z )
05478       {
05479         CPLOT_BYTE_MTX_Free( &CompressedVector );
05480         return FALSE;
05481       }
05482       CompressedVector.data[0][z] = last;
05483       z++;
05484       if( z >= max_z )
05485       {
05486         CPLOT_BYTE_MTX_Free( &CompressedVector );
05487         return FALSE;
05488       }
05489     }
05490     if( i != (int)(P->mPlotData.nrows - 1) )
05491     {
05492       CompressedVector.data[0][z] = 0;
05493       z++;
05494       if( z >= max_z )
05495       {
05496         CPLOT_BYTE_MTX_Free( &CompressedVector );
05497         return FALSE;
05498       }
05499       CompressedVector.data[0][z] = 0;
05500       z++;
05501       if( z >= max_z )
05502       {
05503         CPLOT_BYTE_MTX_Free( &CompressedVector );
05504         return FALSE;
05505       }
05506     }      
05507   }
05508 
05509   // indicate end of bitmap
05510   CompressedVector.data[0][z] = 0;
05511   z++;
05512   if( z >= max_z )
05513   {
05514     CPLOT_BYTE_MTX_Free( &CompressedVector );
05515     return FALSE;
05516   }
05517   CompressedVector.data[0][z] = 1;
05518   z++;
05519   if( z >= max_z )
05520   {
05521     CPLOT_BYTE_MTX_Free( &CompressedVector );
05522     return FALSE;
05523   }
05524   compressedSize = z;
05525 
05526   sizeOfColorTable = BitmapInfoHeader.ClrUsed * 4;   
05527   BitmapFileHeader.OffsetToBitmapBits = CPLOT_SIZEOF_BITMAPFILEHEADER + CPLOT_SIZEOF_BITMAPINFOHEADER + sizeOfColorTable; // 14 + 40 + 88
05528 
05529   // check that compressed is better
05530   if( compressedSize < BitmapInfoHeader.SizeImage )
05531   {
05532     BitmapInfoHeader.Compression = 1;
05533     BitmapInfoHeader.SizeImage = compressedSize;
05534     BitmapFileHeader.Size = compressedSize + BitmapFileHeader.OffsetToBitmapBits;
05535   }
05536 
05537 #ifndef _CRT_SECURE_NO_DEPRECATE
05538   if( fopen_s( &BmpFile, FileName, "wb" ) != 0 )
05539   {
05540     CPLOT_BYTE_MTX_Free( &CompressedVector );
05541     return FALSE;
05542   }
05543 #else
05544   BmpFile = fopen(FileName,"wb");
05545   if( !BmpFile )
05546   {
05547     CPLOT_BYTE_MTX_Free( &CompressedVector );
05548     return FALSE;
05549   }
05550 #endif
05551 
05552   // write the header, write basic element at a time to avoid struct member packing issues.
05553   fwrite( &BitmapFileHeader.Type, sizeof(BitmapFileHeader.Type), 1, BmpFile );
05554   fwrite( &BitmapFileHeader.Size, sizeof(BitmapFileHeader.Size), 1, BmpFile );
05555   fwrite( &BitmapFileHeader.Reserved1, sizeof(BitmapFileHeader.Reserved1), 1, BmpFile );
05556   fwrite( &BitmapFileHeader.Reserved2, sizeof(BitmapFileHeader.Reserved2), 1, BmpFile );
05557   fwrite( &BitmapFileHeader.OffsetToBitmapBits, sizeof(BitmapFileHeader.OffsetToBitmapBits), 1, BmpFile );
05558 
05559   fwrite( &BitmapInfoHeader.Size, sizeof(BitmapInfoHeader.Size), 1, BmpFile );
05560   fwrite( &BitmapInfoHeader.Width, sizeof(BitmapInfoHeader.Width), 1, BmpFile );
05561   fwrite( &BitmapInfoHeader.Height, sizeof(BitmapInfoHeader.Height), 1, BmpFile );
05562   fwrite( &BitmapInfoHeader.Planes, sizeof(BitmapInfoHeader.Planes), 1, BmpFile );
05563   fwrite( &BitmapInfoHeader.BitCount, sizeof(BitmapInfoHeader.BitCount), 1, BmpFile );
05564   fwrite( &BitmapInfoHeader.Compression, sizeof(BitmapInfoHeader.Compression), 1, BmpFile );
05565   fwrite( &BitmapInfoHeader.SizeImage, sizeof(BitmapInfoHeader.SizeImage), 1, BmpFile );
05566   fwrite( &BitmapInfoHeader.XPelsPerMeter, sizeof(BitmapInfoHeader.XPelsPerMeter), 1, BmpFile );
05567   fwrite( &BitmapInfoHeader.YPelsPerMeter, sizeof(BitmapInfoHeader.YPelsPerMeter), 1, BmpFile );
05568   fwrite( &BitmapInfoHeader.ClrUsed, sizeof(BitmapInfoHeader.ClrUsed), 1, BmpFile );
05569   fwrite( &BitmapInfoHeader.ClrImportant, sizeof(BitmapInfoHeader.ClrImportant), 1, BmpFile );
05570 
05571 
05572   if( P->mUseDefaultColorTable )
05573   {     
05574     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.White );
05575     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Black );
05576     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Blue );
05577     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Green );
05578     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Purple );
05579     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Magenta );
05580     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.DarkBlue );
05581     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.IndianRed );
05582     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.BabyBlue );
05583     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.PaislyBlue );
05584     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LightPurple );
05585     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.DarkPurple );
05586     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.GreyPurple );
05587     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Brown );
05588     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Red );
05589     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Pink );
05590     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Yellow );
05591     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Orange );
05592     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Cyan );
05593     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LimeGreen );
05594     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Grey );
05595     CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LightGrey );             
05596   }
05597   else
05598   {
05599     if( P->mColorTable )
05600     {
05601       for( i = 0; i < sizeOfColorTable; i++ )
05602         fwrite( &(P->mColorTable[i]), sizeof(unsigned char), 1, BmpFile );       
05603     }
05604     else
05605     {
05606       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.White );
05607       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Black );
05608       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Blue );
05609       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Green );
05610       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Purple );
05611       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Magenta );
05612       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.DarkBlue );
05613       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.IndianRed );
05614       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.BabyBlue );
05615       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.PaislyBlue );
05616       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LightPurple );
05617       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.DarkPurple );
05618       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.GreyPurple );
05619       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Brown );
05620       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Red );
05621       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Pink );
05622       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Yellow );
05623       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Orange );
05624       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Cyan );
05625       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LimeGreen );
05626       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.Grey );
05627       CPLOT_FWriteRGB( BmpFile, P->mDefaultColorTable.LightGrey );             
05628     }       
05629   }    
05630 
05631 
05632   if( BitmapInfoHeader.Compression == 1 )
05633   {
05634     if( fwrite( CompressedVector.data[0], sizeof(byte), compressedSize, BmpFile ) != compressedSize )
05635     {
05636       CPLOT_BYTE_MTX_Free( &CompressedVector );
05637       return FALSE;
05638     }
05639     // done
05640   }
05641   else
05642   {
05643     for( i = 0; i < (int)P->mPlotData.nrows; i++ )
05644     {
05645       // write the mPlotData
05646       if( fwrite( P->mPlotData.data[i], sizeof(byte), P->mPlotData.ncols, BmpFile ) != P->mPlotData.ncols )
05647       {
05648         CPLOT_BYTE_MTX_Free( &CompressedVector );
05649         return FALSE;
05650       }
05651     }
05652   }
05653 
05654   fclose(BmpFile);
05655 
05656   CPLOT_BYTE_MTX_Free( &CompressedVector );
05657   return TRUE;
05658 }
05659 
05660 
05661 
05662 
05663 
05664 
05665 BOOL CPLOT_SetPlotOptions( 
05666   CPLOT *P, 
05667   CPLOT_structPlotOptions *opt
05668   )
05669 {
05670   if( !P )
05671     return FALSE;
05672   if( !opt )
05673     return FALSE;
05674 
05675   memcpy( &(P->mOptions), opt, sizeof(CPLOT_structPlotOptions) );
05676   return TRUE;
05677 }
05678 
05679 
05680 
05681 BOOL CPLOT_Plot( 
05682   CPLOT *P, 
05683   CPLOT_structSeries *Series 
05684   )
05685 {
05686   int i  = 0;
05687   int x1 = 0;
05688   int x2 = 0;
05689   int y1 = 0;
05690   int y2 = 0;
05691   int n = 0;
05692 
05693   double xval_i;
05694   double xval_ip1;
05695   double yval_i;
05696   double yval_ip1;
05697   CPLOT_enumColor color;
05698 
05699   if( !P )
05700     return FALSE;
05701   if( !Series )
05702     return FALSE;
05703   if( !Series->X )
05704     return FALSE;
05705   if( !Series->Y )
05706     return FALSE;
05707 
05708   n = Series->n;
05709 
05710   if( !CPLOT_DetermineSeriesStatistics( Series ) )
05711     return FALSE;
05712 
05713   if( !P->mIsAxesDrawn || P->mOptions.redrawAxes )
05714   {
05715     // draw the axes
05716     if( !CPLOT_DrawAxes( P, Series, CPLOT_BLACK ) )
05717       return FALSE;
05718     P->mIsAxesDrawn = TRUE;
05719   }
05720 
05721   if( P->mOptions.numberOfSeries < P->mSeriesIndex + 1 )
05722   {
05723     P->mOptions.numberOfSeries = P->mSeriesIndex+1;
05724     if( P->mOptions.numberOfSeries <= 3 )
05725     {
05726       if( !CPLOT_ResizePlot(P) )
05727         return FALSE;
05728     }
05729   }
05730 
05731   
05732   // now plot the mPlotData   
05733   for( i = 0; i < n; i++ )
05734   {
05735     xval_i = Series->X[i];
05736     yval_i = Series->Y[i];
05737 
05738     if( CPLOT_IsNAN( xval_i ) )
05739       continue;
05740     if( CPLOT_IsNAN( yval_i ) )
05741       continue;
05742 
05743     if( xval_i < P->mData.MinX )
05744       continue;
05745     if( xval_i > P->mData.MaxX )
05746       continue;
05747 
05748     x1 = (int)( (xval_i   - P->mData.MinX)*P->mData.ScaleX ) + P->mAxes.StartX;
05749     y1 = (int)( (yval_i   - P->mData.MinY)*P->mData.ScaleY ) + P->mAxes.StartY;
05750 
05751     if( i == n - 1 )
05752     {
05753       xval_ip1 = xval_i;
05754       yval_ip1 = yval_i;
05755       x2 = x1;
05756       y2 = y1;
05757     }
05758     else
05759     {
05760       xval_ip1 = Series->X[i+1];
05761       yval_ip1 = Series->Y[i+1];             
05762       if( CPLOT_IsNAN( xval_ip1 ) )
05763       {
05764         xval_ip1 = xval_i;
05765         yval_ip1 = yval_i;
05766         x2 = x1;
05767         y2 = y1;
05768       }
05769       else if( CPLOT_IsNAN( yval_ip1 ) )
05770       {
05771         xval_ip1 = xval_i;
05772         yval_ip1 = yval_i;
05773         x2 = x1;
05774         y2 = y1;
05775       }
05776       else
05777       {
05778         x2 = (int)( (xval_ip1 - P->mData.MinX)*P->mData.ScaleX ) + P->mAxes.StartX;
05779         y2 = (int)( (yval_ip1 - P->mData.MinY)*P->mData.ScaleY ) + P->mAxes.StartY;
05780       }
05781     }
05782 
05783     color = Series->color;
05784 
05785     if( x1 <= P->mAxes.StartX - 2)
05786     {
05787       continue;
05788     }
05789     if( x1 >= P->mAxes.FinishX + 2)
05790     {
05791       continue;
05792     }
05793     if( y1 <= P->mAxes.StartY - 2)
05794     {
05795       if( Series->markOutlierData )
05796       {
05797         // watch for +infinity values.
05798         if( CPLOT_IsPostiveINF( yval_i ) )
05799         {
05800           y1 = P->mAxes.FinishY + 2;
05801           if(  i == n - 1 ) // last point 
05802           {
05803             y2 = P->mAxes.FinishY;
05804           }
05805         }
05806         else
05807         {
05808           y1 = P->mAxes.StartY - 2;
05809           if(  i == n - 1 ) // last point 
05810           {
05811             y2 = P->mAxes.StartY;
05812           }
05813         }
05814         color = CPLOT_CYAN;         
05815       }
05816       else
05817       {
05818         continue;
05819       }
05820     }
05821     if( y1 >= P->mAxes.FinishY + 2)
05822     {
05823       if( Series->markOutlierData )
05824       {
05825         // watch for -infinity values.
05826         if( CPLOT_IsNegativeINF( yval_i ) )
05827         {
05828           y1 = P->mAxes.StartY - 2;   
05829           if( i == n - 1 ) // last point 
05830           {
05831             y2 = P->mAxes.StartY;
05832           }
05833         }
05834         else 
05835         {
05836           y1 = P->mAxes.FinishY + 2;
05837           if( i == n - 1 ) // last point 
05838           {
05839             y2 = P->mAxes.FinishY;
05840           }
05841         }
05842         color = CPLOT_CYAN;         
05843       }
05844       else
05845       {
05846         continue;
05847       }
05848     }         
05849 
05850     if( xval_i < P->mOptions.endOfWarmupEpoch )
05851     {
05852       if( !CPLOT_DrawPoint( P, x1, y1, CPLOT_LIGHTGREY ) )
05853         return FALSE;
05854     }
05855     else
05856     {
05857       if( !CPLOT_DrawPoint( P, x1, y1, color ) )
05858         return FALSE;
05859     }
05860 
05861     if( x2 < P->mAxes.StartX )
05862     {
05863       if( CPLOT_IsPostiveINF( xval_ip1 ) )
05864       {
05865         x2 = P->mAxes.FinishX;
05866       }
05867       else
05868       {
05869         x2 = P->mAxes.StartX;
05870       }        
05871     }
05872 
05873     if( x2 > P->mAxes.FinishX )
05874     {
05875       if( CPLOT_IsNegativeINF( xval_ip1 ) )
05876       {
05877         x2 = P->mAxes.StartX;
05878       }
05879       else
05880       {
05881         x2 = P->mAxes.FinishX;
05882       }
05883     }
05884 
05885     if( y2 < P->mAxes.StartY )
05886     {
05887       if( CPLOT_IsPostiveINF( yval_ip1 ) )
05888       {
05889         y2 = P->mAxes.FinishY;
05890       }
05891       else
05892       {
05893         y2 = P->mAxes.StartY;
05894       }
05895     }
05896 
05897     if( y2 > P->mAxes.FinishY )
05898     {
05899       if( CPLOT_IsNegativeINF( yval_ip1 ) )
05900       {
05901         y2 = P->mAxes.StartY;
05902       }
05903       else
05904       {
05905         y2 = P->mAxes.FinishY;
05906       }
05907     }
05908 
05909     if( Series->connected )
05910     {
05911       if( xval_i < P->mOptions.endOfWarmupEpoch )
05912       {
05913         if( !CPLOT_DrawLine( P, x1, y1, x2, y2, CPLOT_LIGHTGREY ) )
05914           return FALSE;
05915       }
05916       else
05917       {
05918         if( !CPLOT_DrawLine( P, x1, y1, x2, y2, Series->color ) )
05919           return FALSE;
05920       }
05921     }
05922   }
05923 
05924   if( Series->label != NULL )
05925   {
05926     if( strlen( Series->label ) > 0 )
05927     {
05928       if( !CPLOT_DrawLegendLabel( P, Series->label, Series->units, Series->color ) )
05929         return FALSE;
05930     }
05931   }
05932 
05933   if( P->mOptions.plotStatistics )
05934   {
05935     if( !CPLOT_DrawStats( P, Series ) )
05936       return FALSE;    
05937   }
05938 
05939   P->mSeriesIndex++;
05940   return TRUE;
05941 }
05942 
05943 
05944