To make unmanaged vector layers work like the removed ol.FeatureOverlay,
the layer filter for ol.Map#forEachFeatureAtPixel needs to ignore unmanaged
layers.
* Skipped features need to be hit-detected on unmanaged layers.
* updateWhileAnimating and updateWhileInteracting are recommended to
achieve the same instant visual feedback that ol.FeatureOverlay had.
By using the frameState's focus, we can adjust extent and transform and
render it for the world of interest instead of wrapping it and rendering
for every visible world.
When we have only a single point, we want to make sure it gets added (fixes#1821).
Because this code doesn't differentiate coordinates that are part of a linestring or linearring from those that are independent points, we always add the first segment (or pair of points). In addition, coordinates for segments are appended whenever they represent a change in relationship with respect to the extent. This keeps the code simpler for handling fills and properly capturing intersection points for linestrings. This could be modified to save a few extra coordinates, but it provides for simpler code at a very minimal cost.