VisionServer  v2.1.1-1-g21dc5465
FRC vision library
calib.h File Reference
#include <vector>
#include <array>
#include <string>
#include <map>
#include <unordered_map>
#include <opencv2/core/types.hpp>
#include <wpi/json.h>
#include <wpi/StringMap.h>
#include <charconv>
#include <type_traits>
#include <cpp-tools/src/types.h>
+ Include dependency graph for calib.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  __CalibSet
 
struct  CalibSet_< fp_T, map_T >
 
struct  __CalibMap
 
struct  __CalibSMap
 
struct  CalibSMap_< fp_T, cmap_T, smap_T >
 
struct  __CalibMat
 
struct  CalibMat_< fp_T, str_T, cmap_T, nmap_T >
 
struct  CalProps< typename >
 
struct  CalProps< CalibSet_< fp_T, cmap_T > >
 
struct  CalProps< CalibSMap_< fp_T, cmap_T, smap_T > >
 
struct  CalProps< CalibMat_< fp_T, str_T, cmap_T, nmap_T > >
 

Macros

#define CALIB_DEFAULT_FLOAT_TYPE   float
 
#define CALIB_DEFAULT_STRING_TYPE   std::string
 
#define CALIB_DEFAULT_MAP_TYPE   VecMap
 
#define CALIB_DEFAULT_SMAP_TYPE   wpi::StringMap
 

Typedefs

template<typename first_T , typename second_T >
using VecMap = std::vector< std::pair< first_T, second_T > >
 
template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE>
using Calibration_ = std::array< cv::Mat_< fp_T >, 2 >
 
typedef Calibration_ Calibration
 
typedef CalibSet_ CalibSet
 
typedef CalibSMap_ CalibSMap
 
typedef CalibMat_ CalibMat
 
template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE, typename str_T = CALIB_DEFAULT_STRING_TYPE, template< typename, typename > typename map_T = CALIB_DEFAULT_MAP_TYPE>
using CalibMap_ = CalibMat_< fp_T, str_T, map_T, map_T >
 
typedef CalibMap_ CalibMap
 
template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE>
using CalibSList_ = CalibSMap_< fp_T, VecMap, wpi::StringMap >
 
typedef CalibSList_ CalibSList
 
template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE, typename str_T = CALIB_DEFAULT_STRING_TYPE>
using CalibList_ = CalibMap_< fp_T, str_T, VecMap >
 
typedef CalibList_ CalibList
 

Functions

template<typename num_T = int>
cv::Size_< num_T > extractSize (std::string_view str)
 
template<typename Map >
const Map::Set_T * findSet (std::string_view name, const Map &map)
 
template<typename Set >
const Set::Cal_T * findCalib (const cv::Size2i &sz, const Set &set)
 
template<typename Map >
const Map::Cal_T * findCalib (std::string_view name, const cv::Size2i &sz, const Map &map)
 
template<typename Map >
const Map::Cal_T * findAnyCalib (std::initializer_list< std::string_view > names, const cv::Size2i &sz, const Map &map)
 
template<typename Map >
const Map::Set_T * wpi_find_set_impl (std::string_view name, const Map &map)
 
template<typename Map >
const Map::Set_T * seq_find_set_impl (std::string_view name, const Map &map)
 
template<typename Map >
const Map::Set_T * assoc_find_set_impl (std::string_view name, const Map &map)
 
template<typename Set >
const Set::Cal_T * seq_find_calib_impl (const cv::Size2i &sz, const Set &set)
 
template<typename Set >
const Set::Cal_T * assoc_find_calib_impl (const cv::Size2i &sz, const Set &set)
 

Macro Definition Documentation

◆ CALIB_DEFAULT_FLOAT_TYPE

#define CALIB_DEFAULT_FLOAT_TYPE   float

Definition at line 18 of file calib.h.

◆ CALIB_DEFAULT_STRING_TYPE

#define CALIB_DEFAULT_STRING_TYPE   std::string

Definition at line 21 of file calib.h.

◆ CALIB_DEFAULT_MAP_TYPE

#define CALIB_DEFAULT_MAP_TYPE   VecMap

Definition at line 24 of file calib.h.

◆ CALIB_DEFAULT_SMAP_TYPE

#define CALIB_DEFAULT_SMAP_TYPE   wpi::StringMap

Definition at line 27 of file calib.h.

Typedef Documentation

◆ VecMap

template<typename first_T , typename second_T >
using VecMap = std::vector<std::pair<first_T, second_T> >

Definition at line 15 of file calib.h.

◆ Calibration_

template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE>
using Calibration_ = std::array<cv::Mat_<fp_T>, 2>

Definition at line 50 of file calib.h.

◆ Calibration

Definition at line 52 of file calib.h.

◆ CalibSet

Definition at line 74 of file calib.h.

◆ CalibSMap

Definition at line 102 of file calib.h.

◆ CalibMat

Definition at line 131 of file calib.h.

◆ CalibMap_

template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE, typename str_T = CALIB_DEFAULT_STRING_TYPE, template< typename, typename > typename map_T = CALIB_DEFAULT_MAP_TYPE>
using CalibMap_ = CalibMat_<fp_T, str_T, map_T, map_T>

Definition at line 161 of file calib.h.

◆ CalibMap

Definition at line 163 of file calib.h.

◆ CalibSList_

template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE>
using CalibSList_ = CalibSMap_<fp_T, VecMap, wpi::StringMap>

Definition at line 166 of file calib.h.

◆ CalibSList

Definition at line 167 of file calib.h.

◆ CalibList_

template<typename fp_T = CALIB_DEFAULT_FLOAT_TYPE, typename str_T = CALIB_DEFAULT_STRING_TYPE>
using CalibList_ = CalibMap_<fp_T, str_T, VecMap>

Definition at line 172 of file calib.h.

◆ CalibList

Definition at line 173 of file calib.h.

Function Documentation

◆ extractSize()

template<typename num_T = int>
cv::Size_< num_T > extractSize ( std::string_view  str)

Definition at line 209 of file calib.h.

◆ findSet()

template<typename Map >
const Map::Set_T * findSet ( std::string_view  name,
const Map &  map 
)

Definition at line 307 of file calib.h.

◆ findCalib() [1/2]

template<typename Set >
const Set::Cal_T * findCalib ( const cv::Size2i &  sz,
const Set &  set 
)

Definition at line 322 of file calib.h.

◆ findCalib() [2/2]

template<typename Map >
const Map::Cal_T * findCalib ( std::string_view  name,
const cv::Size2i &  sz,
const Map &  map 
)

Definition at line 333 of file calib.h.

◆ findAnyCalib()

template<typename Map >
const Map::Cal_T * findAnyCalib ( std::initializer_list< std::string_view >  names,
const cv::Size2i &  sz,
const Map &  map 
)

Definition at line 341 of file calib.h.

◆ wpi_find_set_impl()

template<typename Map >
const Map::Set_T * wpi_find_set_impl ( std::string_view  name,
const Map &  map 
)

Definition at line 357 of file calib.h.

◆ seq_find_set_impl()

template<typename Map >
const Map::Set_T * seq_find_set_impl ( std::string_view  name,
const Map &  map 
)

Definition at line 366 of file calib.h.

◆ assoc_find_set_impl()

template<typename Map >
const Map::Set_T * assoc_find_set_impl ( std::string_view  name,
const Map &  map 
)

Definition at line 376 of file calib.h.

◆ seq_find_calib_impl()

template<typename Set >
const Set::Cal_T * seq_find_calib_impl ( const cv::Size2i &  sz,
const Set &  set 
)

Definition at line 386 of file calib.h.

◆ assoc_find_calib_impl()

template<typename Set >
const Set::Cal_T * assoc_find_calib_impl ( const cv::Size2i &  sz,
const Set &  set 
)

Definition at line 396 of file calib.h.