SatDump 2.0.0-alpha-76a915210
Loading...
Searching...
No Matches
bright_temp_to_em_rad.h
Go to the documentation of this file.
1#pragma once
2
6
8
9namespace satdump
10{
11 namespace calibration
12 {
13 namespace conv
14 {
24 {
25 public:
26 double convert(const UnitConverter *c, double x, double y, double val)
27 {
28 if (val == CALIBRATION_INVALID_VALUE)
29 return val; // Special case
30
31 if (c->wavenumber == -1)
32 return CALIBRATION_INVALID_VALUE;
33 return temperature_to_radiance(val, c->wavenumber);
34 }
35
36 bool convert_range(const UnitConverter *c, double &min, double &max)
37 {
38 min = convert(c, 0, 0, min);
39 max = convert(c, 0, 0, max);
40 return true;
41 }
42 };
43 } // namespace conv
44 } // namespace calibration
45} // namespace satdump
Base class for unit converters. This is meant to implement conversions between calibration unit types...
Definition calibration_converter.h:26
Universal UnitConverter class, handling all conversion logic between any calibration unit type to ano...
Definition calibration_converter.h:115
Brightness Temperate to Emissive Radiance converter.
Definition bright_temp_to_em_rad.h:24
double convert(const UnitConverter *c, double x, double y, double val)
Core function (for images!) implementing conversion between calibration unit types.
Definition bright_temp_to_em_rad.h:26
bool convert_range(const UnitConverter *c, double &min, double &max)
Convert unit ranges. This does the same as convert, except it's optimized for converting a range.
Definition bright_temp_to_em_rad.h:36