First, this is so simple and yet so original. I absolutely love it. It feels like a tiny little piece of Star Trek or of science fiction but that's real and lives on my phone. So creative. It puts such a smile on my face. Super kudos!
Second, why does it need the phone to be flat? Depending on where the arrow's pointing, that's not always ideal. Would be great if there were a way to get around that.
Third, for some reason I really want the distance to the galactic center to be something absurdly and therefore entertainingly precise. Not a hard-coded nice round number of 26,000 light years, but something actually calculated in real time. Maybe it hides the decimals unless you click on it, but then... it not only calculates the live distance of the earth right now, but uses your exact location. (And if you want to use the GPS/accelerometer to have it update in real-time, that would be *chef's kiss*.)
The reason for the phone being flat is perhaps a limitation in iOS or perhaps a limitation of mine — I don’t know which! Basically you can access deviceHeading which is a projection of the north vector onto the long axis of the device. When the phone is orthogonal to north, that becomes unreliable, so the floating arrow breaks. What I really need is the north vector, real-time updated, relative to the device itself, no projection. But it seems like that isn’t available.
Huh, when I go into your debug tab the heading value always seems to stay accurate no matter if my phone is flat or vertical. It seems to work the same as the Compass app, which similarly stays accurate.
However, I do see that the drawn arrow totally breaks down when the phone is held vertically. So I wonder if maybe it's a bug somewhere in the calculations or drawing?
It would a lot of decimals... the diameter of the Earth's orbit is only 0.0000316 light years, and it's oriented fairly oblique to the galactic center, so the distance changes by only a fraction of that (roughly cos(40°).)
Of course, that's precisely what would make it entertaining!
But also interesting to see whether the number is increasing or decreasing at any given moment.
Of course, upon further reflection I realize that the rate of change is almost entirely determined by the position of the solar system in its elliptical orbit around the galaxy, and speed of the earth's elliptical orbit around the sun, and (at certain occasional points) your position in the rotational movement of the earth.
Anything using the accelerometer would be silly to include...
Comments
Three thoughts --
First, this is so simple and yet so original. I absolutely love it. It feels like a tiny little piece of Star Trek or of science fiction but that's real and lives on my phone. So creative. It puts such a smile on my face. Super kudos!
Second, why does it need the phone to be flat? Depending on where the arrow's pointing, that's not always ideal. Would be great if there were a way to get around that.
Third, for some reason I really want the distance to the galactic center to be something absurdly and therefore entertainingly precise. Not a hard-coded nice round number of 26,000 light years, but something actually calculated in real time. Maybe it hides the decimals unless you click on it, but then... it not only calculates the live distance of the earth right now, but uses your exact location. (And if you want to use the GPS/accelerometer to have it update in real-time, that would be *chef's kiss*.)
So kind, thank you!
The reason for the phone being flat is perhaps a limitation in iOS or perhaps a limitation of mine — I don’t know which! Basically you can access deviceHeading which is a projection of the north vector onto the long axis of the device. When the phone is orthogonal to north, that becomes unreliable, so the floating arrow breaks. What I really need is the north vector, real-time updated, relative to the device itself, no projection. But it seems like that isn’t available.
Huh, when I go into your debug tab the heading value always seems to stay accurate no matter if my phone is flat or vertical. It seems to work the same as the Compass app, which similarly stays accurate.
However, I do see that the drawn arrow totally breaks down when the phone is held vertically. So I wonder if maybe it's a bug somewhere in the calculations or drawing?
Hm okay, thank you that’s a good observation.
I need to find someone more familiar than I am with combining quaternions and reference frames to lend a hand!
It would a lot of decimals... the diameter of the Earth's orbit is only 0.0000316 light years, and it's oriented fairly oblique to the galactic center, so the distance changes by only a fraction of that (roughly cos(40°).)
Of course, that's precisely what would make it entertaining!
But also interesting to see whether the number is increasing or decreasing at any given moment.
Of course, upon further reflection I realize that the rate of change is almost entirely determined by the position of the solar system in its elliptical orbit around the galaxy, and speed of the earth's elliptical orbit around the sun, and (at certain occasional points) your position in the rotational movement of the earth.
Anything using the accelerometer would be silly to include...