Thermal Camera SDK 10.0.1
SDK for Optris Thermal Cameras
Loading...
Searching...
No Matches
optris::TemperatureRegion Struct Reference

Characterizes a rectangular region by the indexes of the upper left and the lower right corners along with an associated temperature. More...

#include <ImageBuilder.h>

Collaboration diagram for optris::TemperatureRegion:
Collaboration graph

Public Member Functions

 TemperatureRegion () noexcept
 Constructor.
 
 TemperatureRegion (int x1, int y1, int x2, int y2) noexcept
 Constructor.
 
void reset () noexcept
 Resets the temperature and the coordinates of the corners.
 
bool fitsInRectangle (int width, int height, int padding=0) const noexcept
 Returns whether the region fits within a rectangle of the given dimensions.
 

Public Attributes

float temperature
 Associated temperature in °C.
 
int x1
 X index of the upper left corner.
 
int y1
 Y index of the upper left corner.
 
int x2
 X index of the lower right corner.
 
int y2
 Y index of the lower right corner.
 

Detailed Description

Characterizes a rectangular region by the indexes of the upper left and the lower right corners along with an associated temperature.

Note that the origin of coordinates is located in upper left corner with the x-axis pointing right and the y-axis pointing downwards.

+---> x | v 1--------—+ y | | | | +--------—2

=> x1 <= x2 & y1 <= y2

Constructor & Destructor Documentation

◆ TemperatureRegion()

optris::TemperatureRegion::TemperatureRegion ( int x1,
int y1,
int x2,
int y2 )
noexcept

Constructor.

Parameters
[in]x1x index of the upper left corner.
[in]y1y index of the upper left corner.
[in]x2x index of the lower right corner.
[in]y2y index of the lower right corner.

Member Function Documentation

◆ fitsInRectangle()

bool optris::TemperatureRegion::fitsInRectangle ( int width,
int height,
int padding = 0 ) const
noexcept

Returns whether the region fits within a rectangle of the given dimensions.

Parameters
[in]widthin pixels of the rectangle to fit the region in.
[in]heightin pixels of the rectangle to fit the region in.
[in]paddingin pixels applied to the region in all directions during the check.
Returns
true if the region fits in the given rectangle. False otherwise.

The documentation for this struct was generated from the following file: