Atlas-Cronos  7.1.0
Public Member Functions | Static Public Member Functions | Protected Member Functions | Properties | List of all members
Flir.Atlas.Image.ThermalImageFile Class Reference

This class represents an Thermal image. More...

Inheritance diagram for Flir.Atlas.Image.ThermalImageFile:
Flir.Atlas.Image.ThermalImage Flir.Atlas.Image.ImageBase Flir.Atlas.Image.Helpers.DisposableObject

Public Member Functions

 ThermalImageFile ()
 Creates an instance of a ThermalImageFile. More...
 
 ThermalImageFile (byte [] fff)
 Creates an instance of a ThermalImageFile. More...
 
new void Dispose ()
 Releases all resources used by this ThermalImageFile. More...
 
 ThermalImageFile (string path)
 Creates an instance of an IRImage from a file on the specified path. More...
 
 ThermalImageFile (Stream path)
 Creates an instance of an IRImage from a file on the specified path. More...
 
int Count ()
 Gets the number of frames. More...
 
void ConvertToUltraMax ()
 Converts the image to an UltraMax image More...
 
void Open (Stream stream)
 Open a thermal image from a stream. More...
 
void Open (string fileName)
 Opens a Thermal Image from the specified file.
More...
 
void Close ()
 Closes the file stream. More...
 
void Crop (Rectangle rect, string path)
 Crop the file . More...
 
void Save (Bitmap overlay)
 Saves the Thermal Image to file. More...
 
void Save (string filename, Bitmap overlay)
 Saves the Thermal Image to the specified file. More...
 
void Save (Stream targetStream, Bitmap overlay=null)
 Saves the Thermal Image to the specified stream. More...
 
void Save ()
 Saves the Thermal Image to file. More...
 
void Save (string filename)
 Saves the Thermal Image to the specified file. More...
 
- Public Member Functions inherited from Flir.Atlas.Image.ThermalImage
override void SaveSnapshot (string filename, Bitmap overlay)
 Saves the current image to disk. More...
 
new void Dispose ()
 Releases all resources used by this Thermal-image. More...
 
override bool Create (string formatId, bool loadAll=true)
 Create the underlying format (internal use) More...
 
bool CreateFFF ()
 Create empty image. This is method is mainly for internal use. More...
 
new void SaveSnapshot (string filename)
 Saves the current image to disk. More...
 
ThermalValue GetValueAt (Point location)
 Gets a ThermalValue from a position in the Thermal Image. More...
 
int GetSignalFromOutput (double value)
 Extrapolate a signal value from an output value. More...
 
double GetValueFromSignal (int signal)
 Gets a temperature value from a signal. More...
 
double [] GetValues (Point[] points)
 Gets temperature values from an array of points. More...
 
double [] GetValues (Rectangle rectangle)
 Gets temperatures from a signal. More...
 
void GetValues (Rectangle rectangle, ref double [] data)
 Get values by reference to data buffer More...
 
double GetEmissivityFromValue (double temperatureMeasured, double actualTemperature)
 Calculates emissivity from a known temperature. More...
 
double GetEmissivityFromValue (int x, int y, double actualTemperature)
 Calculates emissivity from a known temperature. More...
 
double GetValueFromEmissivity (double emissivity, double temperature)
 Calculates temperature in current TemperatureUnit. More...
 
double CalculateEmissivity (double radiationMeasured, double? emissivityMeasured, double radiationKnown, double radiationReflected)
 Calculates the emissivity from reference temperature. More...
 
override void RenderTo (Flir.Atlas.Image.Interfaces.IPixels imagePixels)
 Render the new image to the input image buffer IPixels. More...
 
byte [,,] ImageArray ()
 Returns a byte array representing the image. More...
 
Bitmap Rotate (int angle)
 Rotate the image. !WARNING: The bitmap is created per-request, dispose when not needed! More...
 
void SetRotate (int angle)
 Rotate the image. More...
 
void SetSketch (bool value)
 Sets sketch on or off. More...
 
Bitmap GetPhoto ()
 Gets the embedded photo. More...
 
override void Copy (ImageBase src)
 Deep copy a ThermalImage from source except of pixel data. More...
 
- Public Member Functions inherited from Flir.Atlas.Image.ImageBase
virtual bool Load (byte[] image, int size)
 Loads a FFF image from memory More...
 
virtual bool Load (byte[] image)
 Loads an Thermal FFF Image from a byte array.
More...
 
virtual bool Load (byte[] image, ImageLoadParameters loadParams)
 Loads an Thermal FFF Image from a byte array.
More...
 
virtual byte [] GetData ()
 Get embedded radiometric data blob FFF. This method shall not be used for accessing the pixel data instead use the methods and properties found in ImageProcessing. More...
 
virtual byte [] GetFormattedImageData ()
 Get embedded radiometric data blob FFF with applied image data. This method shall not be used for accessing the pixel data instead use the methods and properties found in ImageProcessing. More...
 
virtual bool GetData (Stream stream)
 Get embedded radiometric data blob FFF. This method shall not be used for accessing the pixel data instead use the methods and properties found in ImageProcessing. More...
 
void SaveSnapshot (string filename)
 Saves the current image to disk. More...
 
void InternalSaveSnapshot (string filename, Bitmap overlay)
 
void Swap ()
 Manually swaps the image back buffer. More...
 
void EnterLock ()
 Acquires an exclusive lock. More...
 
bool TryEnterLock ()
 Attempts to acquire an exclusive lock. More...
 
void ExitLock ()
 Releases an exclusive lock. More...
 
virtual bool HasSketch ()
 Return true if the image has a sketch image. More...
 
bool IsSketchEnabled ()
 Return true if the image has a sketch image and it is enabled. More...
 
- Public Member Functions inherited from Flir.Atlas.Image.Helpers.DisposableObject
void Dispose ()
 

Static Public Member Functions

static bool IsThermalImage (string fileName)
 Check if the file contains thermal data. More...
 
static bool IsThermalImage (Stream stream)
 Check if the stream contains thermal data. More...
 

Protected Member Functions

override void Initialize ()
 Initializes the Thermal Image. More...
 
- Protected Member Functions inherited from Flir.Atlas.Image.ThermalImage
void SetupFusion ()
 Check if the image contains Fusion data and set up event handling More...
 
void SetColorDistribution (ColorDistribution value)
 Set color distribution. More...
 
void SetColorDistributionSettings (ColorDistributionSettings value)
 Set color distribution. More...
 
Rectangle GetZoomPosition (Rectangle rectPos, IFrame frame)
 Calculate the position of the rectangle in a zoomed in image. More...
 
Rectangle GetZoomPositionRotate (Rectangle rectPos, IFrame frame)
 Calculate the position of the rectangle in a zoomed in image. More...
 
void GetZoomAndPan (out float zoomFactor, out short panX, out short panY, IFrame frame)
 Gets the zoom and pan settings. More...
 
virtual void CurrentTemperature_UnitChanged (object sender, TemperatureUnitEventArgs e)
 Will be called whenever the temperatuer unit is changed. More...
 
override void RaiseChangedEvent ()
 Shall be raised for any changes made to the Thermal-image. More...
 
- Protected Member Functions inherited from Flir.Atlas.Image.ImageBase
override void DisposeManagedResources ()
 
- Protected Member Functions inherited from Flir.Atlas.Image.Helpers.DisposableObject
virtual void DisposeUnmanagedResources ()
 

Properties

ThermalSequencePlayer ThermalSequencePlayer [get]
 Gets the ThermalSequencePlayer Plays seq, csq and fcf files. If Count > 1 it is a sequence More...
 
string FileName [get, set]
 Gets the name of the current opened file. More...
 
bool ContainsUltraMaxData [get]
 Check if the image contains UltraMax data. Images containing UltraMax data can be converted to UltraMax, see ConvertToUltraMax() More...
 
string Title [get]
 Gets the image title. More...
 
- Properties inherited from Flir.Atlas.Image.ThermalImage
Bitmap JpegImage [get, set]
 Gets or sets the jpeg representation of the Thermal image. More...
 
int OverflowSignalValue [get]
 Gets the overflow signal value. More...
 
int UnderflowSignalValue [get]
 Gets the underflow signal value. More...
 
int MinSignalValue [get]
 Gets the minimum signal value of the image. More...
 
int MaxSignalValue [get]
 Gets the maximum signal value of the image. More...
 
int Precision [get]
 Presentation precision gets number of decimals. More...
 
ZoomSettings Zoom [get]
 Image zoom settings. More...
 
ColorDistribution ColorDistribution [get, set]
 Gets or sets the Thermal image color distribution. More...
 
Calculator ThermalMeasurements [get]
 Calculate advanced measurements More...
 
ImageStatistics Statistics [get]
 Gets the image results ImageStatistics More...
 
ImageParameters ThermalParameters [get, protected set]
 Gets the image object parameters i.e. emissivity, distance etc. More...
 
TemperatureUnit TemperatureUnit [get, set]
 Gets or sets the temperature unit and will propagate a TemperatureUnitChanged event when changed. More...
 
DistanceUnit DistanceUnit [get, set]
 Gets or sets the distance unit. More...
 
CameraInformation CameraInformation [get, set]
 Gets information about the camera used to create this Thermal image. More...
 
Histogram Histogram [get]
 Gets the image Histogram. More...
 
MeasurementCollection Measurements [get]
 Gets the measurements collection. More...
 
TriggerData Trigger [get]
 Gets the trigger settings for this image. More...
 
Scale Scale [get, set]
 Gets the scale object. More...
 
Palettes.PaletteManager PaletteManager [get]
 Gets the palette object. More...
 
Palette Palette [get, set]
 Handle palette selections More...
 
IsothermCollection Isotherms [get]
 Gets the collection of isotherms. More...
 
AlarmCollection Alarms [get]
 Gets the collection of alarms. More...
 
Fusion.Fusion Fusion [get, protected set]
 Gets the Fusion object. More...
 
override Bitmap Image [get]
 Returns a System.Drawing.Bitmap representing the image. !WARNING: The bitmap is created per-request, dispose when not needed! More...
 
DateTime DateTime [get, set]
 Gets the image creation UTC date and time. More...
 
DateTime DateTaken [get]
 Gets the date and time when the image was shot/taken More...
 
Dictionary< string, string > TextAnnotations [get]
 Gets a collection of text annotation objects. Text annotations are Key, Value items i.e. Location – area 51. More...
 
SensorsCollection SensorsCollection [get]
 Gets a collection of sensor data objects. More...
 
VoiceAnnotation VoiceAnnotation [get]
 Gets the voice annotation object. More...
 
- Properties inherited from Flir.Atlas.Image.ImageBase
abstract Bitmap Image [get]
 Returns a System.Drawing.Bitmap representing the image. !WARNING: The bitmap is created per-request, dispose when not needed! More...
 
bool IsSilent [get, set]
 Set to true if no events is wanted from the image. More...
 
ImageProcessing.ImageProcessing ImageProcessing [get]
 Advanced image processing. More...
 
ThermalPipeline ThermalPipeline [get]
 Gets the pipeline Pipeline. More...
 
virtual int Width [get]
 Gets the width of the image in pixels. More...
 
virtual int Height [get]
 Gets the height of the image in pixels. More...
 
virtual Size Size [get]
 Gets the width and height of the image in pixels. More...
 
CompassInfo CompassInformation [get]
 Gets the compassInformation of the image. More...
 
Flir.Atlas.Image.GPSInfo GpsInformation [get]
 Gets the GPS information from the image. More...
 
virtual string Description [get, set]
 Gets or sets the image description from the Exif (Exchangeable image file format) data. More...
 
bool IsDisposed [get]
 True if this instance has been disposed More...
 
static string Version [get]
 Gets the used Atlas Image version. More...
 
- Properties inherited from Flir.Atlas.Image.Helpers.DisposableObject
bool Disposed [get]
 

Additional Inherited Members

- Static Public Attributes inherited from Flir.Atlas.Image.ThermalImage
static TemperatureUnit DefaultTemperatureUnit = TemperatureUnit.Celsius
 Gets or sets the default temperature unit used in all instances of ThermalImage More...
 
static DistanceUnit DefaultDistanceUnit = DistanceUnit.Meter
 Gets or sets the default distance unit used in all instances of ThermalImage More...
 
- Protected Attributes inherited from Flir.Atlas.Image.ImageBase
ImageProcessing.ImageProcessing _imageProcessing
 
Cronos.IR.RotateFlipType _RotationAngle
 
- Events inherited from Flir.Atlas.Image.ThermalImage
EventHandler< TemperatureUnitEventArgsTemperatureUnitChanged
 Occurs when the temperature unit is changed. More...
 
- Events inherited from Flir.Atlas.Image.ImageBase
EventHandler< ImageChangedEventArgsChanged
 Occurs when an image has changed e.g. needs to be updated. More...
 

Detailed Description

This class represents an Thermal image.

Thread Safety
Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Examples
The following code example demonstrates how to construct a new ThermalImageFile from a file, using the IRImage constructor. This example is designed to be used with a Windows Forms that contains a PictureBox, and Button named PictureBox1, and Button1, respectively. Paste the code into the form and associate the Button1_Click method with the button's Click event.
private void button1_Click(object sender, EventArgs e)
{
var irImage = new ThermalImageFile(@"C:\Images\IR_2034.jpg");
pictureBox1.Image = irImage.Image;
}

Constructor & Destructor Documentation

◆ ThermalImageFile() [1/4]

Flir.Atlas.Image.ThermalImageFile.ThermalImageFile ( )
inline

Creates an instance of a ThermalImageFile.

Exceptions
Flir.Atlas.Image.ThermalExceptionAn internal error has occured.

◆ ThermalImageFile() [2/4]

Flir.Atlas.Image.ThermalImageFile.ThermalImageFile ( byte []  fff)
inline

Creates an instance of a ThermalImageFile.

Parameters
fffimage bytes
Exceptions
Flir.Atlas.Image.ThermalExceptionAn internal error has occured.

◆ ThermalImageFile() [3/4]

Flir.Atlas.Image.ThermalImageFile.ThermalImageFile ( string  path)
inline

Creates an instance of an IRImage from a file on the specified path.

Parameters
pathThe file to open.
Exceptions
Flir.Atlas.Image.ThermalExceptionAn internal error has occurred.
System.ArgumentExceptionThe path is null or empty.
System.IO.FileNotFoundExceptionThe file specified in path was not found.

◆ ThermalImageFile() [4/4]

Flir.Atlas.Image.ThermalImageFile.ThermalImageFile ( Stream  path)
inline

Creates an instance of an IRImage from a file on the specified path.

Parameters
pathThe file to open.
Exceptions
Flir.Atlas.Image.ThermalExceptionAn internal error has occurred.
System.ArgumentExceptionThe path is null or empty.
System.IO.FileNotFoundExceptionThe file specified in path was not found.

Member Function Documentation

◆ Close()

void Flir.Atlas.Image.ThermalImageFile.Close ( )
inline

Closes the file stream.

Only Save() with a filename will work after a call to Close() all other calls to Save(...) will throw an exception.

◆ ConvertToUltraMax()

void Flir.Atlas.Image.ThermalImageFile.ConvertToUltraMax ( )
inline

Converts the image to an UltraMax image

◆ Count()

int Flir.Atlas.Image.ThermalImageFile.Count ( )
inline

Gets the number of frames.

Returns
Number of frames in the image file

◆ Crop()

void Flir.Atlas.Image.ThermalImageFile.Crop ( Rectangle  rect,
string  path 
)
inline

Crop the file .

Parameters
rectrectangle to crop
pathpath and file name where the croped image should be saved

◆ Dispose()

new void Flir.Atlas.Image.ThermalImageFile.Dispose ( )
inline

Releases all resources used by this ThermalImageFile.

◆ Initialize()

override void Flir.Atlas.Image.ThermalImageFile.Initialize ( )
inlineprotectedvirtual

Initializes the Thermal Image.

Reimplemented from Flir.Atlas.Image.ThermalImage.

◆ IsThermalImage() [1/2]

static bool Flir.Atlas.Image.ThermalImageFile.IsThermalImage ( string  fileName)
inlinestatic

Check if the file contains thermal data.

Parameters
fileNamepath to file.
Returns
true if thermal image.

◆ IsThermalImage() [2/2]

static bool Flir.Atlas.Image.ThermalImageFile.IsThermalImage ( Stream  stream)
inlinestatic

Check if the stream contains thermal data.

Parameters
streamstream to analyze.
Returns
true if thermal image.

◆ Open() [1/2]

void Flir.Atlas.Image.ThermalImageFile.Open ( Stream  stream)
inline

Open a thermal image from a stream.

Parameters
streamThe stream containing the thermal image.
Exceptions
InvalidOperationException
ThermalException

◆ Open() [2/2]

void Flir.Atlas.Image.ThermalImageFile.Open ( string  fileName)
inline

Opens a Thermal Image from the specified file.

Parameters
fileNameThe file to open
Exceptions
System.ArgumentExceptionThe path is null or empty.
System.Security.SecurityExceptionA caller higher in the call stack does not have the permission specified by the current instance.
System.IO.FileNotFoundExceptionThe file specified in path was not found.
Flir.Atlas.Image.ThermalExceptionFailed to open Thermal image.

◆ Save() [1/5]

void Flir.Atlas.Image.ThermalImageFile.Save ( Bitmap  overlay)
inline

Saves the Thermal Image to file.

Parameters
overlayThe jpeg representation of the Thermal image.
Exceptions
System.InvalidOperationExceptionThe FileName is null or empty.
System.Security.SecurityExceptionA caller higher in the call stack does not have the permission specified by the current instance.
Flir.Atlas.Image.ThermalExceptionFailed to save Thermal image.

Overwrites the current file. Overlay is the image that will be seen when viewing the Thermal image in Windows Explorer or an external image viewer.

◆ Save() [2/5]

void Flir.Atlas.Image.ThermalImageFile.Save ( string  filename,
Bitmap  overlay 
)
inline

Saves the Thermal Image to the specified file.

Parameters
filenameA string that specifies the path to the location on which to save the file
overlayThe jpeg representation of the Thermal image.
Exceptions
System.ArgumentExceptionThe fileName is null or empty.
System.Security.SecurityExceptionA caller higher in the call stack does not have the permission specified by the current instance.
Flir.Atlas.Image.ThermalExceptionFailed to save Thermal image.

◆ Save() [3/5]

void Flir.Atlas.Image.ThermalImageFile.Save ( Stream  targetStream,
Bitmap  overlay = null 
)
inline

Saves the Thermal Image to the specified stream.

Parameters
targetStream
overlay
Exceptions
ThermalException

◆ Save() [4/5]

void Flir.Atlas.Image.ThermalImageFile.Save ( )
inline

Saves the Thermal Image to file.

Exceptions
System.InvalidOperationExceptionThe FileName is null or empty.
System.Security.SecurityExceptionA caller higher in the call stack does not have the permission specified by the current instance.
Flir.Atlas.Image.ThermalExceptionFailed to save Thermal image.

Overwrites the current file.

◆ Save() [5/5]

void Flir.Atlas.Image.ThermalImageFile.Save ( string  filename)
inline

Saves the Thermal Image to the specified file.

Parameters
filenameA string that specifies the path to the location on which to save the file
Exceptions
System.ArgumentExceptionThe fileName is null or empty.
System.Security.SecurityExceptionA caller higher in the call stack does not have the permission specified by the current instance.
Flir.Atlas.Image.ThermalExceptionFailed to save Thermal image.

Property Documentation

◆ ContainsUltraMaxData

bool Flir.Atlas.Image.ThermalImageFile.ContainsUltraMaxData
get

Check if the image contains UltraMax data. Images containing UltraMax data can be converted to UltraMax, see ConvertToUltraMax()

◆ FileName

string Flir.Atlas.Image.ThermalImageFile.FileName
getset

Gets the name of the current opened file.

The file name includes both the file path and the extension. If no file is opened, this method returns an empty string ("").

◆ ThermalSequencePlayer

ThermalSequencePlayer Flir.Atlas.Image.ThermalImageFile.ThermalSequencePlayer
get

Gets the ThermalSequencePlayer Plays seq, csq and fcf files. If Count > 1 it is a sequence

◆ Title

string Flir.Atlas.Image.ThermalImageFile.Title
get

Gets the image title.

If no title was set in the camera, the file name will be used.