1
0
mirror of https://github.com/doitsujin/dxvk.git synced 2024-12-01 16:24:12 +01:00

[d3d9] Allow fourcc formats as the source in CheckFormatConversion

The docs say:
"The source format must be a FOURCC format or a valid back buffer format."
This commit is contained in:
Robin Kertels 2024-07-19 18:09:43 +02:00 committed by Joshie
parent b7d61b70c1
commit 031a98c232
2 changed files with 3 additions and 1 deletions

View File

@ -251,7 +251,8 @@ namespace dxvk {
D3D9Format SourceFormat, D3D9Format SourceFormat,
D3D9Format TargetFormat) { D3D9Format TargetFormat) {
bool sourceSupported = SourceFormat != D3D9Format::Unknown bool sourceSupported = SourceFormat != D3D9Format::Unknown
&& IsSupportedBackBufferFormat(SourceFormat); && (IsSupportedBackBufferFormat(SourceFormat)
|| (IsFourCCFormat(SourceFormat) && !IsVendorFormat(SourceFormat)));
bool targetSupported = TargetFormat == D3D9Format::X1R5G5B5 bool targetSupported = TargetFormat == D3D9Format::X1R5G5B5
|| TargetFormat == D3D9Format::A1R5G5B5 || TargetFormat == D3D9Format::A1R5G5B5
|| TargetFormat == D3D9Format::R5G6B5 || TargetFormat == D3D9Format::R5G6B5

View File

@ -230,6 +230,7 @@ namespace dxvk {
&& format != D3D9Format::MULTI2_ARGB8 && format != D3D9Format::MULTI2_ARGB8
&& format != D3D9Format::UYVY && format != D3D9Format::UYVY
&& format != D3D9Format::R8G8_B8G8 && format != D3D9Format::R8G8_B8G8
&& format != D3D9Format::YUY2
&& format != D3D9Format::G8R8_G8B8 && format != D3D9Format::G8R8_G8B8
&& format != D3D9Format::DXT1 && format != D3D9Format::DXT1
&& format != D3D9Format::DXT2 && format != D3D9Format::DXT2