mirror of
https://github.com/par274/sharpemu.git
synced 2026-08-01 07:29:43 +08:00
Vulkan: enable textureCompressionBC when the device supports it (#716)
Guest BC1–BC7 textures can be sampled directly when the feature is available; warn when it is not.
This commit is contained in:
@@ -4131,6 +4131,7 @@ internal static unsafe class VulkanVideoPresenter
|
|||||||
ShaderStorageImageExtendedFormats = supportedFeatures.ShaderStorageImageExtendedFormats,
|
ShaderStorageImageExtendedFormats = supportedFeatures.ShaderStorageImageExtendedFormats,
|
||||||
ShaderStorageImageReadWithoutFormat = supportedFeatures.ShaderStorageImageReadWithoutFormat,
|
ShaderStorageImageReadWithoutFormat = supportedFeatures.ShaderStorageImageReadWithoutFormat,
|
||||||
ShaderStorageImageWriteWithoutFormat = supportedFeatures.ShaderStorageImageWriteWithoutFormat,
|
ShaderStorageImageWriteWithoutFormat = supportedFeatures.ShaderStorageImageWriteWithoutFormat,
|
||||||
|
TextureCompressionBC = supportedFeatures.TextureCompressionBC,
|
||||||
RobustBufferAccess = supportedFeatures.RobustBufferAccess,
|
RobustBufferAccess = supportedFeatures.RobustBufferAccess,
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -4170,6 +4171,13 @@ internal static unsafe class VulkanVideoPresenter
|
|||||||
"translated shaders using unformatted storage image load/store will fail.");
|
"translated shaders using unformatted storage image load/store will fail.");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!supportedFeatures.TextureCompressionBC)
|
||||||
|
{
|
||||||
|
Console.Error.WriteLine(
|
||||||
|
"[LOADER][WARN] GPU does not support textureCompressionBC " +
|
||||||
|
"guest BC1-BC7 textures cannot be sampled directly.");
|
||||||
|
}
|
||||||
|
|
||||||
var maintenance8Features = new PhysicalDeviceMaintenance8FeaturesKHR
|
var maintenance8Features = new PhysicalDeviceMaintenance8FeaturesKHR
|
||||||
{
|
{
|
||||||
SType = StructureType.PhysicalDeviceMaintenance8FeaturesKhr,
|
SType = StructureType.PhysicalDeviceMaintenance8FeaturesKhr,
|
||||||
|
|||||||
Reference in New Issue
Block a user