Skip to content

Conversation

abaire
Copy link
Contributor

@abaire abaire commented Jul 1, 2025

No description provided.

ui/xui/compat.cc Outdated

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.

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.

{"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