Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* Example of stand-alone plugin development
- Distributed in the public domain.
- */
- #include "ExampleDistribution.h"
- #include <iostream>
- #include <string>
- #include "kml/dom.h" // The KML DOM header.
- #include "kml/base/file.h"
- using namespace std;
- // create a spiral
- FooDistribution::FooDistribution(int n, Rect* volume, Args* args) : Distribution(n,volume) {
- rad = args->extract_switch("-foo-rad")?args->pop_number():0.1;
- d = MIN(width,height)/n/2;
- i=0;
- cout << "3" << endl;
- cout << "1" << endl;
- std::string file_content;
- kmlbase::File::ReadFileToString("graffiti.kml", &file_content);
- cout << "2" << endl;
- cout << file_content << endl;
- }
- BOOL FooDistribution::next_location(METERS *loc) {
- cout << "4" << endl;
- loc[0] = cos(rad*i)*d*i;
- loc[1] = sin(rad*i)*d*i;
- loc[2] = 0;
- i++; // increment for next point
- cout << "5" << endl;
- return true; // yes, make the device
- }
Add Comment
Please, Sign In to add comment