mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-04-27 11:28:58 +02:00
[vk] Adjustment BitScaleHelper
This commit is contained in:
parent
ce48db0c7b
commit
f05b385ba3
1 changed files with 12 additions and 0 deletions
|
|
@ -2051,6 +2051,18 @@ bool Image::BlitScaleHelper(bool scale_up) {
|
|||
using namespace VideoCommon;
|
||||
static constexpr auto BLIT_OPERATION = Tegra::Engines::Fermi2D::Operation::SrcCopy;
|
||||
const bool is_color{aspect_mask == VK_IMAGE_ASPECT_COLOR_BIT};
|
||||
const bool has_depth = (aspect_mask & VK_IMAGE_ASPECT_DEPTH_BIT) != 0;
|
||||
const bool has_stencil = (aspect_mask & VK_IMAGE_ASPECT_STENCIL_BIT) != 0;
|
||||
const bool is_depth_only = has_depth && !has_stencil;
|
||||
const bool is_stencil_only = has_stencil && !has_depth;
|
||||
if ((is_depth_only || is_stencil_only) && info.num_samples == 1) {
|
||||
const VkImage src_image = scale_up ? *original_image : *scaled_image;
|
||||
const VkImage dst_image = scale_up ? *scaled_image : *original_image;
|
||||
BlitScale(*scheduler, src_image, dst_image, info, aspect_mask, runtime->resolution,
|
||||
/*supports_linear_filter=*/false, scale_up);
|
||||
return true;
|
||||
}
|
||||
|
||||
const bool supports_linear_filter = runtime->SupportsLinearFilter(info.format);
|
||||
const bool is_bilinear = is_color && supports_linear_filter;
|
||||
const auto filter_mode = is_bilinear ? Tegra::Engines::Fermi2D::Filter::Bilinear
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue