9#include "NewHorizonsMvicFrameCamera.h"
15#include "CameraDetectorMap.h"
16#include "CameraDistortionMap.h"
17#include "CameraFocalPlaneMap.h"
18#include "CameraGroundMap.h"
19#include "CameraSkyMap.h"
22#include "NewHorizonsMvicFrameCameraDistortionMap.h"
23#include "NaifStatus.h"
55 m_exposure = inst[
"ExposureDuration"];
56 QString stime = inst[
"SpacecraftClockStartCount"];
59 double offset = 0.125;
62 et2utc_c(m_etStart,
"ISOC", 3, 30, utc);
70 PvlKeyword &origBand = bandBin[
"OriginalBand"];
72 for(
int i = 0; i < origBand.size(); i++) {
73 m_originalBand.push_back(
toInt(origBand[i]));
74 m_utcTime.push_back(utcTime[i]);
78 detectorMap->SetDetectorSampleSumming(1);
79 detectorMap->SetDetectorLineSumming(1);
84 focalMap->SetDetectorOrigin(2500.5, 64.5);
89 QString naifXKey =
"INS-98900_DISTORTION_COEF_X";
90 QString naifYKey =
"INS-98900_DISTORTION_COEF_Y";
91 QString naifppKey =
"INS-98900_PP_OFFSET";
92 vector<double> distCoefX;
93 vector<double> distCoefY;
95 for (
int i=0; i < 20; i++) {
96 distCoefX.push_back(
getDouble(naifXKey,i));
97 distCoefY.push_back(
getDouble(naifYKey,i));
119 if(vband > (
int) m_originalBand.size()) {
120 QString msg = QObject::tr(
"Band number out of array bounds in NewHorizonsMvicFrameCamera::SetBand legal "
121 "bands are [1-%1], input was [%2]").
122 arg(m_originalBand.size()).arg(vband);
127 double et =
time.Et();
130 et2utc_c(et,
"ISOC", 3, 30, utc);
Convert between parent image coordinates and detector coordinates.
Convert between distorted focal plane and detector coordinates.
Convert between undistorted focal plane and ground coordinates.
QString m_spacecraftNameLong
Full spacecraft name.
virtual double exposureDuration() const
Return the exposure duration for the pixel that the camera is set to.
void SetFocalLength()
Reads the focal length from the instrument kernel.
void SetPixelPitch()
Reads the Pixel Pitch from the instrument kernel.
void LoadCache()
This loads the spice cache big enough for this image.
QString m_instrumentNameShort
Shortened instrument name.
QString m_spacecraftNameShort
Shortened spacecraft name.
virtual void SetBand(const int band)
Virtual method that sets the band number.
QString m_instrumentNameLong
Full instrument name.
Convert between undistorted focal plane and ra/dec coordinates.
IO Handler for Isis Cubes.
Pvl * label() const
Returns a pointer to the IsisLabel object associated with the cube.
Generic class for Framing Cameras.
virtual std::pair< iTime, iTime > ShutterOpenCloseTimes(double time, double exposureDuration)=0
Returns the shutter open and close times.
@ Programmer
This error is for when a programmer made an API call that was illegal.
static void CheckErrors(bool resetNaif=true)
This method looks for any naif errors that might have occurred.
Distort/undistort focal plane coordinates for New Horizons/MVIC frame sensor.
This is the camera model for the New Horizons MVIC Frame mode Camera.
void SetBand(const int vband)
Sets the band in the camera model.
NewHorizonsMvicFrameCamera(Cube &cube)
Create a NewHorizonsMvicFrameCamera object.
virtual std::pair< iTime, iTime > ShutterOpenCloseTimes(double time, double exposureDuration)
Returns the shutter open and close times.
Contains multiple PvlContainers.
Container for cube-like labels.
A single keyword-value pair.
@ Traverse
Search child objects.
void setTime(const iTime &time)
By setting the time you essential set the position of the spacecraft and body as indicated in the cla...
virtual iTime getClockTime(QString clockValue, int sclkCode=-1, bool clockTicks=false)
This converts the spacecraft clock ticks value (clockValue) to an iTime.
virtual iTime time() const
Returns the ephemeris time in seconds which was used to obtain the spacecraft and sun positions.
SpiceInt naifIkCode() const
This returns the NAIF IK code to use when reading from instrument kernels.
SpiceDouble getDouble(const QString &key, int index=0)
This returns a value from the NAIF text pool.
Parse and return pieces of a time string.
This is free and unencumbered software released into the public domain.
int toInt(const QString &string)
Global function to convert from a string to an integer.
Namespace for the standard library.