Skip to content

ui: Add render scale and backend to compat reports #2319

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

abaire
Copy link
Contributor

@abaire abaire commented Jul 1, 2025

No description provided.

ui/xui/compat.cc Outdated
@@ -91,6 +87,23 @@ void CompatibilityReporter::Draw()
description[0] = '\x00';
report.compat_comments = description;

char render_scale_buffer[8];
snprintf(render_scale_buffer, sizeof(render_scale_buffer), "%dx",
nv2a_get_surface_scale_factor() - 1);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe copied from other UI code? The -1 elsewhere is for translating to lookup table, but here this will result in 0x being printed

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yup, copied from UI code. Fixed.

@@ -41,15 +41,17 @@ public:
std::string compat_rating;
std::string compat_comments;
std::string xbe_headers;
std::string rendering_scale;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Unusual indentation?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed, tabs once again.

@@ -57,6 +49,8 @@ const std::string &CompatibilityReport::GetSerializedReport()
{"compat_rating", compat_rating},
{"compat_comments", compat_comments},
{"xbe_headers", xbe_headers},
{"rendering_scale", rendering_scale},
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

  • Indentation doesn't match surrounding
  • I'll have to update the backend to support saving these fields

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Weird, once again this looks fine in the GH UI for me. Looks like the file is using tabs. What do you have your tabs set to so I can catch these before they're a PR issue (at least until we run clang-format and get rid of them)?

Screenshot 2025-07-01 at 18 30 13

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Huh, weird. GitHub on my end was showing a 1 space tab. Locally I usually use tab=4 spaces. Yeah, we'll clang-format and convert the tabs to spaces at some point.

@abaire abaire force-pushed the add_res_scale_and_backend_to_compat branch from 8efaa98 to bf0b93f Compare July 2, 2025 01:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants