chengxinlun / Stellarium-android

A version of Stellarium for android
GNU General Public License v2.0
84 stars 28 forks source link

Possibility to add custom landscape based on horizon polygon #11

Open khaled-hammoud opened 5 years ago

khaled-hammoud commented 5 years ago

Would you give the user to add his own landscape configuration as horizon polygon added as text file like the PC as geneva_horizon.txt? It would be a good advantage as I think ;)

ghost commented 5 years ago

Think this partially implemented here: https://github.com/chengxinlun/Stellarium-android/issues/2

khaled-hammoud commented 5 years ago

No, not the same, I create the folder stellarium manually, so /sdcard/stellarium/landscapes/geneva

And there is the correspondant landscape.ini and horizon_Geneva.txt, but nothing is showed in the settings in the app, so I think it is not supported now. My android is rooted

chengxinlun commented 5 years ago

Just gave it a test. Custom landscapes are supported. However, the ini file must be named as landscape.ini to be recognized.

chengxinlun commented 5 years ago

A simple test works. It might be that landscape geneva is not supported with 0.12 kernel. I will look into the issue.

khaled-hammoud commented 5 years ago

My stellarium version is 1.29, and yes the landscape is so renamed landscape.ini and in thr same directory is the auxilliary horizon file renamed as horizon_Geneve.txt

But is my path okay? /sd/stellarium/landscapes/geneva/

or should a directory named "data" inserted between "stellarium" and "landscapes"?

gzotti commented 5 years ago

Polygonal landscape was introduced in the 0.13 series. If the Android version is based on 0.12, it will not work. But it could be back-ported, of course.

khaled-hammoud commented 5 years ago

I am not so familiar with technical data, but my android OS is 7.0 nougat, Stellarium mobile 1.29.6, are the requirement satisfied to install custom landscapes specially polygonal?

chengxinlun commented 5 years ago

Thanks @gzotti for pointing out. I did some testing. Geneva, or any otjer polygon landscape, won't load as not supported by 0.12 kernel.

chengxinlun commented 5 years ago

However, it should still show up in the landscape list. Are you sure you granted permissions of read/write access of external storage to stellarium? @kha-ce

chengxinlun commented 5 years ago

A easy way to check is that stellarium folder should be automatically created under /sdcard, with config.ini in the folder.

khaled-hammoud commented 5 years ago

I uninstalled Stellarium then reinstalled, giving permission to read/write it, I didnt find a directory automatically created in path /sdcard/ nor in /extSdCard/, I created the folder manually in /sdcard/, I renames it stellarium/landscapes/[name_of_the_installed_landscape]/landscape.ini and the accompioned png image, it didnt work, nor was showed in the app, that was on Android 7.0. I tried the same with other android but version 5.0 not 7.0 and rooted, didnt work, but I found the config.ini under /data/data/com.noctuasoftware.stellarium/files/.stellarium/, I moved my own landscape folder and put it here beside config.ini so in /landscapes/[my_own_landscape]/ I restated the device, didnt work. Thank you for all your time, I gave up for android :(

silas1037 commented 3 years ago

Stellarium 0.20.4 ported to Android has supported horizon polygon landscape. And this may work when introducing code from it.