Carna Version 3.3.3
Loading...
Searching...
No Matches
Public Member Functions | Static Public Member Functions | Public Attributes | List of all members
Carna::base::HUV Struct Reference

Represents values in \(\left[-1024, +3071\right]\). More...

#include <HUV.h>

Public Member Functions

 operator signed short () const
 Implicitly casts into a signed short and yields value.
 
 HUV ()=default
 Constructor.
 
 HUV (signed int value, bool absolute=false)
 Creates HUV with value. Clamps to \(\left[-1024, 3071\right]\) if absolute is true.
 
 HUV (float intensity, bool absolute=false)
 Creates HUV corresponding to intensity. Clamps to \(\left[-1024, 3071\right]\) if absolute is true.
 
float absIntensity () const
 Returns the corresponding absolute intensity.
 
float relIntensity () const
 Returns the corresponding relative intensity.
 

Static Public Member Functions

template<typename T >
static HUV abs (T value)
 Wraps an absolute HU value.
 
template<typename T >
static HUV rel (T value)
 Wraps a relative HU value.
 

Public Attributes

signed short value
 Holds the HU value.
 

Detailed Description

Represents values in \(\left[-1024, +3071\right]\).

Author
Leonid Kostrykin
Date
June 2021

Definition at line 34 of file HUV.h.

Constructor & Destructor Documentation

◆ HUV() [1/2]

Carna::base::HUV::HUV ( signed int  value,
bool  absolute = false 
)
inlineexplicit

Creates HUV with value. Clamps to \(\left[-1024, 3071\right]\) if absolute is true.

Definition at line 95 of file HUV.h.

◆ HUV() [2/2]

Carna::base::HUV::HUV ( float  intensity,
bool  absolute = false 
)
inlineexplicit

Creates HUV corresponding to intensity. Clamps to \(\left[-1024, 3071\right]\) if absolute is true.

Definition at line 106 of file HUV.h.

Member Function Documentation

◆ abs()

template<typename T >
HUV Carna::base::HUV::abs ( value)
static

Wraps an absolute HU value.

Definition at line 134 of file HUV.h.

◆ absIntensity()

float Carna::base::HUV::absIntensity ( ) const
inline

Returns the corresponding absolute intensity.

Definition at line 121 of file HUV.h.

◆ operator signed short()

Carna::base::HUV::operator signed short ( ) const
inline

Implicitly casts into a signed short and yields value.

Definition at line 89 of file HUV.h.

◆ rel()

template<typename T >
HUV Carna::base::HUV::rel ( value)
static

Wraps a relative HU value.

Definition at line 141 of file HUV.h.

◆ relIntensity()

float Carna::base::HUV::relIntensity ( ) const
inline

Returns the corresponding relative intensity.

Definition at line 127 of file HUV.h.

Member Data Documentation

◆ value

signed short Carna::base::HUV::value

Holds the HU value.

Definition at line 40 of file HUV.h.


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