ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
CRC::Parameters< CRCType, CRCWidth > Struct Template Reference

CRC parameters. More...

#include <CRC.h>

Public Member Functions

Table< CRCType, CRCWidth > MakeTable () const
 Returns a CRC lookup table construct using these CRC parameters. More...
 

Public Attributes

CRCType polynomial
 CRC polynomial. More...
 
CRCType initialValue
 Initial CRC value. More...
 
CRCType finalXOR
 Value to XOR with the final CRC. More...
 
bool reflectInput
 true to reflect all input bytes More...
 
bool reflectOutput
 true to reflect the output CRC (reflection occurs before the final XOR) More...
 

Detailed Description

template<typename CRCType, uint16_t CRCWidth>
struct CRC::Parameters< CRCType, CRCWidth >

CRC parameters.

Definition at line 151 of file CRC.h.

Member Function Documentation

◆ MakeTable()

template<typename CRCType , uint16_t CRCWidth>
CRC::Table< CRCType, CRCWidth > CRC::Parameters< CRCType, CRCWidth >::MakeTable ( ) const
inline

Returns a CRC lookup table construct using these CRC parameters.

Note
This function primarily exists to allow use of the auto keyword instead of instantiating a table directly, since template parameters are not inferred in constructors.
Template Parameters
CRCTypeInteger type for storing the CRC result
CRCWidthNumber of bits in the CRC
Returns
CRC lookup table

Definition at line 314 of file CRC.h.

Member Data Documentation

◆ finalXOR

template<typename CRCType , uint16_t CRCWidth>
CRCType CRC::Parameters< CRCType, CRCWidth >::finalXOR

Value to XOR with the final CRC.

Definition at line 155 of file CRC.h.

Referenced by CRC::Calculate().

◆ initialValue

template<typename CRCType , uint16_t CRCWidth>
CRCType CRC::Parameters< CRCType, CRCWidth >::initialValue

Initial CRC value.

Definition at line 154 of file CRC.h.

Referenced by CRC::Calculate().

◆ polynomial

template<typename CRCType , uint16_t CRCWidth>
CRCType CRC::Parameters< CRCType, CRCWidth >::polynomial

CRC polynomial.

Definition at line 153 of file CRC.h.

◆ reflectInput

template<typename CRCType , uint16_t CRCWidth>
bool CRC::Parameters< CRCType, CRCWidth >::reflectInput

true to reflect all input bytes

Definition at line 156 of file CRC.h.

Referenced by CRC::Calculate().

◆ reflectOutput

template<typename CRCType , uint16_t CRCWidth>
bool CRC::Parameters< CRCType, CRCWidth >::reflectOutput

true to reflect the output CRC (reflection occurs before the final XOR)

Definition at line 157 of file CRC.h.

Referenced by CRC::Calculate().


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