Remove cached DrmKmsPlan resuse
This CL resolves visual artifacts caused when the DrmKmsPlan is cached from ValidateDisplay and later used during PresentDisplay. This change restores prior behavior where the plan is created and cached during validate, but then recreated fresh during present. Change-Id: Ifea65946d586c9020143a35455405c5e4c5479e1
This commit is contained in:
parent
8eeece3993
commit
9df6d57b48
1 changed files with 7 additions and 9 deletions
|
|
@ -998,15 +998,13 @@ std::optional<AtomicCommitArgs> HwcDisplay::CreateFrameUpdateCommit(
|
|||
composition_layers.emplace_back(layer->GetLayerData());
|
||||
}
|
||||
|
||||
// Use the provided validated composition plan if it exists, otherwise create
|
||||
// it now.
|
||||
a_args
|
||||
.composition = composition.composition_plan != nullptr
|
||||
? composition.composition_plan
|
||||
: DrmKmsPlan::CreateDrmKmsPlan(GetPipe(),
|
||||
std::move(
|
||||
composition_layers),
|
||||
cursor_layer);
|
||||
// TODO: Attempting to reuse the |composition.composition_plan| here causes
|
||||
// visual artifacts, so we must create a new plan. We expect the new plan to
|
||||
// be equivalent, so why can the existing plan not be used?
|
||||
a_args.composition = DrmKmsPlan::CreateDrmKmsPlan(GetPipe(),
|
||||
std::move(
|
||||
composition_layers),
|
||||
cursor_layer);
|
||||
if (!a_args.composition) {
|
||||
ALOGE_IF(!a_args.test_only, "Failed to create DrmKmsPlan");
|
||||
return std::nullopt;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue