AstronomyAPI/Samples

Moonphase rotated

Closed this issue · 11 comments

Hi there,

I was investigating the moonphase api and the image looks nice.
However, the moonphase seems to be rotated. The Last Quarter is show as First Quarter and also all other phase look incorrectly rotated.
It seems that the image has northern and southern hemisfere switched

Hi, thanks for noticing this. Will take a look.

Thanks, I also noticed the phase is called Wanning Crescent instead of Waning :)

Hi, the calculations are based on an observer facing south, so it's similar to looking at a star chart. Can you compare again with stellarium's results ?

Thanks, I also noticed the phase is called Wanning Crescent instead of Waning :)

i've fixed the typo

Could you send me the payload you're sending. It seems to be something related to your lat,long.

I'm not sure what exactly was the problem but these are the images i generated. All i did was clear the cdn cache.

https://widgets.astronomyapi.com/moon-phase/generated/402a266de480117c0e52b8e72b5d5178a206295ff7d615d7e51ae7a3753fcad1.svg

https://widgets.astronomyapi.com/moon-phase/generated/c24464410b717824057e6eb52c1242bb49040df6aeee7ab4f582b7aa99cd0e15.png

btw svg images has an alignment issue we're aware.

That is mighty strange, looks good to me!

I have tried calling it again and now generates the correct image :)
https://widgets.astronomyapi.com/moon-phase/generated/402a266de480117c0e52b8e72b5d5178a206295ff7d615d7e51ae7a3753fcad1.svg

Thanks for the help!

hey, must be something with the cache key. i'll take a look later. happy to help. :)

Hi, I have added a new parameter to change the rotation of the moon as needed. Modify the view object to add the new parameter as follows: Valid values are either "north-up" or "south-up". The parameter is optional, default value is "north-up"

"view": {
    "type": "portrait-simple",
    "orientation": "north-up"
}