libretro / libretro/RetroArch

Missing HiDPI resolution listing on a Retina MacBook Pro.

Open
#18,964 2 comments 5 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C
Stars
14.1k
Forks
2.2k
Avg merge
7h 35m
Merged PRs (30d)
51

Description

Is there an existing issue for this?
  • This is a bug in RetroArch frontend
  • I have searched the existing issues
Description

On a Retina display, navigate to Settings > Video > Output then select Screen Resolution and note the resolution list. They are all low-dpi resolutions that are not exposed in System Settings > Display by default. None of the HiDPI Retina resolutions are present.

I was working on a swift script to work around this limitation (only to select alternate refresh rates) and I ran into the same problem. CGDisplayCopyAllDisplayModes returns only lo-DPI resolutions by default. I don’t have any experience with Swift but in my search, I found a way to reveal the correct display modes. Remembering how RetroArch lists display modes, I searched the codebase and it looks like it’s doing the same here and here.

It must be called like so:

CGDisplayCopyAllDisplayModes(
    displayID,
    // HiDPI modes (Retina) ignored without this:
    [kCGDisplayShowDuplicateLowResolutionModes: kCFBooleanTrue!] as CFDictionary
  )

The other problem is video_refresh_rate being set to zero causing the screen to go black after the selection.

Expected behavior

No response

Steps to reproduce the bug
  1. navigate to Settings > Video > Output
  2. make any selection
  3. screen goes black
Version/Commit

1.22.2

Bisect Results

No response

Present in the nightly version

Yes, this is reproduced in the nightly build

Platform & operating system

macOS Tahoe 26.4.1 M1

Affected Cores

No response

Environment information

No response

Relevant log output

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Inspect gfx/display_servers/dispserv_apple.m at the display-mode enumeration points around lines 140 and 270, then compare them with the linked Swift example. Reproduce Settings > Video > Output on a Retina Mac and check both the available HiDPI modes and the reported video_refresh_rate. Done means Retina resolutions are listed and selecting one does not leave the screen black.

Written by the indexing model from the issue text.

Assessment

Tech stack
c, macos, objective-c
Domain
desktop, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
55/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.