claude0001 1,341 Posted January 1, 2021 Share Posted January 1, 2021 (edited) On 12/31/2020 at 5:49 AM, tdm said: A bit OT but ... does Minecraft Java run on this? Interesting question. My guess would be that, if at all, Minecraft will run unacceptably slowly. As far as I know, there is no native implementation of a JRE on Sailfish. Here's an old and quite defunct thread about this on the Jolla forum. Now, I see no reason why it would not be possible to install the standard Linux versions of OpenJDK or even OracleJRE on Sailfish. Initially, this would enable text-only JAVA apps. Graphics in (Linux) OpenJDK/OracleJRE depends on X11, which SailfishOS does not support out-of-the-box. That could however be fixed using XWayland, which can be installed on SFOS somehow (see e.g. here). However, as we discussed in that same thread, even then there will be no hardware-accelerated OpenGL. In the end, you hit the same limitation as in a Linux-Chroot on Android/LineageOS: since SFOS is still using the same (Android) Kernel, the standard Linux interfaces for HW acceleration are not available, hence programs designed for desktop Linux cannot take advantage of the GPU. Edited January 2, 2021 by claude0001 1 Quote Link to post Share on other sites
claude0001 1,341 Posted January 2, 2021 Author Share Posted January 2, 2021 (edited) On 12/31/2020 at 5:49 AM, tdm said: A bit OT but ... does Minecraft Java run on this? And if it does, how well does it run? Sooo ... I could not resist doing the experiment. 😄 Not on SFOS/XWayland (as I do not have that on my device), but using my LineageOS/Linux-Chroot (devuan 3) with Xvnc. As argued above, I expect the two to yield quite similar results. As expected: Minecraft Java Edition does run in principle (yay!), but with so low framerate that it is not practically useful. What I did: Installed the default OpenJDK 11 shipping with Devuan/Debian (beowulf/buster). No problems here. Turns out running Minecraft is trickier than expected. I spent most of the time at this point, trying to understand internals of the game engine. While the program is a JAVA (and thus portable) app in principle, it depends on lwjgl which is not part of JAVA SE, but ships with the Minecraft Launcher. As the latter expects an x86/amd64 environment, it provides only the respective builds, which of course does not help us with our Pro1. To make things worse, the Launcher downloads and unpacks its preferred lwjgl libraries on-the-fly each time the game is started, so manual patching using the (perfectly available) arm64 versions is difficult. Grr. In the end, the easiest solution is to use a third-party launcher fixing all that. After 5 minutes of googling I found MultiMC for which an arm64 port exists. The port seems not to have been updated in a while and supports only Minecraft releases up to 1.16.1 -- but for the purpose of our experiment that should be good enough. After setting up a Minecraft version and my user account in MultiMC, Minecraft just starts normally without further tinkering. Horay! As expected, performance is pretty bad due to software-rendering in Mesa3D (llvmpipe). With the -- tiny -- default window size and standard graphics settings I get approx. 3 FPS in an ocean/forest biome. Sound works via my pulseaudio->XRDP->MS-RDP-App setup, even without much latency it seems. Nice. Keyboard input works fine. Mouse control is horrible, but that's not directly related to the Pro1. My way of accessing the Linux chroot emulates a remote-controlled cursor and Minecraft gets confused by that (I cannot play via mouse-sharing on my PCs either, probably for the same reasons). The game did not crash on me, but I honestly didn't spend much time in it. At the end of the day, this has been an interesting test of how far you can go with desktop-Linux software on our device. After all, Minecraft is a quite complex JAVA app. One could probably tweak performance a little by tinkering with graphics settings or by getting Optifine to run. Also, my Xvnc/XRDP solution likely adds some additional graphics overhead compared to a native X11 server. It would thus be interesting if anyone could repeat this experiment on a SFOS/LXC system like @matf showed here. The fundamental problem -- namely the lack of GPU-accelerated OpenGL -- should be the same in both cases though ... Obligatory screenshots: Edited January 3, 2021 by claude0001 3 Quote Link to post Share on other sites
tdm 2,322 Posted January 3, 2021 Share Posted January 3, 2021 A few folks on the discord server have been experimenting. In particular "kabouik" installed OpenJDK in a LXC container. I sent him the minecraft java files and pointed him to the lwjgl arm64 libs. He was able to get it running, but as mentioned, it is rather slow due to lack of GL. So we have two working solutions but neither are accelerated. In the meantime I've found android based minecraft launchers. So I'm not sure which is going to win out yet. PS: this is not for me, it is for my oldest son. Apparently minecraft PE (bedrock) and minecraft java behave differently and he prefers the Java behavior. 2 Quote Link to post Share on other sites
_DW_ 628 Posted January 4, 2021 Share Posted January 4, 2021 On 1/3/2021 at 4:42 AM, tdm said: PS: this is not for me, it is for my oldest son. Apparently minecraft PE (bedrock) and minecraft java behave differently and he prefers the Java behavior. My son also says the same thing 😄 Managed to kill his minecraft server yesterday docker decided to break :S Quote Link to post Share on other sites
3zet 100 Posted January 4, 2021 Share Posted January 4, 2021 Also java minecraft have awesome mods and modpacks, right now I'm playing with friends on Sevtech: Ages on the sky. Great modpack. Also Enigmatica 2: Expert was a really good one but this ramps up crafting difficulty to ridiculous level and its indeed for experts 😄 Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.