-
Notifications
You must be signed in to change notification settings - Fork 1.3k
Conversation
Related: #250 |
Making some headway here — Got a Now adapting the various buckets to request geometries out of a more abstract interface instead of mucking with |
It builds! |
Eagerly following... |
Ok, setting this down for a moment and getting some other eyes on it. I have been working alone for a while, probing the limits of my C++ knowledge and leveling-up along the way. @kkaefer @jfirebaugh @ljbade could you take a peek? Also cc'ing @artemp @springmeyer @tmpsantos in case you've got any bandwidth to check this out. Current status is at master...07fd062 My current problem is failure to link because the The overall plan for this refactor is to move these currently-base classes down into derived classes:
It places them under abstract interface (pure virtual) base classes:
One other note: the old It then migrates I ran into a bit of hairyness with the filtered layers and their I had at one point moved away from the After this is done, I should be able to jump back to #893 to create |
@jfirebaugh has 👀 on this and we're working through it. |
|
||
public: | ||
inline explicit Geometry(pbf& data); | ||
inline explicit PBFGeometry(pbf data); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I assume this was an intentional to avoid mutating the passed in parameter?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Accident, I think — was going to take a review back through and improve passing by reference where applicable.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I intentionally changed from a reference to a value, as pbf
is intended to be passed by value and at the call site was being manually copied to a temporary. In any case, I'm about to push a commit that inlines PBFGeometry
entirely.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Much 🙇 to @jfirebaugh; merging now. |
refactor VectorTile to vend geometry
See background in #893 (comment). Basically the following classes are tightly coupled to PBF-specific vector tile geometry routines:
TileParser
LineBucket
FillBucket
SymbolBucket
All of these step through individual geometries in vector tiles (example) which ties the use of their structures to PBF binary-format tiles. We want to be able to also have "live tiles" that back annotations, which are structured similarly to vector tiles (multi-layer, pre-simplified, able to be filtered for styling purposes) yet come from sources such as live-adding or GeoJSON parsing.
The parser and buckets should ask for geometries in an intermediate format (probably
Tile
, which also has 4096 extents) and then do things with them.