function iteratePoints(data, callbackfn) {
	data.s.forEach(shapeOrPath => {
		if (shapeOrPath.type === 0) {
			// path
			callbackfn(/** @type {PathSerialized} */(shapeOrPath).s.p?.position);
			callbackfn(/** @type {PathSerialized} */(shapeOrPath).e.p?.position);
		} else {
			// shape
			callbackfn(/** @type {ShapeData} */(shapeOrPath).position);
		}
	});
}
@param {DiagramSerialized} data, @param {(point:Point)=>void} callbackfn