mirror of
https://git.eden-emu.dev/eden-emu/eden.git
synced 2026-08-16 21:33:01 +00:00
Some trivial tests
This commit is contained in:
@@ -1000,10 +1000,10 @@ void RasterizerVulkan::LoadDiskResources(u64 title_id, std::stop_token stop_load
|
||||
void RasterizerVulkan::FlushWork() {
|
||||
#ifdef __ANDROID__
|
||||
static constexpr u32 DRAWS_TO_DISPATCH = 512;
|
||||
static constexpr u32 CHECK_MASK = 3;
|
||||
static constexpr u32 CHECK_MASK = 31;
|
||||
#else
|
||||
static constexpr u32 DRAWS_TO_DISPATCH = 4096;
|
||||
static constexpr u32 CHECK_MASK = 7;
|
||||
static constexpr u32 CHECK_MASK = 31;
|
||||
#endif // __ANDROID__
|
||||
|
||||
static_assert(DRAWS_TO_DISPATCH % (CHECK_MASK + 1) == 0);
|
||||
|
||||
@@ -598,10 +598,24 @@ void TextureCache<P>::UpdateRenderTargets(bool is_clear) {
|
||||
up_scale = Settings::values.resolution_info.up_scale;
|
||||
down_shift = Settings::values.resolution_info.down_shift;
|
||||
}
|
||||
render_targets.size = Extent2D{
|
||||
(maxwell3d->regs.surface_clip.width * up_scale) >> down_shift,
|
||||
(maxwell3d->regs.surface_clip.height * up_scale) >> down_shift,
|
||||
u32 clip_width = (maxwell3d->regs.surface_clip.width * up_scale) >> down_shift;
|
||||
u32 clip_height = (maxwell3d->regs.surface_clip.height * up_scale) >> down_shift;
|
||||
const auto& resolution = Settings::values.resolution_info;
|
||||
const auto clamp_to_attachment = [&](ImageViewId view_id) {
|
||||
if (!view_id) {
|
||||
return;
|
||||
}
|
||||
const ImageViewBase& view = slot_image_views[view_id];
|
||||
clip_width = (std::min)(clip_width, is_rescaling ? resolution.ScaleUp(view.size.width)
|
||||
: view.size.width);
|
||||
clip_height = (std::min)(clip_height, is_rescaling ? resolution.ScaleUp(view.size.height)
|
||||
: view.size.height);
|
||||
};
|
||||
for (size_t index = 0; index < NUM_RT; ++index) {
|
||||
clamp_to_attachment(render_targets.color_buffer_ids[index]);
|
||||
}
|
||||
clamp_to_attachment(depth_buffer_id);
|
||||
render_targets.size = Extent2D{clip_width, clip_height};
|
||||
render_targets.is_rescaled = is_rescaling;
|
||||
|
||||
if (render_targets != previous_render_targets) {
|
||||
|
||||
Reference in New Issue
Block a user