mirror of
https://github.com/OpenSpace/OpenSpace.git
synced 2026-05-08 04:20:14 -05:00
Make the DestinationFrame in the SpiceRotation option and use GALACTIC if it is not specified
This commit is contained in:
@@ -68,8 +68,10 @@ namespace {
|
||||
std::string sourceFrame
|
||||
[[codegen::annotation("A valid SPICE NAIF name or integer")]];
|
||||
|
||||
// [[codegen::verbatim(DestinationInfo.description)]]
|
||||
std::string destinationFrame;
|
||||
// This value specifies the destination frame that is used for the coordinate
|
||||
// transformation. This has to be a valid SPICE name. If this value is not
|
||||
// specified, a reference frame of 'GALACTIC' is used instead
|
||||
std::optional<std::string> destinationFrame;
|
||||
|
||||
// [[codegen::verbatim(DestinationInfo.description)]]
|
||||
std::optional<std::variant<std::vector<std::string>, std::string>> kernels;
|
||||
@@ -99,7 +101,7 @@ SpiceRotation::SpiceRotation(const ghoul::Dictionary& dictionary)
|
||||
const Parameters p = codegen::bake<Parameters>(dictionary);
|
||||
|
||||
_sourceFrame = p.sourceFrame;
|
||||
_destinationFrame = p.destinationFrame;
|
||||
_destinationFrame = p.destinationFrame.value_or("GALACTIC");
|
||||
|
||||
if (p.kernels.has_value()) {
|
||||
if (std::holds_alternative<std::string>(*p.kernels)) {
|
||||
|
||||
Reference in New Issue
Block a user