8#include "IdealCamera.h"
16#include "CameraDistortionMap.h"
17#include "CameraFocalPlaneMap.h"
18#include "IException.h"
21#include "LineScanCameraDetectorMap.h"
22#include "LineScanCameraGroundMap.h"
23#include "LineScanCameraSkyMap.h"
24#include "NaifStatus.h"
75 if (inst.hasKeyword(
"FocalLength")) {
82 if (inst.hasKeyword(
"PixelPitch")) {
89 double et = inst[
"EphemerisTime"];
92 if (inst.hasKeyword(
"ExposureDuration")) {
96 double sampleDetectors = inst[
"SampleDetectors"];
97 double lineDetectors = inst[
"LineDetectors"];
102 int xDependency = inst[
"FocalPlaneXDependency"];
110 if (inst.hasKeyword(
"TransX")) xdir = inst[
"TransX"];
111 if (inst.hasKeyword(
"TransY")) ydir = inst[
"TransY"];
127 if (inst.hasKeyword(
"TransX0")) {
128 keyval[0] = inst[
"TransX0"];
132 keyval[yDependency] = 0.;
137 pdpool_c(
"IDEAL_TRANSX", 3, keyval);
146 if (inst.hasKeyword(
"TransY0")) {
147 keyval[0] = inst[
"TransY0"];
151 keyval[xDependency] = 0.;
156 pdpool_c(
"IDEAL_TRANSY", 3, keyval);
165 if (inst.hasKeyword(
"TransS0")) {
166 keyval[0] = inst[
"TransS0"];
169 keyval[xDependency] = 1 /
PixelPitch() * sdir;
170 keyval[yDependency] = 0.;
175 pdpool_c(
"IDEAL_TRANSS", 3, keyval);
184 if (inst.hasKeyword(
"TransL0")) {
185 keyval[0] = inst[
"TransL0"];
188 keyval[yDependency] = 1 /
PixelPitch() * ldir;
189 keyval[xDependency] = 0.0;
194 pdpool_c(
"IDEAL_TRANSL", 3, keyval);
198 QString type = (QString) inst[
"InstrumentType"];
199 if (type.toUpper() ==
"FRAMING") {
203 fmap->SetDetectorOrigin(sampleDetectors / 2.0 + 0.5,
204 lineDetectors / 2.0 + 0.5);
212 else if (type.toUpper() ==
"LINESCAN") {
216 fmap->SetDetectorOrigin(sampleDetectors / 2.0 + 0.5,
226 QString msg =
"Unknown InstrumentType [" +
227 (QString) inst[
"InstrumentType"] +
"]";
244 string msg =
"No CK Frame ID for Ideal Camera class";
256 string msg =
"No CK Reference ID for Ideal Camera class";
268 string msg =
"No SPK Target ID for Ideal Camera class";
280 string msg =
"No SPK Center ID for Ideal Camera class";
292 string msg =
"No SPK Reference ID for Ideal Camera class";
Convert between parent image coordinates and detector coordinates.
Distort/undistort focal plane coordinates.
Convert between distorted focal plane and detector coordinates.
@ Line
The x value of the focal plane maps to a line.
@ Sample
The x value of the focal plane maps to a sample.
Convert between undistorted focal plane and ground coordinates.
virtual double exposureDuration() const
Return the exposure duration for the pixel that the camera is set to.
double PixelPitch() const
Returns the pixel pitch.
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.
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.
@ User
A type of error that could only have occurred due to a mistake on the user's part (e....
virtual QString instrumentNameShort() const
This method returns the shortened instrument name.
virtual int CkFrameId() const
CK frame ID.
virtual int SpkReferenceId() const
SPK Reference ID.
virtual QString spacecraftNameLong() const
This method returns the full spacecraft name.
virtual int SpkTargetId() const
SPK Target ID.
virtual int CkReferenceId() const
CK Reference ID.
virtual int SpkCenterId() const
SPK Center ID.
QString m_instrumentNameShort
Shortened instrument name.
QString m_spacecraftNameLong
Full spacecraft name.
~IdealCamera()
Destroys the IdealCamera object.
QString m_spacecraftNameShort
Shortened spacecraft name.
IdealCamera(Cube &cube)
Creates a generic camera model.
virtual QString spacecraftNameShort() const
This method returns the shortened spacecraft name.
QString m_instrumentNameLong
Full instrument name.
virtual QString instrumentNameLong() const
This method returns the full instrument name.
bool p_framing
true if framing camera
Convert between parent image coordinates and detector coordinates.
Convert between undistorted focal plane and ground coordinates.
Convert between undistorted focal plane and ra/dec coordinates.
static void CheckErrors(bool resetNaif=true)
This method looks for any naif errors that might have occurred.
Contains multiple PvlContainers.
@ Traverse
Search child objects.
PvlGroupIterator findGroup(const QString &name, PvlGroupIterator beg, PvlGroupIterator end)
Find a group with the specified name, within these indexes.
void setTime(const iTime &time)
By setting the time you essential set the position of the spacecraft and body as indicated in the cla...
QVariant readValue(QString key, SpiceValueType type, int index=0)
This should be used for reading ALL text naif kernel values.
@ SpiceDoubleType
SpiceDouble type.
This is free and unencumbered software released into the public domain.
double toDouble(const QString &string)
Global function to convert from a string to a double.
Namespace for the standard library.