mirror of
https://github.com/skyline-emu/skyline.git
synced 2024-12-22 22:11:49 +01:00
Ignore new layer creations instead of replacing previous ones while waiting for proper multiple layers support.
This commit is contained in:
parent
2855d12f31
commit
cb62e15748
@ -117,13 +117,13 @@ namespace skyline::service::hosbinder {
|
||||
u64 IHOSBinderDriver::CreateLayer(DisplayId pDisplayId) {
|
||||
if (pDisplayId != displayId)
|
||||
throw exception("Creating layer on unopened display: '{}'", ToString(pDisplayId));
|
||||
else if (layer) // Fallback to replacing previous layer
|
||||
Logger::Warn("Creation of multiple layers is not supported");
|
||||
|
||||
|
||||
layerStrongReferenceCount = InitialStrongReferenceCount;
|
||||
layerWeakReferenceCount = 0;
|
||||
layer = std::make_shared<GraphicBufferProducer>(state, nvMap);
|
||||
else if (!layer) {
|
||||
layerStrongReferenceCount = InitialStrongReferenceCount;
|
||||
layerWeakReferenceCount = 0;
|
||||
layer = std::make_shared<GraphicBufferProducer>(state, nvMap);
|
||||
}
|
||||
else // Ignore new layer creations if one already exists
|
||||
Logger::Warn("Creation of multiple layers is not supported. Ignoring creation of new layers.");
|
||||
|
||||
return DefaultLayerId;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user