13 inline double G(
double x,
double y, 
double t) 
    16   return exp(-(x*x+y*y))*sin(t+x)*cos(y-t);
    20 int main(
const int argc, 
const char *argv[])
    29   std::vector<double> x(Nx);
    30   std::vector<double> y(Ny);
    31   std::vector<double> z(Nx*Ny);
    33   const double x_low = -2.5;
    34   const double x_upp = 1.5;
    35   const double y_low = -2.5;
    36   const double y_upp = 4;
    37   const double dx = (x_upp-x_low)/(Nx-1);
    38   const double dy = (y_upp-y_low)/(Ny-1);
    44   for (
int i=0; i<Nx; i++)
    47   for (
int i=0; i<Ny; i++)
    54   auto t0=std::chrono::system_clock::now();
    74     for (
int i=0; i<Nx; i++)
    75       for (
int j=0; j<Ny; j++)
    76         z[j*Nx+i] = 
G(x[i],y[j],t);
    84       frame.
WritePNG(
"example-surf2d.png");
    88     auto t1=std::chrono::system_clock::now();
    89     double xdt=std::chrono::duration_cast<std::chrono::duration<double>>(t1-t0).count();
    93       printf(
"Frame rate: %.2f fps\n",(
double)(i1-i0)/4.0);
    94       t0=std::chrono::system_clock::now();
 
void WritePNG(std::string fname)
Write png image of frame content. 
 
void SetGrid(const V &xcoord, const V &ycoord)
 
double G(double x, double y, double t)
 
int main(const int argc, const char *argv[])
 
Provide a framework wrapping window+interactor+renderers from vtk. 
 
Experimental class for 2D elevation plot - don't use. 
 
std::vector< RGBPoint > RGBTable
 
void SetRGBTable(RGBTable &tab, int tabsize)
 
void AddFigure(Figure *figure)
Add figure at position (0) 
 
Define Frame class providing a window for rendering. 
 
void Show()
Show frame content and continue. 
 
void UpdateValues(const V &values)