ACloudViewer  3.9.4
A Modern Library for 3D Data Processing
ccNormalCompressor Class Reference

Normal compressor. More...

#include <ecvNormalCompressor.h>

Static Public Member Functions

static unsigned Compress (const PointCoordinateType N[3])
 Compression algorithm. More...
 
static void Decompress (unsigned index, PointCoordinateType N[3], unsigned char level=QUANTIZE_LEVEL)
 Decompression algorithm. More...
 
static void InvertNormal (CompressedNormType &code)
 Inverts a (compressed) normal. More...
 

Static Public Attributes

static const unsigned char QUANTIZE_LEVEL
 Compressed normals quantization level (number of directions: 2^(2*N+3)) More...
 
static const unsigned MAX_VALID_NORM_CODE
 Last valid normal code. More...
 
static const unsigned NULL_NORM_CODE = MAX_VALID_NORM_CODE + 1
 Null normal code. More...
 

Detailed Description

Normal compressor.

Definition at line 16 of file ecvNormalCompressor.h.

Member Function Documentation

◆ Compress()

static unsigned ccNormalCompressor::Compress ( const PointCoordinateType  N[3])
static

Compression algorithm.

◆ Decompress()

static void ccNormalCompressor::Decompress ( unsigned  index,
PointCoordinateType  N[3],
unsigned char  level = QUANTIZE_LEVEL 
)
static

Decompression algorithm.

◆ InvertNormal()

static void ccNormalCompressor::InvertNormal ( CompressedNormType code)
static

Inverts a (compressed) normal.

Member Data Documentation

◆ MAX_VALID_NORM_CODE

const unsigned ccNormalCompressor::MAX_VALID_NORM_CODE
static
Initial value:
=
(1 << (QUANTIZE_LEVEL * 2 + 3)) - 1
static const unsigned char QUANTIZE_LEVEL
Compressed normals quantization level (number of directions: 2^(2*N+3))

Last valid normal code.

Definition at line 25 of file ecvNormalCompressor.h.

◆ NULL_NORM_CODE

const unsigned ccNormalCompressor::NULL_NORM_CODE = MAX_VALID_NORM_CODE + 1
static

Null normal code.

Definition at line 28 of file ecvNormalCompressor.h.

◆ QUANTIZE_LEVEL

const unsigned char ccNormalCompressor::QUANTIZE_LEVEL
static
Initial value:
=
9

Compressed normals quantization level (number of directions: 2^(2*N+3))

Warning
Never pass a 'constant initializer' by reference

Definition at line 21 of file ecvNormalCompressor.h.


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