| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
As reported by clang-tidy-8.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* [build] Fix integer overflow runtime error for core part
Temporarily remove circle ci UBSAN build precondition
* [build] Enable all of the ubsans
[build] Check runtime error
[build] Update UBSAN_OPTION
* [build] Add UBSAN blacklist
[build] Ignore system libraries
[build] Ignore vendor library
* [build] Fix implicit conversion runtime error in core
* [build] Fix division by zero runtime error
* [build] Add unfixed error to ubsan blacklist
* [build] Make UBSAN halt on error
Revert "Temporary remove build precondition"
* [build] Fix division by zero error
* [build] Make UBSAN officially work without FIXME prefix
* [build] Fix implicit conversion from int64_t to uint64_t
* [build] Rename style test json file name
* Address review findings
|
|
|
|
| |
As reported by clang-tidy-8.
|
|
|
|
| |
and get rid of `SpriteLoaderWorker`, use `scheduleAndReplyValue()` API instead.
|
|
|
|
|
|
| |
If we get a new sprite sheet from the server, we need to merge current
sprite sheet with a new one, while overwiting duplicates and keeping
old unique images in a style.
|
|
|
|
|
|
| |
In cases when cached resource is useable, yet don't have an expiration
timestamp, we provided data to the requester from the cache and the same
data was returned once 304 response was received from the network.
|
|
|
|
| |
This reverts commit 80cb05420a86ed53815cae7fb2cb3fddf07dd1d1.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
What happened:
The excessive `onSpriteLoaded()` notifications were caused by the trick inside `OnlineFileRequest::completed()` implemenation,
which causes receving of two file source updates pointing to the *same* data in case the network response is `notModified` and
the local storage has the sprite sheet already stored inside.
In the SpriteLoader` implementation, it resulted in 2 extra `parseSprite()` calls and 2 extra `onSpriteLoaded()` notifications.
Then, the excessive `onSpriteLoaded()` notifications affected style images and all the unnecessarily added image dupes (btw,
the amount of these dupes `= 2 * number of style images`) were treated by the `RenderOrchestrator` as *updated* images.
Further, `RenderOrchestrator` called `ImageManager::updateImage()` for the updated images and the `ImageManager` populated the
`updatedImageVersions` map.
Finally, at every frame all the geometry tiles iterated through the `updatedImageVersions` to check whether their uploaded
textures needed patching.
All the mentioned above had a negative performance impact.
The fix:
Now, `SpriteLoader` sends `onSpriteLoaded()` notifications only if the data in the file source response is different comparing
to the existing one.
|
|
|
|
|
|
| |
This change enables attaching images to the style with batches and
avoids massive re-allocations. Thus, it improves UI performance
especially at start-up time.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* [core] Introduce FileSourceManager and use it for default platform impl
- Add `FileSourceManager` interface that provides access to `FileSource`
instances and means of registering / unregistering `FileSource` factories
- Split `DefaultFileSource` into smaller parts
- Add `DatabaseFileSource` interface and it's default implementation
- Remove inter-dependencies between concrete `FileSource` classes
* [build] Add files to next build system
* [core] Add generic property setters / getters
* [core] Remove setOnlineStatus from OnlineFileSource interface
* [core] Hide threading implementation details from DatabaseFileSource interface
* [core] Make DB file source methods virtual
* [core] Add documentation for DatabaseFileSource and rename one method
* [core] Use simple callback instead of ActorRef
* [core] Remove ActorRef from OnlineFileSource public header
* [core] Add callback to FileSource::forward async API
* [core] Pass OfflineRegionDefinition by value
* [core] Update tests to use modular file sources
* [core] Update unit tests
* [core] Update unit tests after rebase
* [core] Backport low prio fix for cached requests
* [core] Backport pack database
* [core] Return removed factory from unRegisterFileSourceFactory
* [core] Rename shadowed args in onlinefilesource
* [core] Remove simple std::function callback aliases
* [core] Expose online file source property keys in public header file
* [test-runner] Add proxy file source test runner
* [cache] Update mbgl-cache utility to use new file source
* [metrics] Rebaseline binary size metrics
* [offline] Update offline utility
* [core] Update changelog
|
|
|
|
|
|
|
|
|
|
| |
- Do not carry it over everywhere as parameter, it is a shared
instance anyway and the lifecycle is pretty much the app lifecycle
from the moment we instantiate a map.
- Rename to BackgroundScheduler because it is a Scheduler that will
do tasks in the background, we don't make assumptions if it is a
thread pool or a single thread.
- Most importantly, remove the dependency from `core` on `platform`.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* Introduce AspiringActor, EstablishedActor
This pair of objects represents the two-phase (parent-thread /
child-thread) construction that's needed to support constructing
Thread<Object> without blocking until the child thread is up and
running.
An `AspiringActor<O>` is responsible for:
- ownership of the actor's `Mailbox`
- allocating the memory for (but *not* constructing) the target object `O`
Using these two pieces--the mailbox and a stable address for `O`--an
`AspiringActor<O>` can accept messages for the target object, or provide
`ActorRef<O>`s that do so, before the object has actually been
constructed by the corresponding `EstablishedActor<O>`. (Such messages
are queued in the mailbox until after the object is constructed.)
This allows for an `AspiringActor<O>` to be created and safely used by a
thread other than the one on which the target object will (eventually)
live.
An `EstablishedActor<O>` is responsible for managing the lifetime of the
target object `O` and the open/closed state of the parent's `mailbox`.
The `O` object's lifetime is contained by that of its owning
`EstablishedActor<O>`: the `EstablishedActor` constructor executes the
`O` constructor via "placement new", constructing it at the address
provided by the parent `AspiringActor`, and the `~EstablishedActor`
destructor similarly executes the `~O` destructor (after closing the
mailbox). `EstablishedActor` should therefore live entirely on the
thread intended to own `O`.
* Remove Actor#{invoke,ask}
|
| |
|
| |
|
| |
|
|
|
|
| |
Instead, just add them to the Style as needed. Includes changes from #8905 and takes care to avoid regressing #3817.
|
| |
|
|
|
|
|
|
|
|
| |
* Always return image metrics exclusive of padding
* Work with integer coordinates whenever possible
* Eliminate redundant SpriteAtlasElement members
* Fix asymmetric re-padding in getIconQuad when pixelRatio != 1
* Add explanatory comments
|
|
|
|
| |
This makes pattern usage more like icons, and will be necessary for data-driven *-pattern properties.
|
| |
|
| |
|
| |
|
|
|
|
| |
We switched to 16-bit coordinates in attributes in b0cb8715ed74678b4d0f05829fa71a590e41b2f6, so there's no longer any reason to require that they are divisible by four.
|
|
|
|
| |
More like Source and Layer.
|
| |
|
| |
|
| |
|
|
|
|
|
| |
* Simplify SymbolLayout; it never needs to care about more than one SpriteAtlas.
* Move the reference from SymbolLayer::Impl to SymbolBucket. This is a prerequisite for making layer Impls immutable.
|
|
|
|
|
|
|
| |
A style has a collection of images, just as it has collections of sources and layers.
* Name things appropriately
* Use std::unique_ptr
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Expose glyph and icon information to workers via message interface.
- Glyph/SpriteAtlas track which tiles have outstanding requests
and send messages to them when glyphs/icons become available.
- Remove obsolete "updateSymbolDependentTiles" pathway
- Symbol preparation for a tile now depends on all glyphs becoming
available before it can start.
- Start tracking individual icons needed for a tile, although we don't
do anything with the information yet.
- Introduce typedef for GlyphID
|
| |
|
| |
|
| |
|
| |
|
|
|
|
| |
Simplify internal datastructures. Properly remove rects from the bin pack when an image is removed.
|
| |
|
|
|
|
|
|
| |
Provide Image::copy, which handles copying rectangles from a source to a destination, with thorough bounds checking.
Also fixes an indexing error in SpriteAtlas, where the top row of pixels in a wrapped image was copied from the wrong source row.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|