Loading a .png file automatically opens with the "image display" core even if you have another one compatible with this extension
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 14.1k
- Forks
- 2.2k
- Avg merge
- 7h 35m
- Merged PRs (30d)
- 51
Description
Hey!
Very niche issue but PICO-8 games are in .png format by default, for example if you go to the Celeste page: https://www.lexaloffle.com/bbs/?pid=11722#p and click "Cart" it will open this: https://www.lexaloffle.com/bbs/cposts/1/15133.p8.png , which actually contains the game.
The problem is that if you go to "Load Content" and select the .png, it automatically opens it with the "image display" built-in core, although .png is a valid extension in the Retro8 core: https://github.com/libretro/retro8/blob/afa143ac123034fb7907f05282ac746c214deb1f/src/libretro/libretro.cpp#L191 and in the .info file as well: https://github.com/libretro/libretro-super/blob/6f238f9af976164c108fc73177c72da117bd99bd/dist/info/retro8_libretro.info#L4
It can be very easily worked around by renaming the file to .p8 instead or by loading the core before selecting the .png, so it's not really a huge issue, just annoying. It could become a real problem if someone wants to make a media core or something that can read .png in the future however.
Out of curiosity I also tried adding "mp4" to the supported extensions in the .info file, looks like the same issue exists with FFmpeg core, it just assumes it's the only compatible core. This isn't a valid extension in any other core AFAIK so it's even less of a problem atm, just wanted to point it out :p
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with RetroArch's Load Content entry point, then compare extension handling with the retro8 libretro.cpp and retro8_libretro.info entries cited in the report; also check whether the FFmpeg example follows the same path. Done means a compatible core can be selected for a .png instead of prematurely opening the image display core.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100