00001 #ifndef _WINC_VECTPLOT
00002 #define _WINC_VECTPLOT
00003
00004 #include <WXP/ColorFill.h>
00005 #include <WXP/Grid.h>
00006 #include <WXP/Plot.h>
00007 #include <WXP/String.h>
00008
00009 namespace WXP {
00010 class VectPlot {
00011 int type;
00012 int skipx, skipy;
00013 float intrvl;
00014 float base;
00015 float speed;
00016 int density;
00017 float scale;
00018 float arrow_scale;
00019 float dom_scale;
00020 float min_cut;
00021 float max_cut;
00022 float max;
00023 String color_table;
00024 String color_data;
00025 String color_fill;
00026 String color_label;
00027 ColorFill fill;
00028 int bar;
00029 int *num;
00030 int numsize;
00031
00032 public:
00033 VectPlot();
00034 VectPlot( const char *param );
00035 int init();
00036 int setParam( const char *param );
00037 int setInterval( float val );
00038 int setBase( float val );
00039 int setSpeed( float val );
00040 int setDensity( int val );
00041 int setSkip( int val );
00042 int setColorTable( const char *str );
00043 int setColorFill( const char *str );
00044 int setColorLine( const char *str );
00045 inline int getType(){ return type; };
00046 int setType( const char *str );
00047 inline int setType( int rtype ){ type = rtype; return 1; };
00048 inline float getMax(){ return max; };
00049 int drawLabels( Plot &plot, Grid &grid );
00050 int draw( Plot &plot, Grid &ugrid, Grid &vgrid );
00051 int drawStreamline( Plot &plot, Grid &ugrid, Grid &vgrid,
00052 int i, int j, float length );
00053 int drawBar( Plot &plot, const char *locate );
00054 int drawVect( Plot &plot, const char *locate );
00055
00056 enum {
00057 VECTOR,
00058 BARB,
00059 STREAM
00060 };
00061 };
00062 }
00063 #endif