Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
LinearCharacteristics.h
00001 #ifndef LINEAR_CHARACTERISTICS_H_ 00002 #define LINEAR_CHARACTERISTICS_H_ 00003 00004 class LinearCharacteristics 00005 { 00006 00007 public: 00008 00009 LinearCharacteristics(float gain, float offset); 00010 LinearCharacteristics(float x0, float x1, float y0, float y1); 00011 LinearCharacteristics(float x0, float x1, float y0, float y1, float yMin, float yMax); 00012 00013 LinearCharacteristics() {}; 00014 00015 virtual ~LinearCharacteristics(); 00016 00017 float operator()(float x) 00018 { 00019 return evaluate(x); 00020 } 00021 00022 float evaluate(float x); 00023 00024 void setup(float gain, float offset); 00025 void setup(float x0, float x1, float y0, float y1); 00026 void setup(float x0, float x1, float y0, float y1, float yMin, float yMax); 00027 00028 void correctExistingOffset(float); 00029 00030 private: 00031 00032 float gain; 00033 float offset; 00034 float yMin; 00035 float yMax; 00036 00037 }; 00038 00039 #endif
Generated on Thu Nov 17 2022 22:07:39 by
1.7.2