The International Simutrans Forum

Community => Simutrans Gaming Discussion => Topic started by: Yona-TYT on November 28, 2018, 02:12:58 AM

Title: Simutrans on android with wine
Post by: Yona-TYT on November 28, 2018, 02:12:58 AM
For a while now, a port of wine for android has been available.
I was wondering if someone has already tried running simutran on android with wine?, since I do not have a tablet to try that.  :-[

https://dl.winehq.org/wine-builds/android/ (https://dl.winehq.org/wine-builds/android/)
Title: Re: Simutrans on android with wine
Post by: prissi on November 28, 2018, 02:39:14 AM
Emulating an i86 CPU on ARM for Simutrans will have awful performance and kill the battery very fast. With SDL2, porting to Android is easy, as easy as making Simutrans for Steam. I have not enough spare time to do this, but will happily incorporate any such ports.
Title: Re: Simutrans on android with wine
Post by: jameskuyper on November 28, 2018, 02:59:05 AM
I can understand the performance issue - emulating a different platform is always inefficient, the more different the platforms, the worse the efficiency. However, I'm curious about why the battery drain would be high? When writing your answer, keep in mind that while I know a lot about programming in general, I know next to nothing about programming for Android platforms. Naively, I'd expect the main battery drain to be due to the display, and I wouldn't expect it to be significantly higher than anything else that keeps the display on an active.
Title: Re: Simutrans on android with wine
Post by: Ters on November 28, 2018, 06:45:01 AM
When emulating one CPU on another, the actual CPU will have run many instructions for every instruction for the emulated CPU. Simutrans also pushes the CPU pretty hard even when it isn't running in an emulator, and will drain my laptop's battery quickly as well. To conserve battery, CPU's for portable devices in particular (although I think any modern CPU has this feature), will enter low power states when CPU load is low, such as when you are not using the device at all, or doing things that don't require the CPU to calculate like crazy. Reading this web page doesn't require a lot of work from the CPU. It just needs to figure out where everything is supposed to go when loading the page, and then only perform some minor adjustments when you scroll. Real-time games crunch numbers all the time.