Skip to content

Comments

Latitude, Longitude and Altitude are now passed back from the sgp4 functions#136

Open
Alex-developer wants to merge 2 commits intokoansys:masterfrom
Alex-developer:master
Open

Latitude, Longitude and Altitude are now passed back from the sgp4 functions#136
Alex-developer wants to merge 2 commits intokoansys:masterfrom
Alex-developer:master

Conversation

@Alex-developer
Copy link

This has required changing the time parameter passed to the function
from the minutes since epoch to the julian date the position information
is required for.

This has required changing the time parameter passed to the function
from the minutes since epoch to the julian date the position information
is required for.
@Alex-developer
Copy link
Author

I forgot to do the non wegl version and can't create another pull request. so the changes are ...

index_crippled.js

MINUS jdSat = new Cesium.JulianDate.fromTotalDays(satrecs[satnum].jdsatepoch);
MINUS minutesSinceEpoch = jdSat.getMinutesDifference(julianDate);
MINUS rets = sgp4(satrecs[satnum], minutesSinceEpoch);
ADD jdSat = new Cesium.JulianDate();
ADD var time = jdSat.getJulianDayNumber() + jdSat.getJulianTimeFraction();
ADD rets = sgp4(satrecs[satnum], time);

MINUS newRow.insertCell(-1).appendChild(document.createTextNode(Cesium.Math.toDegrees(carto.latitude).toFixed(3)));
MINUS newRow.insertCell(-1).appendChild(document.createTextNode(Cesium.Math.toDegrees(carto.longitude).toFixed(3)));
MINUS newRow.insertCell(-1).appendChild(document.createTextNode(carto.height.toFixed(0)));
ADD newRow.insertCell(-1).appendChild(document.createTextNode(satrecs[satnum].lat.toFixed(3)));
ADD newRow.insertCell(-1).appendChild(document.createTextNode(satrecs[satnum].lon.toFixed(3)));
ADD newRow.insertCell(-1).appendChild(document.createTextNode(satrecs[satnum].alt.toFixed(3)));

not_supported.html

ADD script type="text/javascript" src="../js/post.js"></script>
ADD script type="text/javascript" src="../js/math_utils.js"></script>

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant