зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1254273 - Align the displayport to a max of 256 pixels even if the layer is larger. r=BenWa
MozReview-Commit-ID: CLghUMWkJU8
This commit is contained in:
Родитель
4a14dd7e13
Коммит
ab65d99c4e
|
@ -953,8 +953,11 @@ GetDisplayPortFromMarginsData(nsIContent* aContent,
|
|||
if (APZCCallbackHelper::IsDisplayportSuppressed()) {
|
||||
alignment = ScreenSize(1, 1);
|
||||
} else if (gfxPrefs::LayersTilesEnabled()) {
|
||||
alignment = ScreenSize(gfxPlatform::GetPlatform()->GetTileWidth(),
|
||||
gfxPlatform::GetPlatform()->GetTileHeight());
|
||||
// Don't align to tiles if they are too large, because we could expand
|
||||
// the displayport by a lot which can take more paint time. It's a tradeoff
|
||||
// though because if we don't align to tiles we have more waste on upload.
|
||||
alignment = ScreenSize(std::min(256, gfxPlatform::GetPlatform()->GetTileWidth()),
|
||||
std::min(256, gfxPlatform::GetPlatform()->GetTileHeight()));
|
||||
} else {
|
||||
// If we're not drawing with tiles then we need to be careful about not
|
||||
// hitting the max texture size and we only need 1 draw call per layer
|
||||
|
|
Загрузка…
Ссылка в новой задаче