[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/cyclemap/tilemaker/master/src/output_object.cpp [Back]  [Original]

/*
	OutputObject - any object (node, linestring, polygon) to be outputted to tiles
*/

#include "output_object.h"
#include "helpers.h"
#include "coordinates_geom.h"
#include 
using namespace std;
namespace geom = boost::geometry;

// **********************************************************

std::ostream& operatorhasBoolValue()) {
			fbuilder.add_property(key, it->boolValue());
		} else if (it->hasIntValue()) {
			// could potentially add ,vtzero::sint_value_type(2) to force sint encoding (efficient for -ve ints)
			fbuilder.add_property(key, it->intValue());
		} else if (it->hasFloatValue()) {
			fbuilder.add_property(key, it->floatValue());
		}
	}
}

bool OutputObject::compatible(const OutputObject &other) {
	return geomType == other.geomType &&
	       z_order == other.z_order &&
	       attributes == other.attributes;
}

// Comparision functions
bool operator==(const OutputObject& x, const OutputObject& y) {
	return
		x.layer == y.layer &&
		x.z_order == y.z_order &&
		x.geomType == y.geomType &&
		x.attributes == y.attributes &&
		x.objectID == y.objectID;
}

bool operator==(const OutputObjectID& x, const OutputObjectID& y) {
	return x.oo == y.oo && x.id == y.id;
}

Web Proxy Viewer  |  New URL  |  Original Page