Isis 3 Programmer Reference
Isis::ProcessExportPds4 Class Reference

Process class for exporting cubes to PDS4 standards. More...

#include <ProcessExportPds4.h>

Inheritance diagram for Isis::ProcessExportPds4:
Inheritance graph
Collaboration diagram for Isis::ProcessExportPds4:
Collaboration graph

Public Types

enum  ImageType { StandardImage , BinSetSpectrum , UniformlySampledSpectrum }
 
enum  ExportFormat { BSQ , BIL , BIP , JP2 }
 Storage order enumeration. More...
 

Public Member Functions

 ProcessExportPds4 ()
 Default Constructor - Set to default the data members.
 
 ~ProcessExportPds4 ()
 Destructor.
 
QDomDocument & StandardPds4Label ()
 Create a standard PDS4 image label from the input cube.
 
QDomDocument & SpectralPds4Label ()
 
void StandardAllMapping ()
 Create the standard keywords for the IMAGE_MAP_PROJECTION group in a PDS label.
 
void CreateImageLabel ()
 Creates a PDS4 label.
 
void StandardImageImage ()
 
void OutputLabel (std::ofstream &os)
 Write the XML label to the supplied stream.
 
void StartProcess (std::ofstream &fout)
 This method fills the image data of the PDS4 file using the parent class ProcessExport::StartProcess.
 
QDomDocument & GetLabel ()
 Return the internalized PDS4 label.
 
void WritePds4 (QString outFile)
 This method write out the labels and image data to the specified output file.
 
QDomElement getElement (QStringList xmlPath, QDomElement parent=QDomElement())
 Convenience method to get an element given a path and its parent.
 
void addHistory (QString description, QString date="tbd", QString version="1.0")
 Add a modification history instance by adding a Modification_Detail entry to the Modification_History element.
 
void setLogicalId (QString lid)
 Allows mission specific programs to set logical_identifier required for PDS4 labels.
 
void setVersionId (QString versionId)
 Allows mission specific programs to set version_id required for PDS4 labels.
 
void setTitle (QString title)
 Allows mission specific programs to set the title required for PDS4 labels.
 
void setSchemaLocation (QString schema)
 Allows mission specific programs to use specified versions of dictionaries.
 
void setImageType (ImageType imageType)
 Create a standard PDS4 image label from the input cube.
 
void setPixelDescription (QString description)
 Sets the description string which describes the pixel vales in File_Area_Observational.
 
void reorder ()
 This method reorders the existing m_domDoc to follow PDS4 standards and fixes time formatting if needed.
 
void addSchema (QString sch, QString xsd, QString xmlns, QString xmlnsURI)
 Adds necessary information to the xml header for a pds4 class.
 
void addSchema (QString xsd, QString xmlns, QString xmlnsURI)
 Adds necessary information to the xml header for a pds4 class for schema which lack schematron files (.sch)
 
virtual void StartProcess (void funct(Isis::Buffer &in))
 This method invokes the process operation over a single input cube.
 
virtual void StartProcess (void funct(std::vector< Isis::Buffer * > &in))
 
virtual void StartProcess (std::ofstream &fout)
 Write an entire cube to an output file stream.
 
virtual void StartProcess (void funct())
 In the base class, this method will invoked a user-specified function exactly one time.
 
void SetOutputRange (const double minimum, const double maximum)
 Set output pixel range in Buffer.
 
void SetOutputNull (const double value)
 Set output special pixel value for NULL.
 
void SetOutputLis (const double value)
 Set output special pixel value for LIS.
 
void SetOutputLrs (const double value)
 Set output special pixel value for LRS.
 
void SetOutputHis (const double value)
 Set output special pixel value for HIS.
 
void SetOutputHrs (const double value)
 Set output special pixel value for HRS.
 
double OutputNull ()
 Return the output special pixel value for NULL.
 
double OutputLis ()
 Return the output special pixel value for LIS.
 
double OutputLrs ()
 Return the output special pixel value for LRS.
 
double OutputHis ()
 Return the output special pixel value for HIS.
 
double OutputHrs ()
 Return the output special pixel value for HRS.
 
bool HasInputRange () const
 
void SetInputRange ()
 Set input pixel range from user.
 
void SetInputRange (UserInterface &ui)
 
void SetInputRange (const double minimum, const double maximum)
 Set input pixel range from to a linear stretch.
 
void SetInputRange (const double minimum, const double maximum, const int index)
 Set input pixel range from to a linear stretch.
 
void SetInputRange (const double minimum, const double middle, const double maximum)
 Set input pixel range from to a piecewise linear stretch.
 
void SetInputRange (const double minimum, const double middle, const double maximum, const int index)
 Set input pixel range from to a piecewise linear stretch.
 
void CreateWorldFile (const QString &worldFile)
 Create a standard world file for the input cube.
 
void SetOutputEndian (enum ByteOrder endianness)
 Set byte endianness of the output cube.
 
void SetOutputType (Isis::PixelType pixelIn)
 Set output pixel bit type in Buffer.
 
void setCanGenerateChecksum (bool flag)
 @description Set m_canGenerateChecksum which determines if we can generate a MD5 checksum on the image data.
 
bool canGenerateChecksum ()
 @description Return if we can generate a checksum
 
QString checksum ()
 @description Generates a file checksum.
 
double GetInputMinimum (unsigned int n=0) const
 Get the valid minimum pixel value for the Nth input cube.
 
double GetInputMaximum (unsigned int n=0) const
 Get the valid maximum pixel value for the Nth input cube.
 
double GetOutputMinimum ()
 Get the valid minimum pixel value to be written to the output file.
 
double GetOutputMaximum ()
 Get the valid maximum pixel value to be written to the output file.
 
void setFormat (ExportFormat format)
 Sets the storage order of the output file.
 
template<typename Functor >
void ProcessCubes (const Functor &functor)
 
virtual void EndProcess ()
 End the processing sequence and cleans up by closing cubes, freeing memory, etc.
 
virtual void Finalize ()
 Cleans up by closing cubes and freeing memory for owned cubes.
 
virtual Isis::CubeSetInputCube (const QString &parameter, const int requirements=0)
 Opens an input cube specified by the user and verifies requirements are met.
 
virtual Isis::CubeSetInputCube (const QString &fname, const Isis::CubeAttributeInput &att, int requirements=0)
 Opens an input cube specified by the programmer and verifies requirements are met.
 
virtual void SetInputCube (Isis::Cube *inCube, int requirements=0)
 Set the InputCube vector to an opened Cube which was dynamically allocated.
 
virtual Isis::CubeSetOutputCube (const QString &parameter)
 Allocates a user-specified output cube whose size matches the first input cube.
 
virtual Isis::CubeSetOutputCube (const QString &parameter, const int nsamps, const int nlines, const int nbands=1)
 Allocates a user specified output cube whose size is specified by the programmer.
 
virtual Isis::CubeSetOutputCube (const QString &fname, const Isis::CubeAttributeOutput &att, const int nsamps, const int nlines, const int nbands=1)
 Allocates a output cube whose name and size is specified by the programmer.
 
virtual Isis::CubeSetOutputCubeStretch (const QString &parameter, UserInterface *ui=nullptr)
 Allocates a user-specified output cube whose size matches the first input cube.
 
virtual Isis::CubeSetOutputCubeStretch (const QString &parameter, const int nsamps, const int nlines, const int nbands=1, UserInterface *ui=nullptr)
 Allocates a user specified output cube whose size is specified by the programmer.
 
void AddInputCube (Cube *cube, bool owned=true)
 
void AddOutputCube (Cube *cube, bool owned=true)
 
void CheckRequirements (const Cube *cube, const int requirements)
 Checks to make sure the input cube meets the inputted requirements.
 
void ClearCubes ()
 Close owned cubes from the list and clear the list.
 
void ClearInputCubes ()
 Close owned input cubes from the list and clear the list.
 
void ClearOutputCubes ()
 Close owned output cubes from the list and clear the list.
 
void PropagateLabels (const bool prop)
 This method allows the programmer to turn on/off the propagation of labels from the 1st input cube to any of the output cubes.
 
void PropagateLabels (const QString &cube)
 This method allows the programmer to propagate labels from a specific secondary cube.
 
void PropagateTables (const bool prop)
 This method allows the programmer to propagate input tables to the output cube (default is true)
 
void PropagateTables (const QString &fromName, const QList< QString > &tableNames=QList< QString >())
 Propagate the tables from the cube with the given filename to the output cube.
 
void PropagatePolygons (const bool prop)
 This method allows the programmer to propagate input blobs to the output cube (default is true)
 
void PropagateHistory (const bool prop)
 This method allows the programmer to propagate history to the output cube (default is true)
 
void PropagateOriginalLabel (const bool prop)
 This method allows the programmer to propagate original labels to the output cube (default is true)
 
Isis::ProgressProgress ()
 This method returns a pointer to a Progress object.
 
QString MissionData (const QString &mission, const QString &file, bool highestVersion=false)
 This method reads the mission specific data directory from the user preference file, makes sure that mission is available in the Isis installation, and the attaches the provided input file to the directory in order to create a full file specification.
 
void WriteHistory (Cube &cube)
 Writes out the History blob to the cube.
 
void CalculateStatistics ()
 Calculates and stores off statistics on every band of every cube added to this process via the SetInputCube method.
 
std::vector< Isis::Statistics * > BandStatistics (const unsigned index)
 Get the vector of Statistics objects for each band separately of a specified input cube.
 
Isis::StatisticsCubeStatistics (const unsigned index)
 Get the Statistics object for all bands of a specified input cube.
 

Static Public Member Functions

static void translateUnits (QDomDocument &label, QString transMapFile="$ISISROOT/appdata/translations/pds4ExportUnits.pvl")
 This function will go through an XML document and attempt to convert all "units" attributes to the appropriate PDS4 units format.
 

Protected Member Functions

void identificationArea ()
 This method writes the identification information to the PDS4 labels.
 
void standardInstrument ()
 This method translates the information from the ISIS Instrument group to the PDS4 labels.
 
void standardBandBin ()
 Export bandbin group to sp:Spectral Characteristics.
 
void displaySettings ()
 This method writes the display direction information to the PDS4 labels.
 
void fileAreaObservational ()
 Create and internalize an image output label from the input image.
 
QString PDS4PixelType (PixelType pixelType, ByteOrder endianType)
 Helper function for converting ISIS pixel type and byte order to a PDS4 data_type value.
 
void translateBandBinImage (Pvl &inputLabel)
 Export BandBin group for 2D or 3D Image format.
 
void translateBandBinSpectrumUniform (Pvl &inputLabel)
 Export BandBin group for uniformly spaced 3D Spectral data format.
 
void translateBandBinSpectrumBinSet (Pvl &inputLabel)
 Export BandBin group for non-uniformly spaced 3D Spectral data format.
 
std::vector< BufferManager * > GetBuffers ()
 
std::vector< BufferManager * > GetBuffersBSQ ()
 A single line of input data from each input cube will be passed to the line processing function.
 
std::vector< BufferManager * > GetBuffersBIL ()
 A single line of input data from each input cube will be passed to the line processing function.
 
std::vector< BufferManager * > GetBuffersBIP ()
 A single band of input data from each input cube will be passed to the band processing function.
 

Static Protected Member Functions

static QMap< QString, QString > createUnitMap (Pvl configPvl)
 Helper function for creating the unit translation map from a PVL object.
 
static void translateChildUnits (QDomElement parent, QMap< QString, QString > transMap)
 Recursive method that will translate the "unit" attribute of any child elements of a given element.
 

Protected Attributes

QDomDocument * m_domDoc
 XML label.
 
QString m_schemaLocation
 QString with all schema locations required.
 
QString m_lid
 QString with specified logical identifier.
 
QString m_versionId
 QString with specified version id.
 
QString m_title
 QString with specified title.
 
ImageType m_imageType
 Type of image data to be written.
 
QString m_pixelDescription
 Description of pixel values.
 
ExportFormat p_format
 Current storage order.
 
double p_outputMinimum
 Desired minimum pixel value in the Buffer.
 
double p_outputMiddle
 Middle pixel value (minimum+maximun)/2.0 in the Buffer.
 
double p_outputMaximum
 Desired maximum pixel value in the Buffer.
 
std::vector< double > p_inputMinimum
 Minimum pixel value in the input cube to be mapped to the minimum value in the Buffer.
 
std::vector< double > p_inputMiddle
 Middle pixel value in the input cube to be mapped to the (minimum+maximum)/2.0 value in the Buffer.
 
std::vector< double > p_inputMaximum
 Maximum pixel value in the input cube to be mapped to the maximum value in the Buffer.
 
EndianSwapperp_endianSwap
 Object to swap the endianness of the raw output to either MSB or LSB.
 
ByteOrder p_endianType
 The byte order of the output file.
 
PixelType p_pixelType
 The bits per pixel of the output image.
 
std::vector< Stretch * > p_str
 Stretch object to ensure a reasonable range of pixel values in the output data.
 
double p_Null
 The output value for pixels whose input DNs are Null values.
 
double p_Lis
 The output value for pixels whose input DNs are Low Instrument Saturation values.
 
double p_Lrs
 The output value for pixels whose input DNs are Low Representation Saturation values.
 
double p_His
 The output value for pixels whose input DNs are High Instrument Saturation values.
 
double p_Hrs
 The output value for pixels whose input DNs are High Representation Saturation values.
 
bool p_Null_Set
 Indicates whether p_Null has been set (i.e.
 
bool p_Lis_Set
 Indicates whether p_Lis has been set (i.e.
 
bool p_Lrs_Set
 Indicates whether p_Lrs has been set (i.e.
 
bool p_His_Set
 Indicates whether p_His has been set (i.e.
 
bool p_Hrs_Set
 Indicates whether p_Hrs has been set (i.e.
 
QCryptographicHash * m_cryptographicHash
 A cryptographic hash that will generate an MD5 checksum of the image data.
 
bool m_canGenerateChecksum
 Flag to determine if a file checksum will be generated.
 
Isis::Progressp_progress
 Pointer to a Progress object.
 
bool p_propagateLabels
 Flag indicating if labels are be propagated to output cubes.
 
bool p_propagateTables
 Flag indicating if tables are be propagated to output cubes.
 
bool p_propagatePolygons
 Flag indicating if blobs are be propagated to output cubes.
 
bool p_propagateHistory
 Flag indicating if history is to be propagated to output cubes.
 
bool p_propagateOriginalLabel
 Flag indicating if original lable is to be propagated to output cubes.
 
std::vector< std::vector< Isis::Statistics * > > p_bandStats
 Holds the calculated statistics for each band separately of every input cubei after the CalculateStatistics method is called.
 
std::vector< Isis::Statistics * > p_cubeStats
 Holds the calculated statistics for every band together of every input cubei after the CalculateStatistics method is called.
 
std::vector< Isis::Cube * > InputCubes
 A vector of pointers to opened Cube objects.
 
std::vector< Isis::Cube * > OutputCubes
 A vector of pointers to allocated Cube objects.
 
QSet< Isis::Cube * > * m_ownedCubes
 A list of cubes owned by this instant.
 

Private Member Functions

void isisOut8 (Buffer &in, std::ofstream &fout)
 Method for writing 8-bit unsigned pixel data to a file stream.
 
void isisOut16s (Buffer &in, std::ofstream &fout)
 Method for writing 16-bit signed pixel data to a file stream.
 
void isisOut16u (Buffer &in, std::ofstream &fout)
 Method for writing 16-bit unsigned pixel data to a file stream.
 
void isisOut32 (Buffer &in, std::ofstream &fout)
 Method for writing 32-bit signed floating point pixels data to a file stream.
 
void isisOut64 (Buffer &in, std::ofstream &fout)
 Method for writing 64-bit signed double precision floating point pixels data to a file stream.
 
void InitProcess ()
 Convenience method that checks to make sure the user is only using valid input to the StartProcess method.
 

Detailed Description

Process class for exporting cubes to PDS4 standards.

This class extends the ProcessExport class to allow the user to export cubes to PDS4 format.

Author
2017-05-25 Marjorie Hahn and Makayla Shepherd
History

2017-05-31 Ian Humphrey - Added check in StandardPds4Label to thrown an exception if there is no input cube set.

2017-06-01 Ian Humphrey - Added XML declaration and updated attributes for Product_Observational tag.

2017-06-02 Marjorie Hahn - Added global hash seed to force a consistent output (XML attribute order).

2017-06-02 Adam Paquette - Updated call to translation file to use a translation file in the isis data area.

2017-06-02 Makayla Shepherd - Added CreateImageLabel, FixedImageRoot, and StandardImageImage to add hardcoded values to the xml label.

2017-06-04 Adam Paquette - Added GetLabel function and updated StandardPds4Label.

2017-06-08 Marjorie Hahn - Added WritePds4 method to write out the .img and .xml Pds4 data.

2017-09-26 Jesse Mapel - Improved test coverage and documentation. Fixes #5167.

2017-10-18 Jeannie Backer & Makayla Shepherd - Added convenience method getElement and StandardAllMapping method to translate mapping information. See #5202.

2017-10-31 Jeannie Backer - Added standardInstrument() and displaySettings() translations.

2017-11-06 Kristin Berry - Added standardBandBin()

2017-11-07 Jeannie Backer - Added code to search for target in the Mapping group if no instrument group is found. Added Identification Area tranlations. Added sanity checks to getElement().

2017-11-07 Jeannie Backer - Added code to write data file info into label file. Added code to translate time format and add nil tag if empty.

2017-11-15 Jesse Mapel - Added translateUnits method to convert units to PDS4 standard format.

2017-11-16 Kristin Berry - Updated WritePds4 to put the File information first in the output File_Area_Observational.

2017-11-17 Jesse Mapel - Removed empty FixedImageRoot method.

2017-11-20 Jeannie Backer - Updated StandardImageImage() to re-order the Array_3D_Image values properly.

2017-11-21 Kristin Berry - Updated the constructor to add the xml version and encoding to the beginning of the XML file.

2018-02-05 Kristin Berry - Updated WritePds4 to remove the .xml and add a .img if the user inputs something of the form filename.xml as the image output name.

2018-05-16 Christopher Combs - Fixed typo in xml namespaces and changed History attributes to elements. Matches pds validate tool specifations.

2018-06-12 Kristin Berry - Added schema associated with the img class when it is used.

2019-03-01 Kristin Berry - Added ability to set version_id and title, added Special_Constants to define ISIS special pixel values, fixed east/west bounding coordinates swap bug. Fixes git issue #2635.

2019-06-15 Kristin Berry - Added a new addSchema() function for cases in which a schematron file is not available and added setPixelDescription to set a pixel description for the output image.

Definition at line 74 of file ProcessExportPds4.h.

Member Enumeration Documentation

◆ ExportFormat

Storage order enumeration.

Enumerator
BSQ 

Band sequential.

BIL 

Band interleaved by line.

BIP 

Band interleaved by pixel.

JP2 

Compressed JPEG2000.

Definition at line 116 of file ProcessExport.h.

◆ ImageType

enum Isis::ProcessExportPds4::ImageType

Definition at line 80 of file ProcessExportPds4.h.

Constructor & Destructor Documentation

◆ ProcessExportPds4()

Isis::ProcessExportPds4::ProcessExportPds4 ( )

Default Constructor - Set to default the data members.

Definition at line 35 of file ProcessExportPds4.cpp.

References m_domDoc, m_imageType, m_lid, m_schemaLocation, m_title, and m_versionId.

◆ ~ProcessExportPds4()

Isis::ProcessExportPds4::~ProcessExportPds4 ( )

Destructor.

Definition at line 71 of file ProcessExportPds4.cpp.

References m_domDoc.

Member Function Documentation

◆ addHistory()

void Isis::ProcessExportPds4::addHistory ( QString description,
QString date = "tbd",
QString version = "1.0" )

Add a modification history instance by adding a Modification_Detail entry to the Modification_History element.

If there are no existing entries, this will create a Modification_History element also.

Parameters
descriptionThe description of the modification.
dateThe date of the modification. Expected format is "YYYY-MM-DD". Defaults to "tbd".
versionThe product version. Expected format is "m.n". Defaults to "tbd".

Definition at line 1399 of file ProcessExportPds4.cpp.

References getElement(), m_domDoc, Isis::IException::Programmer, Isis::PvlToXmlTranslationManager::setElementValue(), and Isis::IException::Unknown.

Referenced by identificationArea().

◆ AddInputCube()

void Isis::Process::AddInputCube ( Cube * cube,
bool owned = true )
inherited

Definition at line 476 of file Process.cpp.

◆ AddOutputCube()

void Isis::Process::AddOutputCube ( Cube * cube,
bool owned = true )
inherited

Definition at line 482 of file Process.cpp.

◆ addSchema() [1/2]

void Isis::ProcessExportPds4::addSchema ( QString sch,
QString xsd,
QString xmlns,
QString xmlnsURI )

Adds necessary information to the xml header for a pds4 class.

Parameters
schSchematron filename without path
xsdSchema filename without path
xmlnsThe xml namespace used
xmlnsURIFull URL to the xml namespace URI. Also used as the location of the sch and xsd

Definition at line 1044 of file ProcessExportPds4.cpp.

References addSchema(), and m_domDoc.

Referenced by addSchema(), displaySettings(), StandardAllMapping(), and standardBandBin().

◆ addSchema() [2/2]

void Isis::ProcessExportPds4::addSchema ( QString xsd,
QString xmlns,
QString xmlnsURI )

Adds necessary information to the xml header for a pds4 class for schema which lack schematron files (.sch)

Parameters
xsdSchema filename without path
xmlnsThe xml namespace used
xmlnsURIFull URL to the xml namespace URI. Also used as the location of the sch and xsd

Definition at line 1020 of file ProcessExportPds4.cpp.

References m_domDoc, and m_schemaLocation.

◆ BandStatistics()

std::vector< Isis::Statistics * > Isis::Process::BandStatistics ( const unsigned index)
inlineinherited

Get the vector of Statistics objects for each band separately of a specified input cube.

Parameters
indexThe index of the input cube in InputCubes
Returns
vector<Statistics*> A list of statistics ordered by band

Definition at line 279 of file Process.h.

References Isis::Process::p_bandStats.

◆ CalculateStatistics()

void Isis::Process::CalculateStatistics ( )
inherited

Calculates and stores off statistics on every band of every cube added to this process via the SetInputCube method.

The newly calculated statistics are stored in two ways: as a vector where each entry is a single Statistics object for every band of a particular input cube, and as a vector where each entry is a vector of Statistics objects, for each band separately, of a particular input cube.

Definition at line 858 of file Process.cpp.

References Isis::Cube::bandCount(), Isis::Progress::CheckStatus(), Isis::Buffer::DoubleBuffer(), Isis::Process::InputCubes, Isis::Cube::lineCount(), Isis::Process::p_bandStats, Isis::Process::p_cubeStats, Isis::Cube::read(), Isis::LineManager::SetLine(), Isis::Progress::SetMaximumSteps(), Isis::Progress::SetText(), Isis::Buffer::size(), and Isis::toString().

◆ canGenerateChecksum()

bool Isis::ProcessExport::canGenerateChecksum ( )
inherited

@description Return if we can generate a checksum

Returns
Boolean to generate the checksum or not

Definition at line 684 of file ProcessExport.cpp.

References Isis::ProcessExport::m_canGenerateChecksum.

Referenced by Isis::ProcessExportPds::FixedImageRoot(), and Isis::ProcessExportPds::StreamImageRoot().

◆ CheckRequirements()

void Isis::Process::CheckRequirements ( const Cube * cube,
const int requirements )
inherited

Checks to make sure the input cube meets the inputted requirements.

Parameters
cubeCube to check
requirementsUse to specify requirements for the input file. The following requirments are checked against 1) ic_base::SizeMatch checks to make sure the input cube has the same bands, samples, and lines as the first input cube open using this method, 2) ic_base::SpatialMatch checks to make sure the input cube has the same samples and lines as the first input cube, 3) ic_base::Georeferenced checks to make sure latitude/longitudes can be obtained from the input cube, 4) ic_base::FullyGeoreferenced checks to make sure latitude/longitude, phase/incidence/emission, and other geometric parameters can be obtained from the input cube, 5) ic_base::OneBand checks to make sure the input cube has exactly one band. Note, that these requirements can be logically or'ed. For example, ic_base::SpatialMatch | ic_base::georeferenced. Defaults to 0
Exceptions
Isis::iException::Message

Definition at line 513 of file Process.cpp.

References Isis::Cube::bandCount(), Isis::Cube::fileName(), Isis::Process::InputCubes, Isis::Cube::lineCount(), Isis::Cube::sampleCount(), and Isis::IException::User.

Referenced by Isis::Process::SetInputCube(), and Isis::Process::SetInputCube().

◆ checksum()

QString Isis::ProcessExport::checksum ( )
inherited

@description Generates a file checksum.

This must be called after StartProcess.

Returns
QString Returns a QString of the checksum.

Definition at line 694 of file ProcessExport.cpp.

References Isis::ProcessExport::checksum(), Isis::ProcessExport::m_canGenerateChecksum, Isis::ProcessExport::m_cryptographicHash, and Isis::IException::Programmer.

Referenced by Isis::ProcessExport::checksum(), and Isis::ProcessExportPds::updateChecksumInLabel().

◆ ClearCubes()

void Isis::Process::ClearCubes ( )
inherited

Close owned cubes from the list and clear the list.

Definition at line 603 of file Process.cpp.

References Isis::Process::ClearInputCubes(), Isis::Process::ClearOutputCubes(), and Isis::Process::m_ownedCubes.

Referenced by Isis::Process::Finalize().

◆ ClearInputCubes()

void Isis::Process::ClearInputCubes ( )
inherited

Close owned input cubes from the list and clear the list.

Definition at line 614 of file Process.cpp.

References Isis::Process::InputCubes, and Isis::Process::m_ownedCubes.

Referenced by Isis::Process::ClearCubes(), Isis::ProcessGroundPolygons::SetStatCubes(), and Isis::ProcessMapMosaic::StartProcess().

◆ ClearOutputCubes()

void Isis::Process::ClearOutputCubes ( )
inherited

Close owned output cubes from the list and clear the list.

Definition at line 629 of file Process.cpp.

References Isis::Process::m_ownedCubes, and Isis::Process::OutputCubes.

Referenced by Isis::Process::ClearCubes().

◆ CreateImageLabel()

void Isis::ProcessExportPds4::CreateImageLabel ( )

Creates a PDS4 label.

The image label will be stored internally in the class.

This method has a similar function to ProcessExportPds::CreateImageLabel. However, it will create images of object type Array_3D_Image, Array_2D_Image, or Array_3D_Spectrum.

Definition at line 108 of file ProcessExportPds4.cpp.

References displaySettings(), fileAreaObservational(), identificationArea(), Isis::Process::InputCubes, m_domDoc, Isis::IException::Programmer, StandardAllMapping(), standardBandBin(), and standardInstrument().

Referenced by StandardPds4Label().

◆ createUnitMap()

QMap< QString, QString > Isis::ProcessExportPds4::createUnitMap ( Pvl configPvl)
staticprotected

Helper function for creating the unit translation map from a PVL object.

Parameters
configPvlThe config PVL that defines the map.
Returns
QMap<QString,QString> The map that converts lower case ISIS units to PDS4 units.
See also
ProcessExportPds4::translateUnits

Definition at line 1505 of file ProcessExportPds4.cpp.

References Isis::PvlContainer::name(), Isis::PvlObject::object(), and Isis::IException::Programmer.

Referenced by translateUnits().

◆ CreateWorldFile()

void Isis::ProcessExport::CreateWorldFile ( const QString & worldFile)
inherited

Create a standard world file for the input cube.

This method creates a standard world file from the mapping group of the input cube.

Parameters
worldFile[in] Reference to a string containing the name of a file to write the world information to.

Definition at line 1255 of file ProcessExport.cpp.

References Isis::Process::InputCubes, and Isis::Projection::SetWorld().

◆ CubeStatistics()

Isis::Statistics * Isis::Process::CubeStatistics ( const unsigned index)
inlineinherited

Get the Statistics object for all bands of a specified input cube.

Parameters
indexThe index of the input cube in InputCubes
Returns
Statistics* Collections of statistics gathered on all bands

Definition at line 293 of file Process.h.

References Isis::Process::p_cubeStats.

◆ displaySettings()

void Isis::ProcessExportPds4::displaySettings ( )
protected

This method writes the display direction information to the PDS4 labels.

Definition at line 521 of file ProcessExportPds4.cpp.

References addSchema(), Isis::Process::InputCubes, and m_domDoc.

Referenced by CreateImageLabel().

◆ EndProcess()

void Isis::Process::EndProcess ( )
virtualinherited

◆ fileAreaObservational()

◆ Finalize()

void Isis::Process::Finalize ( )
virtualinherited

◆ GetBuffers()

vector< BufferManager * > Isis::ProcessExport::GetBuffers ( )
protectedinherited

Definition at line 870 of file ProcessExport.cpp.

◆ GetBuffersBIL()

vector< BufferManager * > Isis::ProcessExport::GetBuffersBIL ( )
protectedinherited

A single line of input data from each input cube will be passed to the line processing function.

Note the data will be stretched based on the invocations of the SetInputRange and SetOutputRange methods.

Parameters
funct(Isis::Buffer &b) Name of your line processing function. The buffer in will contain stretched input cube pixels for an entire line of each input cube. These pixels must be written to the foreign output file (e.g, jpg, tif, etc).

Definition at line 944 of file ProcessExport.cpp.

References Isis::Process::InputCubes, and Isis::IException::Programmer.

◆ GetBuffersBIP()

vector< BufferManager * > Isis::ProcessExport::GetBuffersBIP ( )
protectedinherited

A single band of input data from each input cube will be passed to the band processing function.

Note the data will be stretched based on the invocations of the SetInputRange and SetOutputRange methods.

Parameters
funct(Isis::Buffer &b) Name of your band processing function. The buffer in will contain stretched input cube pixels for an entire line of each input cube. These pixels must be written to the foreign output file (e.g, jpg, tif, etc).

Definition at line 982 of file ProcessExport.cpp.

References Isis::Process::InputCubes, and Isis::IException::Programmer.

◆ GetBuffersBSQ()

vector< BufferManager * > Isis::ProcessExport::GetBuffersBSQ ( )
protectedinherited

A single line of input data from each input cube will be passed to the line processing function.

Note the data will be stretched based on the invocations of the SetInputRange and SetOutputRange methods.

Parameters
funct(Isis::Buffer &b) Name of your line processing function. The buffer in will contain stretched input cube pixels for an entire line of each input cube. These pixels must be written to the foreign output file (e.g, jpg, tif, etc).

Definition at line 905 of file ProcessExport.cpp.

References Isis::Process::InputCubes, and Isis::IException::Programmer.

◆ getElement()

QDomElement Isis::ProcessExportPds4::getElement ( QStringList xmlPath,
QDomElement parent = QDomElement() )

Convenience method to get an element given a path and its parent.

Parameters
xmlPathThe XML path to the element to retrieve, starting at the parent element. Note: The first element of this path must be the same as the parent element passed in, unless the parent element is NULL. If the parent element passed in is NULL, then we assume that the parent is the root and a full path has been given.
parentThe parent QDomElement of the given path. Defaults to the root element of the document.
Returns
QDomElement

Definition at line 1327 of file ProcessExportPds4.cpp.

References m_domDoc, and Isis::IException::Programmer.

Referenced by addHistory(), identificationArea(), reorder(), StandardAllMapping(), translateBandBinSpectrumBinSet(), and translateBandBinSpectrumUniform().

◆ GetInputMaximum()

double Isis::ProcessExport::GetInputMaximum ( unsigned int n = 0) const
inherited

Get the valid maximum pixel value for the Nth input cube.

Definition at line 429 of file ProcessExport.cpp.

References Isis::ProcessExport::p_inputMaximum, and Isis::IException::Programmer.

Referenced by Isis::ImageExporter::inputMaximum().

◆ GetInputMinimum()

double Isis::ProcessExport::GetInputMinimum ( unsigned int n = 0) const
inherited

Get the valid minimum pixel value for the Nth input cube.

Definition at line 418 of file ProcessExport.cpp.

References Isis::ProcessExport::p_inputMinimum, and Isis::IException::Programmer.

Referenced by Isis::ImageExporter::inputMinimum().

◆ GetLabel()

QDomDocument & Isis::ProcessExportPds4::GetLabel ( )

Return the internalized PDS4 label.

If no label is internalized yet, an empty label will be returned.

Returns
QDomDocument The PDS4 Xml label

Definition at line 1089 of file ProcessExportPds4.cpp.

References m_domDoc.

◆ GetOutputMaximum()

double Isis::ProcessExport::GetOutputMaximum ( )
inlineinherited

Get the valid maximum pixel value to be written to the output file.

Definition at line 165 of file ProcessExport.h.

References Isis::ProcessExport::p_outputMaximum.

◆ GetOutputMinimum()

double Isis::ProcessExport::GetOutputMinimum ( )
inlineinherited

Get the valid minimum pixel value to be written to the output file.

Definition at line 161 of file ProcessExport.h.

References Isis::ProcessExport::p_outputMinimum.

◆ HasInputRange()

bool Isis::ProcessExport::HasInputRange ( ) const
inherited

Definition at line 412 of file ProcessExport.cpp.

◆ identificationArea()

◆ InitProcess()

void Isis::ProcessExport::InitProcess ( )
privateinherited

Convenience method that checks to make sure the user is only using valid input to the StartProcess method.

Set cube up for processing.

Also sets the cube up to be processed by performing the necessary stretches.

This method is called from startProcess() to validate the input cube before processing and to ready the input cube for reading line by line in the cases of BSQ and BIL, or reading band by band in the case of BIP.

Exceptions
Isis::iException::Message- No input cube was specified

Definition at line 726 of file ProcessExport.cpp.

References Isis::ProcessExport::BIP, Isis::Progress::CheckStatus(), Isis::Process::InputCubes, Isis::IsValidPixel(), Isis::ProcessExport::OutputHis(), Isis::ProcessExport::OutputHrs(), Isis::ProcessExport::OutputLis(), Isis::ProcessExport::OutputLrs(), Isis::ProcessExport::OutputNull(), Isis::ProcessExport::p_format, Isis::ProcessExport::p_inputMaximum, Isis::ProcessExport::p_inputMiddle, Isis::ProcessExport::p_inputMinimum, Isis::ProcessExport::p_outputMaximum, Isis::ProcessExport::p_outputMiddle, Isis::ProcessExport::p_outputMinimum, Isis::Process::p_progress, Isis::ProcessExport::p_str, Isis::IException::Programmer, and Isis::Progress::SetMaximumSteps().

Referenced by Isis::ProcessExport::StartProcess(), and Isis::ProcessExport::StartProcess().

◆ isisOut16s()

void Isis::ProcessExport::isisOut16s ( Buffer & in,
std::ofstream & fout )
privateinherited

Method for writing 16-bit signed pixel data to a file stream.

Write a buffer of 16-bit signed pixel data to a stream.

This method takes a buffer of data and assumes that it is 16-bit signed pixel data. It will apply the necessary endian swap to the data and write it out to the output file buffer that the user specifies. The user can only expect to access this method indirectly by calling the StartProcess method.

Parameters
&inReference to a single buffer of pixel data. Note that this buffer will already have had the necessary stretching operations, though it will have the native endianness of the system.
&foutName of the file stream to which the buffer of pixel data will be written.

Definition at line 1136 of file ProcessExport.cpp.

References Isis::ProcessExport::p_endianSwap, and Isis::EndianSwapper::ShortInt().

Referenced by Isis::ProcessExport::StartProcess().

◆ isisOut16u()

void Isis::ProcessExport::isisOut16u ( Buffer & in,
std::ofstream & fout )
privateinherited

Method for writing 16-bit unsigned pixel data to a file stream.

Write a bufferof 16-bit unsigned pixel data to a stream.

This method takes a buffer of data and assumes that it is 16-bit unsigned pixel data. It will apply the necessary endian swap to the data and write it out to the output file buffer that the user specifies. The user can only expect to access this method indirectly by calling the StartProcess method.

Parameters
&inReference to a single buffer of pixel data. Note that this buffer will already have had the necessary stretching operations, though it will have the native endianness of the system.
&foutName of the file stream to which the buffer of pixel data will be written.

Definition at line 1183 of file ProcessExport.cpp.

References Isis::ProcessExport::p_endianSwap, and Isis::EndianSwapper::UnsignedShortInt().

Referenced by Isis::ProcessExport::StartProcess().

◆ isisOut32()

void Isis::ProcessExport::isisOut32 ( Buffer & in,
std::ofstream & fout )
privateinherited

Method for writing 32-bit signed floating point pixels data to a file stream.

Write a buffer of 32-bit floating point pixel data to a stream.

This method takes a buffer of data and assumes that it is 32-bit floating point pixel data. It will apply the necessary endian swap to the data and write it out to the output file buffer that the user specifies. The user can only expect to access this method indirectly by calling the StartProcess method.

Parameters
&inReference to a single buffer of pixel data. Note that this buffer will already have had the necessary stretching operations, though it will have the native endianness of the system.
&foutName of the file stream to which the buffer of pixel data will be written.

Definition at line 1223 of file ProcessExport.cpp.

References Isis::EndianSwapper::ExportFloat(), and Isis::ProcessExport::p_endianSwap.

Referenced by Isis::ProcessExport::StartProcess().

◆ isisOut64()

void Isis::ProcessExport::isisOut64 ( Buffer & in,
std::ofstream & fout )
privateinherited

Method for writing 64-bit signed double precision floating point pixels data to a file stream.

◆ isisOut8()

void Isis::ProcessExport::isisOut8 ( Buffer & in,
std::ofstream & fout )
privateinherited

Method for writing 8-bit unsigned pixel data to a file stream.

Write a buffer of 8-bit pixel data to a stream.

This method takes a buffer of data and assumes that it is 8 bit pixel data. It will apply the necessary endian swap to the data and write it out to the output file buffer that the user specifies. The user can only expect to access this method indirectly by calling the StartProcess method

Parameters
&inReference to a single buffer of pixel data. Note that this buffer will already have had the necessary stretching operations, though it will have the native endianness of the system.
&foutName of the file stream to which the buffer of pixel data will be written.

Definition at line 1099 of file ProcessExport.cpp.

Referenced by Isis::ProcessExport::StartProcess().

◆ MissionData()

QString Isis::Process::MissionData ( const QString & mission,
const QString & file,
bool highestVersion = false )
inherited

This method reads the mission specific data directory from the user preference file, makes sure that mission is available in the Isis installation, and the attaches the provided input file to the directory in order to create a full file specification.

Parameters
missionName of the mission data directory
fileName of the file to attach to the end of the directory
highestVersionIf set to true the method will return the highest version number of the given file. Therefore, file must contain question marks such as "file???.dat". See the FileName class for more information on versioned files. Defaults to false.

Definition at line 788 of file Process.cpp.

References Isis::FileName::expanded(), Isis::FileName::fileExists(), Isis::FileName::highestVersion(), Isis::IException::Io, and Isis::FileName::original().

◆ OutputHis()

double Isis::ProcessExport::OutputHis ( )
inherited

◆ OutputHrs()

double Isis::ProcessExport::OutputHrs ( )
inherited

◆ OutputLabel()

void Isis::ProcessExportPds4::OutputLabel ( std::ofstream & os)

Write the XML label to the supplied stream.

Parameters
[out]osfile stream to which the XML label will be written.

Definition at line 1066 of file ProcessExportPds4.cpp.

References m_domDoc.

Referenced by WritePds4().

◆ OutputLis()

double Isis::ProcessExport::OutputLis ( )
inherited

◆ OutputLrs()

double Isis::ProcessExport::OutputLrs ( )
inherited

◆ OutputNull()

double Isis::ProcessExport::OutputNull ( )
inherited

◆ PDS4PixelType()

QString Isis::ProcessExportPds4::PDS4PixelType ( PixelType pixelType,
ByteOrder endianType )
protected

Helper function for converting ISIS pixel type and byte order to a PDS4 data_type value.

Parameters
pixelTypeThe ISIS pixel type of the data
endianTypeThe byte order of the data
Returns
QString The PDS4 data_type value for the given pixel type and byte order.

Definition at line 1359 of file ProcessExportPds4.cpp.

References Isis::ProcessExport::p_endianType, Isis::ProcessExport::p_pixelType, and Isis::IException::User.

Referenced by fileAreaObservational().

◆ ProcessCubes()

template<typename Functor >
void Isis::ProcessExport::ProcessCubes ( const Functor & functor)
inlineinherited

Definition at line 175 of file ProcessExport.h.

◆ Progress()

Isis::Progress * Isis::Process::Progress ( )
inlineinherited

This method returns a pointer to a Progress object.

Returns
Progress*

Definition at line 259 of file Process.h.

References Isis::Process::p_progress.

Referenced by Isis::Equalization::applyCorrection(), and Isis::ProcessMapMosaic::StartProcess().

◆ PropagateHistory()

void Isis::Process::PropagateHistory ( const bool prop)
inherited

This method allows the programmer to propagate history to the output cube (default is true)

Parameters
propFlag indicating if history is to be propagated to output cubes.

Definition at line 755 of file Process.cpp.

References Isis::Process::p_propagateHistory.

◆ PropagateLabels() [1/2]

void Isis::Process::PropagateLabels ( const bool prop)
inherited

This method allows the programmer to turn on/off the propagation of labels from the 1st input cube to any of the output cubes.

By default, propagation occurs automatically in the Process class when a call to either of the SetOutputCube methods is invoked. If the program * requires no propagation then utilize this method. This method can be invoked between successive calls of SetOutputCube so that some cube will have labels propagated while others will not.

Parameters
propFlag indicating if labels are be propagated to output cubes.

Definition at line 652 of file Process.cpp.

References Isis::Process::p_propagateLabels.

◆ PropagateLabels() [2/2]

void Isis::Process::PropagateLabels ( const QString & cube)
inherited

This method allows the programmer to propagate labels from a specific secondary cube.

Parameters
cubeIString containing the name of the cube containing the labels to propagate.

Definition at line 664 of file Process.cpp.

References Isis::PvlObject::findObject(), and Isis::Process::OutputCubes.

◆ PropagateOriginalLabel()

void Isis::Process::PropagateOriginalLabel ( const bool prop)
inherited

This method allows the programmer to propagate original labels to the output cube (default is true)

Parameters
propFlag indicating if original labels is to be propagated to output cubes.

Definition at line 767 of file Process.cpp.

References Isis::Process::p_propagateOriginalLabel.

◆ PropagatePolygons()

void Isis::Process::PropagatePolygons ( const bool prop)
inherited

This method allows the programmer to propagate input blobs to the output cube (default is true)

Parameters
propFlag indicating if input blobs are to be propagated to output cubes.

Definition at line 744 of file Process.cpp.

References Isis::Process::p_propagatePolygons.

◆ PropagateTables() [1/2]

void Isis::Process::PropagateTables ( const bool prop)
inherited

This method allows the programmer to propagate input tables to the output cube (default is true)

Parameters
propFlag indicating if input tables are to be propagated to output cubes.

Definition at line 693 of file Process.cpp.

References Isis::Process::p_propagateTables.

◆ PropagateTables() [2/2]

void Isis::Process::PropagateTables ( const QString & fromName,
const QList< QString > & tableNames = QList<QString>() )
inherited

Propagate the tables from the cube with the given filename to the output cube.

This is done at the time this method is called, not during normal processing. The names of the tables to propagate can be provided through the second paramter, by specifing a list of table names. Not providing any list (or providing an empty list) will propagate all tables.

Parameters
fromNameQString of the name of the cube containing the tables to propagate.
tableNamesList of QStrings of the names of the tables to propagate; default is empty, which indicates that all tables will be propagated.
History
2016-11-30 Ian Humphrey - Added tableNames parameter so that only specified tables will be propagated when calling this method. Note that a default of an empty QList is used to propagate all tables. References #4433.

Definition at line 714 of file Process.cpp.

References Isis::Cube::close(), Isis::Cube::label(), Isis::PvlObject::object(), Isis::Cube::open(), Isis::Process::OutputCubes, and Isis::Cube::read().

◆ reorder()

void Isis::ProcessExportPds4::reorder ( )

This method reorders the existing m_domDoc to follow PDS4 standards and fixes time formatting if needed.

Definition at line 284 of file ProcessExportPds4.cpp.

References getElement(), m_domDoc, and Isis::PvlToXmlTranslationManager::resetElementValue().

◆ setCanGenerateChecksum()

void Isis::ProcessExport::setCanGenerateChecksum ( bool flag)
inherited

@description Set m_canGenerateChecksum which determines if we can generate a MD5 checksum on the image data.

Parameters
flagboolean to generate the checksum or not

Definition at line 673 of file ProcessExport.cpp.

References Isis::ProcessExport::m_canGenerateChecksum.

◆ setFormat()

void Isis::ProcessExport::setFormat ( ExportFormat format)
inlineinherited

Sets the storage order of the output file.

Definition at line 170 of file ProcessExport.h.

References Isis::ProcessExport::p_format.

Referenced by Isis::ProcessExport::ProcessExport(), and Isis::ProcessExportPds::StandardPdsLabel().

◆ setImageType()

void Isis::ProcessExportPds4::setImageType ( ImageType imageType)

Create a standard PDS4 image label from the input cube.

Returns
QDomDocument The output PDS4 label.

Definition at line 94 of file ProcessExportPds4.cpp.

References m_imageType.

◆ SetInputCube() [1/3]

Isis::Cube * Isis::Process::SetInputCube ( const QString & fname,
const Isis::CubeAttributeInput & att,
int requirements = 0 )
virtualinherited

Opens an input cube specified by the programmer and verifies requirements are met.

Parameters
fnameProgrammer specified work file. For example, "myfile.cub".
attThe cube attributes to use when opening the input cube.
requirementsRequirements to check that the input cube meets. See CheckRequirements().
Returns
Cube*
Exceptions
Isis::iException::Message

Reimplemented in Isis::ProcessByBrick, Isis::ProcessByBrick, and Isis::ProcessMosaic.

Definition at line 68 of file Process.cpp.

References Isis::Process::CheckRequirements(), Isis::Cube::open(), and Isis::Cube::setVirtualBands().

◆ SetInputCube() [2/3]

Isis::Cube * Isis::Process::SetInputCube ( const QString & parameter,
const int requirements = 0 )
virtualinherited

Opens an input cube specified by the user and verifies requirements are met.

Returns
Cube*
Parameters
parameterUser parameter to obtain file to open. Typically, the value is "FROM". For example, the user can specify on the command line FROM=myfile.cub and this method will attempt to open the cube "myfile.cub" if the parameter was set to "FROM".
requirementsRequirements to check that the input cube meets. See CheckRequirements().
Exceptions
Isis::iException::Message

Reimplemented in Isis::ProcessByBrick, Isis::ProcessByLine, Isis::ProcessBySpectra, Isis::ProcessMosaic, Isis::ProcessByBrick, and Isis::ProcessBySample.

Definition at line 139 of file Process.cpp.

References Isis::Application::GetUserInterface(), and Isis::Process::SetInputCube().

Referenced by Isis::JigsawRunWidget::on_JigsawAcceptButton_clicked(), Isis::FileTool::saveAsEnlargedCube(), Isis::ProcessByLine::SetInputCube(), Isis::ProcessBySample::SetInputCube(), Isis::ProcessByBrick::SetInputCube(), Isis::ProcessMosaic::SetInputCube(), Isis::Process::SetInputCube(), Isis::ProcessByLine::SetInputCube(), Isis::ProcessMosaic::SetInputCube(), Isis::ProcessByBrick::SetInputCube(), Isis::ProcessBySample::SetInputCube(), and Isis::ProcessGroundPolygons::SetStatCubes().

◆ SetInputCube() [3/3]

void Isis::Process::SetInputCube ( Isis::Cube * inCube,
int requirements = 0 )
virtualinherited

Set the InputCube vector to an opened Cube which was dynamically allocated.

This is used if there already exists a valid opened cube

Author
Sharmila Prasad (5/7/2011)
Parameters
inCube- Pointer to input Cube
requirementsRequirements to check that the input cube meets. See CheckRequirements().

Reimplemented in Isis::ProcessByBrick, and Isis::ProcessMosaic.

Definition at line 110 of file Process.cpp.

References Isis::Process::CheckRequirements(), Isis::Cube::isOpen(), and Isis::IException::User.

◆ SetInputRange() [1/6]

void Isis::ProcessExport::SetInputRange ( )
inherited

Set input pixel range from user.

This method performs the same function as SetInputRange(min,max) and SetInputRange(min,mid,max). However, the information for min/mid/max is obtained from the user via the command line. Therefore you must include the following parameter group in your application XML file:

<group name="Stretch Options">
<parameter name="STRETCH">
<type>string</type>
<default>
<item>LINEAR</item>
</default>
<brief>Type of stretch</brief>
<description>
This parameter is used to select one of three ways to stretch
(or map) output pixels. They are LINEAR, PIECEWISE, or MANUAL.
</description>
<list>
<option value="LINEAR">
<brief> Linear stretch </brief>
<description>
A minimum and maximum are automatically computed based on
the statistics of the selected band. A histogram of the
band is used to pick the minimum at 0.5% of the data and
the maximum at 99.5% of the data. Input pixels less than
or equal to the minimum are stretched to black while
pixels greater than the or equal to the maximum are
stretched to white. A linear mapping occurs between the
minimum and maximum.
</description>
<inclusions>
<item>MINPERCENT</item>
<item>MAXPERCENT</item>
</inclusions>
<exclusions>
<item>MINIMUM</item>
<item>MAXIMUM</item>
</exclusions>
</option>
<option value="PIECEWISE">
<brief> Piecewise-linear stretch </brief>
<description>
This option is similar to the LINEAR option. A minimum and
maximum are automatically computed. Additionally, the
median is computed and it is mapped to the middle gray
value (halfway between white and black). Therefore, it is
a piecewise-linear stretch with input pixels mapped
linearly between either 1) the minimum/median or 2) the
median/maximum. This option is useful for contrast
stretching cubes with skewed histograms to ensure a
balanced contrast.
</description>
<inclusions>
<item>MINPERCENT</item>
<item>MAXPERCENT</item>
</inclusions>
<exclusions>
<item>MINIMUM</item>
<item>MAXIMUM</item>
</exclusions>
</option>
<option value="MANUAL">
<brief> Manual stretch </brief>
<description>
This option allows you to pick your own stretch. You must
enter a value for MINIMUM and MAXIMUM
</description>
<inclusions>
<item>MINIMUM</item>
<item>MAXIMUM</item>
</inclusions>
<exclusions>
<item>MINPERCENT</item>
<item>MAXPERCENT</item>
</exclusions>
</option>
</list>
</parameter>
<parameter name="MINIMUM">
<type>double</type>
<brief>Minimum pixel value</brief>
<description>
The minimum input pixel value which will be mapped to black.
</description>
<lessThan>
<item>MAXIMUM</item>
</lessThan>
</parameter>
<parameter name="MAXIMUM">
<type>double</type>
<brief>Maximum pixel value</brief>
<description>
The maximum input pixel value which will be mapped to white.
</description>
<greaterThan>
<item>MINIMUM</item>
</greaterThan>
</parameter>
<parameter name="MINPERCENT">
<type>double</type>
<brief>Minimum Percent</brief>
<description>
The percentage of data in the histogram used to compute
the minimum pixel value in the stretch.
</description>
<default><item>0.5</item></default>
<lessThan>
<item>MAXPERCENT</item>
</lessThan>
</parameter>
<parameter name="MAXPERCENT">
<type>double</type>
<brief>Maximum Percent</brief>
<description>
The percentage of data in the histogram used to compute
the maximum pixel value in the stretch.
</description>
<default><item>99.5</item></default>
<greaterThan>
<item>MINPERCENT</item>
</greaterThan>
</parameter>
</group>

Definition at line 359 of file ProcessExport.cpp.

References Isis::Application::GetUserInterface(), and Isis::ProcessExport::SetInputRange().

Referenced by Isis::ProcessExport::SetInputRange(), Isis::ProcessExport::SetInputRange(), and Isis::ProcessExport::SetInputRange().

◆ SetInputRange() [2/6]

void Isis::ProcessExport::SetInputRange ( const double minimum,
const double maximum )
inherited

Set input pixel range from to a linear stretch.

This method allows the programmer to define what range of input pixels in the input cube get mapped to the output range in the Buffer. By default the output range is 0.0 to 1.0 (can be overridden using the SetOutputRange method). This version of SetInputRange allows the programmer to perform a simple linear stretch. That is, "minimum:0.0 maximum:1.0" or minimum is mapped to 0.0, maximum is mapped to 1.0 everything inbetween is mapped linearly (e.g., (minimum+maximum)/2.0:0.5). Also, everything less than the minimum is mapped to 0.0 and everything more than the maximum is mapped to 1.0. If you are uncertain about how stretches operate see the Stretch object. If the input range is never set, no stretch will occur.

Parameters
minimumMinimum pixel value in the input cube to be mapped to the minimum value in the Buffer
maximumMaximum pixel value in the input cube to be mapped to the maximum value in the Buffer
Exceptions
Isis::iException::Message

Definition at line 93 of file ProcessExport.cpp.

References Isis::ProcessExport::SetInputRange().

◆ SetInputRange() [3/6]

void Isis::ProcessExport::SetInputRange ( const double minimum,
const double maximum,
const int index )
inherited

Set input pixel range from to a linear stretch.

This method allows the programmer to define what range of input pixels in the input cube get mapped to the output range in the Buffer. By default the output range is 0.0 to 1.0 (can be overridden using the SetOutputRange method). This version of SetInputRange allows the programmer to perform a simple linear stretch. That is, "minimum:0.0 maximum:1.0" or minimum is mapped to 0.0, maximum is mapped to 1.0 everything inbetween is mapped linearly (e.g., (minimum+maximum)/2.0:0.5). Also, everything less than the minimum is mapped to 0.0 and everything more than the maximum is mapped to 1.0. If you are uncertain about how stretches operate see the Stretch object. If the input range is never set, no stretch will occur.

Parameters
minimumMinimum pixel value in the input cube to be mapped to the minimum value in the Buffer
maximumMaximum pixel value in the input cube to be mapped to the maximum value in the Buffer
indexThe index of the channel you are setting
Exceptions
Isis::iException::Message

Definition at line 122 of file ProcessExport.cpp.

References Isis::ProcessExport::SetInputRange().

◆ SetInputRange() [4/6]

void Isis::ProcessExport::SetInputRange ( const double minimum,
const double middle,
const double maximum )
inherited

Set input pixel range from to a piecewise linear stretch.

This method allows the programmer to define what range of input pixels in the input cube get mapped to the output range in the Buffer. By default the output range is 0.0 to 1.0 (can be overridden using the SetOutputRange method). This version of SetInputRange allows the programmer to perform a piecewise linear stretch. That is,"minimum:0.0 middle:0.5 maximum:1.0". The pixels from the input cube between minimum and middle are mapped to 0.0 and 0.5 linearly, while pixels between middle and maximum are mapped to 0.5 and 1.0 linearly. Those outside the range of minimum and maximum are mapped to 0.0 and 1.0 respectively. If you are uncertain about how stretches operate see the Stretch object. If the input range is never set, no stretch will occur.

Parameters
minimumMinimum pixel value in the input cube to be mapped to the minimum value in the Buffer
middleMiddle pixel value in the input cube to be mapped to the (minimum+maximum)/2.0 value in the Buffer
maximumMaximum pixel value in the input cube to be mapped to the maximum value in the Buffer
Exceptions
Isis::IException::Message

Definition at line 153 of file ProcessExport.cpp.

References Isis::Process::InputCubes, Isis::ProcessExport::p_inputMaximum, Isis::ProcessExport::p_inputMiddle, Isis::ProcessExport::p_inputMinimum, and Isis::IException::Programmer.

◆ SetInputRange() [5/6]

void Isis::ProcessExport::SetInputRange ( const double minimum,
const double middle,
const double maximum,
const int index )
inherited

Set input pixel range from to a piecewise linear stretch.

This method allows the programmer to define what range of input pixels in the input cube get mapped to the output range in the Buffer. By default the output range is 0.0 to 1.0 (can be overridden using the SetOutputRange method). This version of SetInputRange allows the programmer to perform a piecewise linear stretch. That is,"minimum:0.0 middle:0.5 maximum:1.0". The pixels from the input cube between minimum and middle are mapped to 0.0 and 0.5 linearly, while pixels between middle and maximum are mapped to 0.5 and 1.0 linearly. Those outside the range of minimum and maximum are mapped to 0.0 and 1.0 respectively. If you are uncertain about how stretches operate see the Stretch object. If the input range is never set, no stretch will occur.

Parameters
minimumMinimum pixel value in the input cube to be mapped to the minimum value in the Buffer
middleMiddle pixel value in the input cube to be mapped to the (minimum+maximum)/2.0 value in the Buffer
maximumMaximum pixel value in the input cube to be mapped to the maximum value in the Buffer
indexThe index of the channel you are setting
Exceptions
Isis::iException::Message

Definition at line 201 of file ProcessExport.cpp.

References Isis::Process::InputCubes, Isis::ProcessExport::p_inputMaximum, Isis::ProcessExport::p_inputMiddle, Isis::ProcessExport::p_inputMinimum, and Isis::IException::Programmer.

◆ SetInputRange() [6/6]

void Isis::ProcessExport::SetInputRange ( UserInterface & ui)
inherited

Definition at line 363 of file ProcessExport.cpp.

◆ setLogicalId()

void Isis::ProcessExportPds4::setLogicalId ( QString lid)

Allows mission specific programs to set logical_identifier required for PDS4 labels.

This value is added to the xml file by the identificationArea() method.

The input value will be converted to all-lowercase if not already in line with PDS4 requirements.

The input string should be colon separated string with 6 identifiers:

  1. urn
  2. space_agency (ususally nasa)
  3. archiving_organization (usually pds)
  4. bundle_id
  5. collection_id
  6. product_id

Example: urn:esa:psa:em16_tgo_frd:data_raw:frd_raw_sc_d_20150625T133700-20150625T135700

Author
2018-05-21 Jeannie Backer
Parameters
lidThe logical identifier value required for PDS4 compliant labels.

Definition at line 407 of file ProcessExportPds4.cpp.

References m_lid.

◆ SetOutputCube() [1/3]

Isis::Cube * Isis::Process::SetOutputCube ( const QString & fname,
const Isis::CubeAttributeOutput & att,
const int ns,
const int nl,
const int nb = 1 )
virtualinherited

◆ SetOutputCube() [2/3]

Isis::Cube * Isis::Process::SetOutputCube ( const QString & parameter)
virtualinherited

Allocates a user-specified output cube whose size matches the first input cube.

Returns
Cube*
Parameters
parameterUser specified output file. For example, "TO" is a popular user parameter. If the user specified TO=output.cub, then this routine would allocate the file output.cub with size specified by the first opened input cube. The output pixel type will be propagated from the first loaded input cube or will use the value in the application XML file for pixelType.
Exceptions
Isis::iException::Message

Reimplemented in Isis::ProcessMapMosaic, Isis::ProcessImport, and Isis::ProcessMosaic.

Definition at line 163 of file Process.cpp.

References Isis::Process::InputCubes, Isis::IException::Programmer, and Isis::Process::SetOutputCube().

Referenced by Isis::ProcessByBrick::SetOutputCube(), Isis::ProcessImport::SetOutputCube(), Isis::Process::SetOutputCube(), Isis::ProcessImport::SetOutputCube(), Isis::Process::SetOutputCube(), Isis::ProcessImport::SetOutputCube(), Isis::Process::SetOutputCubeStretch(), Isis::ProcessPolygons::SetStatCubes(), and Isis::ProcessGroundPolygons::SetStatCubes().

◆ SetOutputCube() [3/3]

Isis::Cube * Isis::Process::SetOutputCube ( const QString & parameter,
const int ns,
const int nl,
const int nb = 1 )
virtualinherited

Allocates a user specified output cube whose size is specified by the programmer.

Returns
Cube*
Parameters
parameterUser specified output file. For example, "TO" is a popular user parameter. If the user specified TO=output.cub, then this routine would allocate the file output.cub with size specified by the first opened input cube. The output pixel type will be propagated from the first loaded input cube or will use the value in the application XML file for pixelType.
nsNumber of samples to allocate
nlNumber of lines to allocate
nbNumber of bands to allocate
Exceptions
Isis::iException::Message

Definition at line 233 of file Process.cpp.

References Isis::Application::GetUserInterface(), Isis::IException::Programmer, and Isis::Process::SetOutputCube().

◆ SetOutputCubeStretch() [1/2]

Isis::Cube * Isis::Process::SetOutputCubeStretch ( const QString & parameter,
const int ns,
const int nl,
const int nb = 1,
UserInterface * ui = nullptr )
virtualinherited

Allocates a user specified output cube whose size is specified by the programmer.

Returns
Cube*
Parameters
parameterUser specified output file. For example, "TO" is a popular user parameter. If the user specified TO=output.cub, then this routine would allocate the file output.cub with size specified by the first opened input cube. The output pixel type will be propagated from the first loaded input cube or will use the value in the application XML file for pixelType.
nsNumber of samples to allocate
nlNumber of lines to allocate
nbNumber of bands to allocate
uiA user interface used to get the attributes needed. If null, the user interface will be obtained from the application.
Exceptions
Isis::iException::Message

Definition at line 275 of file Process.cpp.

References Isis::Application::GetUserInterface(), Isis::IException::Programmer, and Isis::Process::SetOutputCube().

◆ SetOutputCubeStretch() [2/2]

Isis::Cube * Isis::Process::SetOutputCubeStretch ( const QString & parameter,
UserInterface * ui = nullptr )
virtualinherited

Allocates a user-specified output cube whose size matches the first input cube.

Returns
Cube*
Parameters
parameterUser specified output file. For example, "TO" is a popular user parameter. If the user specified TO=output.cub, then this routine would allocate the file output.cub with size specified by the first opened input cube. The output pixel type will be propagated from the first loaded input cube or will use the value in the application XML file for pixelType.
uiA user interface used to get the attributes needed for SetOutputCube.
Exceptions
Isis::iException::Message

Definition at line 196 of file Process.cpp.

References Isis::Process::InputCubes, Isis::IException::Programmer, and Isis::Process::SetOutputCubeStretch().

Referenced by Isis::Process::SetOutputCubeStretch().

◆ SetOutputEndian()

void Isis::ProcessExport::SetOutputEndian ( enum ByteOrder byteOrderIn)
inherited

Set byte endianness of the output cube.

This method allows the programmer to specify whether the first byte of data output from the ProcessExport will be the most significant byte or the least significant byte. If the user does not explicitly set the endianness, it will default to that of the current system architecture

Parameters
byteOrderInenumeration of the endianness (MSB or LSB)

Definition at line 649 of file ProcessExport.cpp.

References Isis::ProcessExport::p_endianSwap, and Isis::ProcessExport::p_endianType.

Referenced by Isis::ProcessExport::ProcessExport().

◆ SetOutputHis()

void Isis::ProcessExport::SetOutputHis ( const double value)
inherited

Set output special pixel value for HIS.

Sets the value for output special pixel HISs. HIS pixels values from the input cube will be set to this value. Be default this value will be set to the maximum out value set with SetOutputRange

Parameters
valueThe output pixel value for all HIS pixels

Definition at line 521 of file ProcessExport.cpp.

References Isis::ProcessExport::p_His, and Isis::ProcessExport::p_His_Set.

◆ SetOutputHrs()

void Isis::ProcessExport::SetOutputHrs ( const double value)
inherited

Set output special pixel value for HRS.

Sets the value for output special pixel HRSs. HRS pixels values from the input cube will be set to this value. Be default this value will be set to the maximum out value set with SetOutputRange

Parameters
valueThe output pixel value for all HRS pixels

Definition at line 536 of file ProcessExport.cpp.

References Isis::ProcessExport::p_Hrs, and Isis::ProcessExport::p_Hrs_Set.

◆ SetOutputLis()

void Isis::ProcessExport::SetOutputLis ( const double value)
inherited

Set output special pixel value for LIS.

Sets the value for output special pixel LISs. LIS pixels values from the input cube will be set to this value. Be default this value will be set to the minimum out value set with SetOutputRange

Parameters
valueThe output pixel value for all LIS pixels

Definition at line 491 of file ProcessExport.cpp.

References Isis::ProcessExport::p_Lis, and Isis::ProcessExport::p_Lis_Set.

◆ SetOutputLrs()

void Isis::ProcessExport::SetOutputLrs ( const double value)
inherited

Set output special pixel value for LRS.

Sets the value for output special pixel LRSs. LRS8 pixels values from the input cube will be set to this value. Be default this value will be set to the minimum out value set with SetOutputRange

Parameters
valueThe output pixel value for all LRS pixels

Definition at line 506 of file ProcessExport.cpp.

References Isis::ProcessExport::p_Lrs, and Isis::ProcessExport::p_Lrs_Set.

◆ SetOutputNull()

void Isis::ProcessExport::SetOutputNull ( const double value)
inherited

Set output special pixel value for NULL.

Sets the value for output special pixel NULLs. NULL pixels values from the input cube will be set to this value. Be default this value will be set to the minimum out value set with SetOutputRange

Parameters
valueThe output pixel value for all NULL pixels

Definition at line 476 of file ProcessExport.cpp.

References Isis::ProcessExport::p_Null, and Isis::ProcessExport::p_Null_Set.

◆ SetOutputRange()

void Isis::ProcessExport::SetOutputRange ( const double minimum,
const double maximum )
inherited

Set output pixel range in Buffer.

This method allows the programmer to specify the acceptable range of values contained in the Buffer. If this method is never invoked, all pixel values received in the Buffer of the export function will be in the range of 0.0 to 1.0. However, this can be overridden, for example, to 0.0 and 255.0, by invoking this method.

Parameters
minimumDesired minimum pixel value in the Buffer
maximumDesired maximum pixel value in the Buffer
Exceptions
Isis::iException::Message

Definition at line 454 of file ProcessExport.cpp.

References Isis::ProcessExport::p_outputMaximum, Isis::ProcessExport::p_outputMiddle, Isis::ProcessExport::p_outputMinimum, and Isis::IException::Programmer.

Referenced by Isis::ProcessExport::SetOutputType().

◆ SetOutputType()

void Isis::ProcessExport::SetOutputType ( Isis::PixelType pixelIn)
inherited

Set output pixel bit type in Buffer.

This method specifies the type of pixel data that is going to be output. Essentially, it is a convenience method that will automatically calculate the necessary output range based on the minimum and maximum values of the bit type that is specified. Currently, the method only supported data types are Isis::UnsignedByte (Range of 0 to 255), Isis::SignedWord (Range of -32768 to 32767), Isis::UnsignedWord (Range of 0 to 65535), and Isis::Real (Range from the minimum floating-point value to the maximum floating-point value supported in C++; -FLT_MAX to FLT_MAX), since these are the only formats that can be output by ProcessExport. If neither this method nor the SetOutputRange method is invoked, all pixel values received in the Buffer of the export function will be in the range of 0.0 to 1.0.

NOTE: You must set the format type of the output data with SetFormat before calling this method. Otherwise, you will get an error.

Parameters
pixelInthis is an enumeration of the different pixel types. The only values that are recognized as valid are Isis::UnsignedByte, Isis::SignedWord, Isis::UnsignedWord, and Isis::Real.
Exceptions
Isis::iException::Message

Definition at line 608 of file ProcessExport.cpp.

References Isis::ProcessExport::JP2, Isis::ProcessExport::p_format, Isis::ProcessExport::p_pixelType, Isis::IException::Programmer, and Isis::ProcessExport::SetOutputRange().

Referenced by Isis::ProcessExport::ProcessExport().

◆ setPixelDescription()

void Isis::ProcessExportPds4::setPixelDescription ( QString description)

Sets the description string which describes the pixel vales in File_Area_Observational.

Parameters
descriptionDescription of pixel values to use.

Definition at line 793 of file ProcessExportPds4.cpp.

References m_pixelDescription.

◆ setSchemaLocation()

void Isis::ProcessExportPds4::setSchemaLocation ( QString schema)

Allows mission specific programs to use specified versions of dictionaries.

Author
2018-05-21 Jeannie Backer
Parameters
schemaThe string of schema to be set.

Definition at line 453 of file ProcessExportPds4.cpp.

References m_schemaLocation.

◆ setTitle()

void Isis::ProcessExportPds4::setTitle ( QString title)

Allows mission specific programs to set the title required for PDS4 labels.

This value is added to the xml file by the identificationArea() method.

Author
2019-03-01 Kristin Berry
Parameters
titleThe title value required for PDS4 compliant labels.

Definition at line 440 of file ProcessExportPds4.cpp.

References m_title.

◆ setVersionId()

void Isis::ProcessExportPds4::setVersionId ( QString versionId)

Allows mission specific programs to set version_id required for PDS4 labels.

This value is added to the xml file by the identificationArea() method.

The input string should be colon separated string with 6 identifiers:

Author
2019-03-01 Kristin Berry
Parameters
versiondIdThe version_id value required for PDS4 compliant labels.

Definition at line 425 of file ProcessExportPds4.cpp.

References m_versionId.

◆ StandardAllMapping()

void Isis::ProcessExportPds4::StandardAllMapping ( )

Create the standard keywords for the IMAGE_MAP_PROJECTION group in a PDS label.

Exceptions
IException::User"Unable to export projection [" + projName + "] to PDS4 product. " + "This projection is not supported in ISIS."

Definition at line 1164 of file ProcessExportPds4.cpp.

References addSchema(), Isis::PvlKeyword::clear(), Isis::ProjectionFactory::Create(), getElement(), Isis::Process::InputCubes, m_domDoc, Isis::PvlToXmlTranslationManager::resetElementValue(), Isis::toDouble(), Isis::toString(), Isis::PvlObject::Traverse, and Isis::IException::User.

Referenced by CreateImageLabel().

◆ standardBandBin()

void Isis::ProcessExportPds4::standardBandBin ( )
protected

Export bandbin group to sp:Spectral Characteristics.

Definition at line 540 of file ProcessExportPds4.cpp.

References addSchema(), Isis::Process::InputCubes, m_imageType, translateBandBinImage(), translateBandBinSpectrumBinSet(), and translateBandBinSpectrumUniform().

Referenced by CreateImageLabel().

◆ standardInstrument()

void Isis::ProcessExportPds4::standardInstrument ( )
protected

This method translates the information from the ISIS Instrument group to the PDS4 labels.

Definition at line 191 of file ProcessExportPds4.cpp.

References Isis::Process::InputCubes, m_domDoc, Isis::PvlToXmlTranslationManager::resetElementValue(), and Isis::IException::Unknown.

Referenced by CreateImageLabel().

◆ StandardPds4Label()

QDomDocument & Isis::ProcessExportPds4::StandardPds4Label ( )

Create a standard PDS4 image label from the input cube.

Returns
QDomDocument The output PDS4 label.

Definition at line 82 of file ProcessExportPds4.cpp.

References CreateImageLabel(), m_domDoc, and translateUnits().

◆ StartProcess() [1/5]

void Isis::ProcessExport::StartProcess ( std::ofstream & fout)
virtual

Write an entire cube to an output file stream.

Just as with the other invocation of the StartProcess method, this will process an input cube buffer by buffer. Unlike the other invocation, this method takes care of writing the input data to an output file stream specified by the user instead of relying on an external function.

Parameters
&foutAn open stream to which the pixel data will be written. After calling this method once, the stream will contain all of the pixel data from the input cube.

Reimplemented from Isis::ProcessExport.

Definition at line 128 of file ProcessExport.cpp.

◆ StartProcess() [2/5]

void Isis::ProcessExportPds4::StartProcess ( std::ofstream & fout)
virtual

This method fills the image data of the PDS4 file using the parent class ProcessExport::StartProcess.

Parameters
[out]foutOutput file stream to be filled with the PDS4 data.

Reimplemented from Isis::ProcessExport.

Definition at line 1078 of file ProcessExportPds4.cpp.

References Isis::ProcessExport::StartProcess().

Referenced by WritePds4().

◆ StartProcess() [3/5]

virtual void Isis::Process::StartProcess ( void funct())
inlinevirtualinherited

In the base class, this method will invoked a user-specified function exactly one time.

In derived classes such as ProcessByLine, the StartProcess will invoke a user-specified function for every line in a cube.

Parameters
funct()Name of your processing function

Definition at line 213 of file Process.h.

◆ StartProcess() [4/5]

void Isis::ProcessExport::StartProcess ( void functIsis::Buffer &in)
virtual

This method invokes the process operation over a single input cube.

In the cases of BSQ and BIL this is a process by line. In the case of BIP, this is a process by band. A single buffer of input data will be padd to the buffer processing function. Note the data will be stretched based on the invocations of the SetInputRange and SetpOutputRange methods.

Parameters
funct(Isis::Buffer &b) Name of your buffer processing function. The buffer in will contain stretched input cube pixels for an entire buffer. These pixels must be written to the foreign output file (e.g, jpg, tif, etc).

Reimplemented from Isis::ProcessExport.

Definition at line 126 of file ProcessExport.cpp.

◆ StartProcess() [5/5]

virtual void Isis::ProcessExport::StartProcess ( void functstd::vector< Isis::Buffer * > &in)
virtual

Reimplemented from Isis::ProcessExport.

◆ translateBandBinImage()

void Isis::ProcessExportPds4::translateBandBinImage ( Pvl & inputLabel)
protected

Export BandBin group for 2D or 3D Image format.

Definition at line 572 of file ProcessExportPds4.cpp.

References m_domDoc.

Referenced by standardBandBin().

◆ translateBandBinSpectrumBinSet()

void Isis::ProcessExportPds4::translateBandBinSpectrumBinSet ( Pvl & inputLabel)
protected

Export BandBin group for non-uniformly spaced 3D Spectral data format.

Definition at line 726 of file ProcessExportPds4.cpp.

References getElement(), m_domDoc, Isis::IException::Programmer, Isis::PvlToXmlTranslationManager::setElementValue(), and Isis::PvlKeyword::size().

Referenced by standardBandBin().

◆ translateBandBinSpectrumUniform()

void Isis::ProcessExportPds4::translateBandBinSpectrumUniform ( Pvl & inputLabel)
protected

Export BandBin group for uniformly spaced 3D Spectral data format.

Definition at line 584 of file ProcessExportPds4.cpp.

References getElement(), m_domDoc, Isis::IException::Programmer, Isis::PvlToXmlTranslationManager::setElementValue(), Isis::PvlKeyword::size(), Isis::toString(), and Isis::PvlKeyword::unit().

Referenced by standardBandBin().

◆ translateChildUnits()

void Isis::ProcessExportPds4::translateChildUnits ( QDomElement parent,
QMap< QString, QString > transMap )
staticprotected

Recursive method that will translate the "unit" attribute of any child elements of a given element.

Returns void if the given element has no children.

Parameters
parentThe element whose children's units will be translated. This method will be recursively called on all child elements.
transMapThe translation map with lowercase ISIS units as keys and PDS4 units as values.
See also
ProcessExportPds4::translateUnits

Definition at line 1545 of file ProcessExportPds4.cpp.

References translateChildUnits(), and Isis::IException::Unknown.

Referenced by translateChildUnits(), and translateUnits().

◆ translateUnits()

void Isis::ProcessExportPds4::translateUnits ( QDomDocument & label,
QString transMapFile = "$ISISROOT/appdata/translations/pds4ExportUnits.pvl" )
static

This function will go through an XML document and attempt to convert all "units" attributes to the appropriate PDS4 units format.

This method uses a pvl config file to determine what the proper PDS4 format is and what potential input formats are. The file is converted to a map which is then used to convert all of the input units. See $ISISROOT/appdata/translations/pds4ExportUnits.pvl for more information on this file.

This method is automatically called in StandardPds4Label(), but may need to be called again if the label is changed afterwards.

Parameters
[in,out]labelA reference to the label that the units will be translated in.
transMapFileThe path to the config file that will be used to determine unit translations.

Definition at line 1464 of file ProcessExportPds4.cpp.

References createUnitMap(), Isis::IException::Io, Isis::Pvl::read(), translateChildUnits(), and Isis::IException::Unknown.

Referenced by StandardPds4Label().

◆ WriteHistory()

void Isis::Process::WriteHistory ( Cube & cube)
inherited

◆ WritePds4()

void Isis::ProcessExportPds4::WritePds4 ( QString outFile)

This method write out the labels and image data to the specified output file.

Creates an IMG and XML file.

Parameters
outFileQString of the name of the output image file. Will create an XML and an IMG file with the output file name.

Definition at line 1110 of file ProcessExportPds4.cpp.

References Isis::Process::EndProcess(), m_domDoc, OutputLabel(), Isis::PvlToXmlTranslationManager::setElementValue(), and StartProcess().

Member Data Documentation

◆ InputCubes

std::vector<Isis::Cube *> Isis::Process::InputCubes
protectedinherited

A vector of pointers to opened Cube objects.

The pointers are established in the SetInputCube/SetInputWorkCube methods.

Definition at line 185 of file Process.h.

Referenced by Isis::ProcessMosaic::AddBandBinGroup(), Isis::ProcessMosaic::BandComparison(), Isis::ProcessMosaic::BandPriorityWithNoTracking(), Isis::Process::CalculateStatistics(), Isis::Process::CheckRequirements(), Isis::Process::ClearInputCubes(), CreateImageLabel(), Isis::ProcessExport::CreateWorldFile(), displaySettings(), Isis::ProcessExportPds::ExportTable(), fileAreaObservational(), Isis::ProcessExportPds::FixedJP2ImageRoot(), Isis::ProcessMosaic::GetBandIndex(), Isis::ProcessExport::GetBuffersBIL(), Isis::ProcessExport::GetBuffersBIP(), Isis::ProcessExport::GetBuffersBSQ(), identificationArea(), Isis::ProcessExport::InitProcess(), Isis::ProcessExportPds::LineBytes(), Isis::ProcessMosaic::MatchBandBinGroup(), Isis::ProcessMosaic::MatchDEMShapeModel(), Isis::ProcessExportPds::OutputLabel(), Isis::ProcessByBrick::PrepProcessCube(), Isis::ProcessByBrick::PrepProcessCubeInPlace(), Isis::ProcessByBrick::PrepProcessCubes(), Isis::ProcessByBrick::ProcessCube(), Isis::ProcessByBrick::ProcessCubes(), Isis::ProcessRubberSheet::processPatchTransform(), Isis::ProcessByBrick::SetInputBrickSize(), Isis::ProcessByBrick::SetInputBrickSize(), Isis::ProcessMosaic::SetInputCube(), Isis::ProcessMosaic::SetInputCube(), Isis::ProcessExport::SetInputRange(), Isis::ProcessExport::SetInputRange(), Isis::ProcessByBrick::SetOutputCube(), Isis::Process::SetOutputCube(), Isis::Process::SetOutputCube(), Isis::Process::SetOutputCubeStretch(), Isis::ProcessGroundPolygons::SetStatCubes(), StandardAllMapping(), Isis::ProcessExportPds::StandardAllMapping(), standardBandBin(), Isis::ProcessExportPds::StandardImageImage(), standardInstrument(), Isis::ProcessExportPds::StandardJP2Image(), Isis::ProcessMosaic::StartProcess(), Isis::ProcessMapMosaic::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessExport::StartProcess(), Isis::ProcessRubberSheet::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessExport::StartProcess(), Isis::ProcessByBoxcar::StartProcess(), Isis::ProcessByQuickFilter::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessExportPds::StreamJP2ImageRoot(), Isis::ProcessByBrick::VerifyCubes(), and Isis::Process::WriteHistory().

◆ m_canGenerateChecksum

bool Isis::ProcessExport::m_canGenerateChecksum
protectedinherited

◆ m_cryptographicHash

QCryptographicHash* Isis::ProcessExport::m_cryptographicHash
protectedinherited

A cryptographic hash that will generate an MD5 checksum of the image data.

Definition at line 268 of file ProcessExport.h.

Referenced by Isis::ProcessExport::checksum(), Isis::ProcessExport::ProcessExport(), Isis::ProcessExport::StartProcess(), and Isis::ProcessExport::~ProcessExport().

◆ m_domDoc

◆ m_imageType

ImageType Isis::ProcessExportPds4::m_imageType
protected

Type of image data to be written.

Definition at line 134 of file ProcessExportPds4.h.

Referenced by fileAreaObservational(), ProcessExportPds4(), setImageType(), and standardBandBin().

◆ m_lid

QString Isis::ProcessExportPds4::m_lid
protected

QString with specified logical identifier.

Definition at line 131 of file ProcessExportPds4.h.

Referenced by identificationArea(), ProcessExportPds4(), and setLogicalId().

◆ m_ownedCubes

QSet<Isis::Cube *>* Isis::Process::m_ownedCubes
protectedinherited

A list of cubes owned by this instant.

These cubes will be deleted on finalization. Process will not take ownership of cubes allocated outside of Process. It is the caller's responsibility to delete such cubes.

Definition at line 199 of file Process.h.

Referenced by Isis::Process::ClearCubes(), Isis::Process::ClearInputCubes(), Isis::Process::ClearOutputCubes(), Isis::Process::Process(), and Isis::Process::~Process().

◆ m_pixelDescription

QString Isis::ProcessExportPds4::m_pixelDescription
protected

Description of pixel values.

Definition at line 135 of file ProcessExportPds4.h.

Referenced by fileAreaObservational(), and setPixelDescription().

◆ m_schemaLocation

QString Isis::ProcessExportPds4::m_schemaLocation
protected

QString with all schema locations required.

Definition at line 130 of file ProcessExportPds4.h.

Referenced by addSchema(), ProcessExportPds4(), and setSchemaLocation().

◆ m_title

QString Isis::ProcessExportPds4::m_title
protected

QString with specified title.

Definition at line 133 of file ProcessExportPds4.h.

Referenced by identificationArea(), ProcessExportPds4(), and setTitle().

◆ m_versionId

QString Isis::ProcessExportPds4::m_versionId
protected

QString with specified version id.

Definition at line 132 of file ProcessExportPds4.h.

Referenced by identificationArea(), ProcessExportPds4(), and setVersionId().

◆ OutputCubes

std::vector<Isis::Cube *> Isis::Process::OutputCubes
protectedinherited

A vector of pointers to allocated Cube objects.

The pointers are established in the SetOutputCube method.

Definition at line 191 of file Process.h.

Referenced by Isis::ProcessMosaic::AddBandBinGroup(), Isis::ProcessMosaic::AddDefaultBandBinGroup(), Isis::ProcessMosaic::BandComparison(), Isis::ProcessMosaic::BandPriorityWithNoTracking(), Isis::Process::ClearOutputCubes(), Isis::ProcessPolygons::FillPolygon(), Isis::ProcessImportPds::Finalize(), Isis::ProcessMosaic::GetBandIndex(), Isis::ProcessMosaic::GetOriginDefaultByPixelType(), Isis::ProcessMosaic::GetTrackStatus(), Isis::ProcessMosaic::MatchBandBinGroup(), Isis::ProcessMosaic::MatchDEMShapeModel(), Isis::ProcessByBrick::PrepProcessCube(), Isis::ProcessByBrick::PrepProcessCubeInPlace(), Isis::ProcessByBrick::PrepProcessCubes(), Isis::ProcessImport::ProcessBil(), Isis::ProcessImport::ProcessBip(), Isis::ProcessImport::ProcessBsq(), Isis::ProcessByBrick::ProcessCube(), Isis::ProcessByBrick::ProcessCubes(), Isis::ProcessImport::ProcessJp2(), Isis::ProcessRubberSheet::processPatchTransform(), Isis::Process::PropagateLabels(), Isis::Process::PropagateTables(), Isis::ProcessMosaic::ResetCountBands(), Isis::ProcessMapMosaic::RingsSetOutputCube(), Isis::ProcessByBrick::SetOutputBrickSize(), Isis::ProcessByBrick::SetOutputBrickSize(), Isis::ProcessMapMosaic::SetOutputCube(), Isis::ProcessPolygons::SetStatCubes(), Isis::ProcessGroundPolygons::SetStatCubes(), Isis::ProcessGroundPolygons::SetStatCubes(), Isis::ProcessImportPds::StartProcess(), Isis::ProcessMosaic::StartProcess(), Isis::ProcessMapMosaic::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessRubberSheet::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessByBoxcar::StartProcess(), Isis::ProcessByQuickFilter::StartProcess(), Isis::ProcessByBrick::StartProcess(), Isis::ProcessImportPds::TranslatePdsProjection(), and Isis::ProcessByBrick::VerifyCubes().

◆ p_bandStats

std::vector< std::vector< Isis::Statistics * > > Isis::Process::p_bandStats
protectedinherited

Holds the calculated statistics for each band separately of every input cubei after the CalculateStatistics method is called.

Definition at line 172 of file Process.h.

Referenced by Isis::Process::BandStatistics(), and Isis::Process::CalculateStatistics().

◆ p_cubeStats

std::vector< Isis::Statistics * > Isis::Process::p_cubeStats
protectedinherited

Holds the calculated statistics for every band together of every input cubei after the CalculateStatistics method is called.

Definition at line 179 of file Process.h.

Referenced by Isis::Process::CalculateStatistics(), and Isis::Process::CubeStatistics().

◆ p_endianSwap

EndianSwapper* Isis::ProcessExport::p_endianSwap
protectedinherited

◆ p_endianType

◆ p_format

◆ p_His

double Isis::ProcessExport::p_His
protectedinherited

The output value for pixels whose input DNs are High Instrument Saturation values.

Definition at line 252 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputHis(), and Isis::ProcessExport::SetOutputHis().

◆ p_His_Set

bool Isis::ProcessExport::p_His_Set
protectedinherited

Indicates whether p_His has been set (i.e.

if setHis() has been called).

Definition at line 263 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputHis(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputHis().

◆ p_Hrs

double Isis::ProcessExport::p_Hrs
protectedinherited

The output value for pixels whose input DNs are High Representation Saturation values.

Definition at line 254 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputHrs(), and Isis::ProcessExport::SetOutputHrs().

◆ p_Hrs_Set

bool Isis::ProcessExport::p_Hrs_Set
protectedinherited

Indicates whether p_Hrs has been set (i.e.

if setHrs() has been called).

Definition at line 265 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputHrs(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputHrs().

◆ p_inputMaximum

std::vector<double> Isis::ProcessExport::p_inputMaximum
protectedinherited

◆ p_inputMiddle

std::vector<double> Isis::ProcessExport::p_inputMiddle
protectedinherited

Middle pixel value in the input cube to be mapped to the (minimum+maximum)/2.0 value in the Buffer.

Definition at line 230 of file ProcessExport.h.

Referenced by Isis::ProcessExport::InitProcess(), Isis::ProcessExport::ProcessExport(), Isis::ProcessExport::SetInputRange(), and Isis::ProcessExport::SetInputRange().

◆ p_inputMinimum

std::vector<double> Isis::ProcessExport::p_inputMinimum
protectedinherited

◆ p_Lis

double Isis::ProcessExport::p_Lis
protectedinherited

The output value for pixels whose input DNs are Low Instrument Saturation values.

Definition at line 248 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputLis(), and Isis::ProcessExport::SetOutputLis().

◆ p_Lis_Set

bool Isis::ProcessExport::p_Lis_Set
protectedinherited

Indicates whether p_Lis has been set (i.e.

if setLis() has been called).

Definition at line 259 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputLis(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputLis().

◆ p_Lrs

double Isis::ProcessExport::p_Lrs
protectedinherited

The output value for pixels whose input DNs are Low Representation Saturation values.

Definition at line 250 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputLrs(), and Isis::ProcessExport::SetOutputLrs().

◆ p_Lrs_Set

bool Isis::ProcessExport::p_Lrs_Set
protectedinherited

Indicates whether p_Lrs has been set (i.e.

if setLrs() has been called).

Definition at line 261 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputLrs(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputLrs().

◆ p_Null

double Isis::ProcessExport::p_Null
protectedinherited

The output value for pixels whose input DNs are Null values.

Definition at line 247 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputNull(), and Isis::ProcessExport::SetOutputNull().

◆ p_Null_Set

bool Isis::ProcessExport::p_Null_Set
protectedinherited

Indicates whether p_Null has been set (i.e.

if setNull() has been called).

Definition at line 257 of file ProcessExport.h.

Referenced by Isis::ProcessExport::OutputNull(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputNull().

◆ p_outputMaximum

◆ p_outputMiddle

double Isis::ProcessExport::p_outputMiddle
protectedinherited

Middle pixel value (minimum+maximun)/2.0 in the Buffer.

Definition at line 223 of file ProcessExport.h.

Referenced by Isis::ProcessExport::InitProcess(), Isis::ProcessExport::ProcessExport(), and Isis::ProcessExport::SetOutputRange().

◆ p_outputMinimum

◆ p_pixelType

◆ p_progress

◆ p_propagateHistory

bool Isis::Process::p_propagateHistory
protectedinherited

Flag indicating if history is to be propagated to output cubes.

Definition at line 161 of file Process.h.

Referenced by Isis::Process::Process(), Isis::Process::PropagateHistory(), Isis::ProcessMapMosaic::StartProcess(), and Isis::Process::WriteHistory().

◆ p_propagateLabels

bool Isis::Process::p_propagateLabels
protectedinherited

Flag indicating if labels are be propagated to output cubes.

Definition at line 149 of file Process.h.

Referenced by Isis::Process::Process(), Isis::Process::PropagateLabels(), and Isis::Process::SetOutputCube().

◆ p_propagateOriginalLabel

bool Isis::Process::p_propagateOriginalLabel
protectedinherited

Flag indicating if original lable is to be propagated to output cubes.

Definition at line 165 of file Process.h.

Referenced by Isis::Process::Process(), Isis::Process::PropagateOriginalLabel(), and Isis::Process::SetOutputCube().

◆ p_propagatePolygons

bool Isis::Process::p_propagatePolygons
protectedinherited

Flag indicating if blobs are be propagated to output cubes.

Definition at line 157 of file Process.h.

Referenced by Isis::Process::Process(), Isis::Process::PropagatePolygons(), and Isis::Process::SetOutputCube().

◆ p_propagateTables

bool Isis::Process::p_propagateTables
protectedinherited

Flag indicating if tables are be propagated to output cubes.

Definition at line 153 of file Process.h.

Referenced by Isis::Process::Process(), Isis::Process::PropagateTables(), and Isis::Process::SetOutputCube().

◆ p_str

std::vector<Stretch *> Isis::ProcessExport::p_str
protectedinherited

Stretch object to ensure a reasonable range of pixel values in the output data.

Definition at line 243 of file ProcessExport.h.

Referenced by Isis::ProcessExport::InitProcess(), Isis::ProcessExport::StartProcess(), Isis::ProcessExport::StartProcess(), and Isis::ProcessExport::~ProcessExport().


The documentation for this class was generated from the following files: