OPERA  1.0
Open source echelle spectrograph reduction pipeline
operaEspadonsImage Class Reference

Basic operaEspadonsImage constructor. More...

#include <operaEspadonsImage.h>

Inheritance diagram for operaEspadonsImage:
Collaboration diagram for operaEspadonsImage:

Public Member Functions

 operaEspadonsImage ()
 operaEspadonsImage (string Filename, int mode=READWRITE)
 operaEspadonsImage (string Filename, edatatype Datatype, int mode=READWRITE)
 operaEspadonsImage (string Filename, unsigned Naxis1, unsigned Naxis2, DATASEC_t &datasec, edatatype Datatype=tushort, unsigned Compression=0)
 operaEspadonsImage (unsigned Naxis1, unsigned Naxis2, DATASEC_t &datasec, edatatype Datatype=tushort, unsigned Compression=0)
 ~operaEspadonsImage ()
 Destructor, frees image memory and closes FITS file.
unsigned short * operaEspadonsImageCloneDatasecUSHORT ()
 Clone a pixel datasec.
float * operaEspadonsImageCloneDatasec ()
 Clone a pixel datasec.
unsigned short getpixelUSHORT (unsigned x, unsigned y)
 get a pixel value at coordinates x,y.
float getpixel (unsigned x, unsigned y)
void setpixel (unsigned short value, unsigned x, unsigned y)
 get a pixel value at coordinates x,y.
void setpixel (float value, unsigned x, unsigned y)
void operaEspadonsImageCopyHeader (operaEspadonsImage *from)
 Copies all of the header information from image.
operaEspadonsImageoperaEspadonsImageClone (operaEspadonsImage &imageIn)
 Clone an espadons Image object.
operaFITSSubImagegetDatasecSubImage ()
 get the datasec subImage.
void operaFITSImageSetData (operaFITSSubImage &datasecSubImage)
 copy a subimage back in to an operaEspadonsImage datasec.
unsigned getnx ()
 get the DATASEC array length of dimension 1.
unsigned getny ()
 get the DATASEC array length of dimension 2.
unsigned getndpixels ()
 get the image array number of pixels.
unsigned long getsize ()
 Returns the image type (OBJECT, FLAT, ...).
imtype_t getimtype ()
 Returns the image type (OBJECT, FLAT, ...).
string getimtypestring ()
 Returns the image type (OBJECT, FLAT, ...) as a string.
detector_t getdetector ()
 Returns te detector type (EEV1, OLAPA, ...).
string getdetectorstring ()
 Returns te detector type (EEV1, OLAPA, ...) as a string.
amplifier_t getamplifier ()
 Returns te amplifier type (a, ab ...).
string getamplifierstring ()
 Returns te amplifier type (a, ab ...) as a string.
instrumentmode_t getmode ()
 Returns the mode (sp1, sp2, pol ...).
string getmodestring ()
 Returns the mode (sp1, sp2, pol ...) as a string.
speed_t getspeed ()
 Returns the speed (Fast, Slow, Normal ...).
string getspeedstring ()
 Returns the speed (Fast, Slow, Normal ...) as a string.
stokes_t getstokes ()
 Returns the stokes parameter (U, I, Vl ...).
string getstokesstring ()
 Returns the stokes parameter (U, I, Vl ...) as a string.
polarquad_t getpolarquad ()
 Returns the polar quad sequence number (1,2,3,4).
string getpolarquadstring ()
 Returns the polar quad sequence number (1,2,3,4) as a string.

Detailed Description

Basic operaEspadonsImage constructor.

operaEspadonsImage(unsigned Naxis1, unsigned Naxis2, edatatype Datatype=tushort, unsigned Compression=0)

operaEspadonsImage(string Filename, unsigned Naxis1, unsigned Naxis2, DATASEC_t &datasec, edatatype Datatype, unsigned Compression)

operaEspadonsImage(string Filename, int mode=READWRITE)

Constructor for readng a FITS file and creating the corresponding object.

Returns:
none

(string Filename, int mode)

Parameters:
Filename
mode- READWRITE or READONLY, defaults to READWRITE
Exceptions:
operaExceptionoperaErrorHeaderProblem
Returns:
none

a espadons Image object from a FITS file Constructor to create a espadons Image from a FITS file.

Parameters:
Filename
Datatype- convert image to this datatype
mode
Returns:
void

Constructor to create a new FITS file.

Parameters:
Filenameto create (file is deleted if it exists)
Naxis1- x dimension
Naxis2- y dimension
datasec- the datasec where the valid data pixels are
Datatypedefaults to tshort
Compression,defaultsto none
Exceptions:
operaExceptioncfitsio error code
Returns:
void

an in-memory espadons Image object Create an in-memory image of given dimensions.

Parameters:
Naxis1- x ccd dimension
Naxis2- y ccd dimension
datasecDATASEC_t - espadons image datasec
Datatypeoptional datatype defaults to tshort
Compressionoptional compression, defaults to none
Returns:
void
Parameters:
Filename
Exceptions:
operaExceptionoperaErrorHeaderProblem
Returns:
none

an in-memory espadons Image object Create an in-memory image of given dimensions.

Parameters:
Naxis1- x ccd dimension
Naxis2- y ccd dimension
Datatypeoptional datatype defaults to tshort
Compressionoptional compression, defaults to none
Returns:
void

Constructor & Destructor Documentation

operaEspadonsImage::operaEspadonsImage ( )
operaEspadonsImage::operaEspadonsImage ( string  Filename,
int  mode = READWRITE 
)

Here is the call graph for this function:

operaEspadonsImage::operaEspadonsImage ( string  Filename,
edatatype  Datatype,
int  mode = READWRITE 
)

Here is the call graph for this function:

operaEspadonsImage::operaEspadonsImage ( string  Filename,
unsigned  Naxis1,
unsigned  Naxis2,
DATASEC_t datasec,
edatatype  Datatype = tushort,
unsigned  Compression = 0 
)
operaEspadonsImage::operaEspadonsImage ( unsigned  Naxis1,
unsigned  Naxis2,
DATASEC_t datasec,
edatatype  Datatype = tushort,
unsigned  Compression = 0 
)
operaEspadonsImage::~operaEspadonsImage ( )

Destructor, frees image memory and closes FITS file.

~operaEspadonsImage()

Returns:
none

Member Function Documentation

amplifier_t operaEspadonsImage::getamplifier ( )

Returns te amplifier type (a, ab ...).

amplifier_t getamplifier()

Returns:
amplifier type
string operaEspadonsImage::getamplifierstring ( )

Returns te amplifier type (a, ab ...) as a string.

amplifier_t getamplifier()

Returns:
amplifier type
operaFITSSubImage * operaEspadonsImage::getDatasecSubImage ( )

get the datasec subImage.

operaFITSSubImage *getDatasecSubImage()

Returns:
subImage pointers
detector_t operaEspadonsImage::getdetector ( )

Returns te detector type (EEV1, OLAPA, ...).

detector_t getdetector()

Returns:
detector type
string operaEspadonsImage::getdetectorstring ( )

Returns te detector type (EEV1, OLAPA, ...) as a string.

string getdetectorstring()

Returns:
detector type

detector_t getdetector()

Returns:
detector type
imtype_t operaEspadonsImage::getimtype ( )

Returns the image type (OBJECT, FLAT, ...).

imtype_t getimtype()

Returns:
image type
string operaEspadonsImage::getimtypestring ( )

Returns the image type (OBJECT, FLAT, ...) as a string.

string getimtypestring()

Returns:
image type

imtype_t getimtypestring()

Returns:
image type
instrumentmode_t operaEspadonsImage::getmode ( )

Returns the mode (sp1, sp2, pol ...).

instrumentmode_t getmode()

Returns:
mode
string operaEspadonsImage::getmodestring ( )

Returns the mode (sp1, sp2, pol ...) as a string.

string getmodestring()

Returns:
mode
unsigned operaEspadonsImage::getndpixels ( )

get the image array number of pixels.

unsigned getndpixels()

Returns:
unsigned number of pixels
unsigned operaEspadonsImage::getnx ( )

get the DATASEC array length of dimension 1.

unsigned getnx()

Returns:
unsigned length of axis 1
unsigned operaEspadonsImage::getny ( )

get the DATASEC array length of dimension 2.

unsigned getny()

Returns:
unsigned length of axis 2
float operaEspadonsImage::getpixel ( unsigned  x,
unsigned  y 
) [inline]

Reimplemented from operaFITSImage.

unsigned short operaEspadonsImage::getpixelUSHORT ( unsigned  x,
unsigned  y 
) [inline]

get a pixel value at coordinates x,y.

getpixel(unsigned x, unsigned y)

Parameters:
x- the x coordinate
y- the y coordinate
Note:
This function does a shift left by 11 as the image width is known to be 2048 pixels
and a shift is faster than a multiply. If the espadons image width ever changes
this will have to be revisited.
Returns:
unsigned short

Reimplemented from operaFITSImage.

polarquad_t operaEspadonsImage::getpolarquad ( )

Returns the polar quad sequence number (1,2,3,4).

polarquad_t getpolarquad()

Returns:
polar sequence number
string operaEspadonsImage::getpolarquadstring ( )

Returns the polar quad sequence number (1,2,3,4) as a string.

string getpolarquadstring()

Returns:
polar sequence number
unsigned long operaEspadonsImage::getsize ( )

Returns the image type (OBJECT, FLAT, ...).

imtype_t getimtype()

Returns:
image type

unsigned long getsize() get the datasec size of an image.

Returns:
unsigned long sie of the image

Reimplemented from operaFITSImage.

speed_t operaEspadonsImage::getspeed ( )

Returns the speed (Fast, Slow, Normal ...).

speed_t getspeed()

Returns:
speed
string operaEspadonsImage::getspeedstring ( )

Returns the speed (Fast, Slow, Normal ...) as a string.

string getspeedstring()

Returns:
speed
stokes_t operaEspadonsImage::getstokes ( )

Returns the stokes parameter (U, I, Vl ...).

speed_t getstokes()

Returns:
stokes
string operaEspadonsImage::getstokesstring ( )

Returns the stokes parameter (U, I, Vl ...) as a string.

string getstokesstring()

Returns:
stokes
operaEspadonsImage * operaEspadonsImage::operaEspadonsImageClone ( operaEspadonsImage imageIn)

Clone an espadons Image object.

~operaEspadonsImage* operaEspadonsImage::operaEspadonsImageClone(operaEspadonsImage &imageIn)

Parameters:
imageIn- pointer to image to clone
Returns:
~operaEspadonsImage*

operaEspadonsImage* operaEspadonsImage::operaEspadonsImageClone(operaEspadonsImage &imageIn)

Parameters:
imageIn- pointer to image to clone
Returns:
operaEspadonsImage*

Here is the call graph for this function:

float * operaEspadonsImage::operaEspadonsImageCloneDatasec ( )

Clone a pixel datasec.

float* operaEspadonsImage::operaEspadonsImageCloneDatasec()

Returns:
pixels*
unsigned short * operaEspadonsImage::operaEspadonsImageCloneDatasecUSHORT ( )

Clone a pixel datasec.

unsigned short* operaEspadonsImage::operaEspadonsImageCloneDatasecUSHORT()

Returns:
pixels*
void operaEspadonsImage::operaEspadonsImageCopyHeader ( operaEspadonsImage from)

Copies all of the header information from image.

operaEspadonsImageCopyHeader(~operaEspadonsImage *from)

Parameters:
from
Exceptions:
operaExceptioncfitsio error code
Returns:
void

operaEspadonsImageCopyHeader(operaEspadonsImage *from)

Parameters:
from
Exceptions:
operaExceptioncfitsio error code
Returns:
void

Here is the call graph for this function:

void operaEspadonsImage::operaFITSImageSetData ( operaFITSSubImage datasecSubImage)

copy a subimage back in to an operaEspadonsImage datasec.

void operaEspadonsImage::operaFITSImageSetData(operaFITSSubImage &subImage)

Parameters:
datasecSubImagethe datasec sub image
Returns:
void

Here is the call graph for this function:

void operaEspadonsImage::setpixel ( unsigned short  value,
unsigned  x,
unsigned  y 
) [inline]

get a pixel value at coordinates x,y.

setpixel(value, unsigned x, unsigned y)

Parameters:
value- the pixel value
x- the x coordinate
y- the y coordinate
Note:
This method does a shift left by 11 as the image width is known to be 2048 pixels
and a shift is faster than a multiply. If the espadons image width ever changes
this will have to be revisited.
Returns:
unsigned short

Reimplemented from operaFITSImage.

void operaEspadonsImage::setpixel ( float  value,
unsigned  x,
unsigned  y 
) [inline]

Reimplemented from operaFITSImage.


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