Views: 6,937,737 | Homepage | Main | Rules/FAQ | Memberlist | Active users | Last posts | Calendar | Stats | Online users | Search | 04-26-24 08:32 PM |
Guest: |
Main - Posts by MAGNUM_PT |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 1/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
So, for the past couple of days I've been trying to port melonDS to Android and I managed to get it to run. Here's a small video of it (kinda) working on a OnePlus X (Snapdragon 801):
As you can see, performance is terrible, making it completely unplayable. Sound does not work properly and only touch input is implemented (as a proof of concept). Some changes were made to melonDS's source code (to make some aspects more abstract) and can be found here: https://github.com/rafaelvcaetano/melonDS-android-lib The frontend source code will be released soon once I have it in a more user-friendly state (scale screens properly, proper input, BIOS location selection, and sound maybe?). Regarding the culprits of bad performance, I don't have a clear idea of what is the main bottleneck. Currently, I have the emulation running on a separate thread and rendering is done on a separate thread using OpenGL, where I simply fetch the framebuffer and draw it. I didn't even bother implementing synchronization between those threads since the performance was so bad that the chances of having tearing were so low. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 2/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
After remembering that doing a release build could a good idea, I managed to get between 20 to 30 FPS when starting the game. However, it quickly goes down back to 10 FPS. I will try to upload the frontend code today. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 3/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
The frontend source code has been (finally) published. You can find it here: https://github.com/rafaelvcaetano/melonDS-android
A testing build can be found here: https://github.com/rafaelvcaetano/melonDS-android/releases You will need to have the BIOS files (arm7, arm9 and firmware) in a directory to be able to use the emulator. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 4/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Just to finish the conversation:
- Regarding sound, on my device it sound more like ear rape that anything else. Due to the low framerate that was expected, but it didn't seem right. I'll try to check on a better device - Regardint 3D performance, it's quite possible that performance may be lacking. Android does not natively support semaphores, so I had to implement them using mutexes. However, I was not sure how SemTryWait() was supposed to be implemented and that might be causing problems. The other related methods could also use another revision - Currently, the path to the SRAM is hardcoded to be inside the app's data directory. I'll add an option to specify a directory or use the same directory as the ROM From now on, I'll try to be around IRC, as StapleButter suggested, so that we can start discussing some things there. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 5/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Hey! Sorry for the late replies. Yeah. I've been keeping a close eye on developments and this week I ended up addnig support for GBA ROMs. I also took a look at the OpenGL renderer but unfortunately my knowledge in this area is limited.
I've also been looking at Wi-Fi support but I'm still not sure how viable it will be. To support direct mode, root is required, which is far from ideal. I'll keep making some tests but there is absolutely nothing I can promise. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 6/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Posted by novamh Unfortunately, there's not much that can be done. There are no additional options that can be adjusted besides the ones provided in the Settings menu and the default values should provide the best performance. The only thing I can imagine that might improve performance is fiddling with the sound settings (increase latency or disable sound), but even then the gains would only be marginal (if there's any at all). |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 7/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Hi! Android port dev here. You should be able to use the same save states on both Android and PC if you are using the same version of melonDS. Unfortunately, the Android version is still using melonDS 0.9.3 while the PC version is on 0.9.4. For now, if you want to use the save states from Android on PC, you will have to use melonDS 0.9.3 on your PC.
But if you want to share save files instead of save states, that shouldn't be a problem. If you have further issues related to the Android version, please post them in the project's GitHub repository. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 8/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Hi! Android port dev here. I don't know how confortable you are with technology, so I will make a base tutorial here.
* First, you need to find the save files on your PC. They should be in the same directory as your ROM files and end with ".sav". * Then, connect your phone to your PC and locate the folder in which you placed your ROM files. * Finally, copy all save files from the PC (files that end with ".sav" and paste them in the directory in which you placed your ROM files on your Android device). Be aware that the names of the save files should match the name of the corresponding ROM. For example, if your ROM is called "Sample Rom.nds", the save files must be named "Sample Rom.sav". * And that's it. When launching a ROM on your Android device, it should load the save that you had on your PC. If you still have problems or questions, please create a discussion on the project's GitHub repository: https://github.com/rafaelvcaetano/melonDS-android/discussions |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 9/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
The Android version was not developed by the main melonDS team, so they can't really help you. But anyway, you can try using a method attempted by other users, described here: https://github.com/rafaelvcaetano/melonDS-android/discussions/317
It may not be possible by trading directly. You may need to use the GTS. If you have further problems with the Android version, please report it in the project's repository, either by opening an issue or a discussion. |
MAGNUM_PT |
| ||
Member Normal user Level: 7 Posts: 10/10 EXP: 1409 Next: 39 Since: 11-19-18 Last post: 617 days ago Last view: 35 days ago |
Hello! You should ask Android questions on the project's GitHub repository since the original melonDS team did not make the port and probably won't be able to help you.
The cheat database you showed is not well formatted. Try adding </codelist> at the end of the file and import it again. If it doesn't work, open an issue in the project's repository and I'll help you from there. |
Main - Posts by MAGNUM_PT |
Page rendered in 0.025 seconds. (2048KB of memory used) MySQL - queries: 22, rows: 83/83, time: 0.014 seconds. Acmlmboard 2.064 (2018-07-20) © 2005-2008 Acmlm, Xkeeper, blackhole89 et al. |