[ < ] [ > ]   [ << ] [ Up ] [ >> ]         [Top] [Contents] [Index] [ ? ]

2.6.7 Boxs sample

Boxs draw surface by boxes. You can use ‘#’ for drawing wire plot. The sample code is:

int sample(mglGraph *gr)
{
  mglData a;  mgls_prepare2d(&a);
  gr->SetOrigin(0,0,0); gr->Light(true);
  gr->SubPlot(2,2,0);  gr->Title("Boxs plot (default)");
  gr->Rotate(40,60);  gr->Box();  gr->Boxs(a);

  gr->SubPlot(2,2,1); gr->Title("'\\@' style");
  gr->Rotate(50,60);  gr->Box();  gr->Boxs(a,"@");

  gr->SubPlot(2,2,2); gr->Title("'\\#' style");
  gr->Rotate(50,60);  gr->Box();  gr->Boxs(a,"#");

  gr->SubPlot(2,2,3); gr->Title("compare with Tile");
  gr->Rotate(50,60);  gr->Box();  gr->Tile(a);
  return 0;
}
Example of Boxs()

This document was generated by Autobuild on July 16, 2012 using texi2html 1.82.