Add RETRO_ENVIRONMENT_GET_VFS_AUTHORIZED_LOCATIONS env - #19347
Conversation
|
@white-axe Before this gets merged in, how does this look to you? As I think you did the SAF implementation if I'm not mistaken. |
|
FYI this is for scummvm. |
|
@warmenhoven Anything like this in Apple ecosystem? |
|
I kind of want vfs in scummvm so consider this a +1 for this pr |
|
Why is this necessary at all. Why not just use the existing |
This has nothing to do with saves directory. |
Scummvm in RetroArch has a internal method to create a playlist (because it has its own internal scanner handling a myriad of special cases) so like upstream, it either needs to create its own SAF authorizations to use it in that scanner, or get the frontend ones. I'm not sure but I think in the retroarch context (a loaded dll) it can't authorize its own SAF authorizations, or maybe its just for consistency not sure. Tl;dr: Other cores scan the files outside and inherit a authorized saf rom path (files), scummvm needs to navigate a internal saf dir hierarchy and needs a mechanism to pass those. Note scummvm also has the old method to pass saf "roms" like the other cores that I suspect would work, but it loses out on the scummvm internal scanner which "fixes" a lot of bugs (besides the older method being torture for users, involving using player created files in every single game - that method does have a advantage though, which is being able to use zip files as games, something which will never happen in the internal scanner because of hangups of devs about "piracy" and this core being upstream) Zip files in this older method are extracted fully to retroarch tmp by retroarch itself (but because of that they also have high latency over a uncompressed game over a local network so its not really worth it) |
|
Sorry about the closed new issue, clicked the wrong buttons while editing the message. |
|
Android: User goes to load core -> scummvm Open.. to select a new SAF folder Then the user finds the relevant scummvm content, tapping to load. Now from a RA perspective, that path to the ROM or whatever the user selected in the frontend is now passed to the core in retro_load_game: So that would already be a SAF authorized path? Could this be used? Or does it need to know about other paths? This is all guess work btw, I don't know about other requirements for scummvm. But then this could be fed into vfs callback to open additional files, assuming its part of the same path, it should still be authorized? |
Theoretically it should work, though not tested on Android, if Another manual workaround may be preparing the The correct way would be: retrieving from the frontend the URI (and that is the reason for this PR) of a node in the tree high enough to contain all the games below, pressing "mass add" from scummvm launcher and create automatically the needed |
Adds a new env call to get a list of frontend-authorized filesystem locations.
Paths returned by this call must be directly usable with the VFS interface, for example saf://... on Android.