Reject 2d layers of non textures in 2d copy engine

This commit is contained in:
Thog 2019-02-14 01:03:02 +01:00
commit e4e08e6c67
No known key found for this signature in database
GPG key ID: 0CD291558FAFDBC6

View file

@ -81,10 +81,11 @@ namespace Ryujinx.Graphics
{
ImageType Type = ImageTypes[Position];
// FIXME(thog): I'm actually unsure if we should allow other image type, gpu testing needs to be done here.
// FIXME(thog): I'm actually unsure if we should deny all other image type, gpu testing needs to be done here.
if (Type != ImageType.Texture && Type != ImageType.TextureArrayLayer)
{
Logger.PrintWarning(LogClass.Gpu, $"Possible invalid layer type detected! (ImageType.{Type})");
LayerIndex = -1;
return false;
}
return true;