lsst.sphgeom gd90a20c951+052faf71bd
Loading...
Searching...
No Matches
Functions
codec.h File Reference

This file contains simple helper functions for encoding and decoding primitive types to/from byte strings. More...

#include <vector>

Go to the source code of this file.

Functions

void lsst::sphgeom::encodeDouble (double item, std::vector< uint8_t > &buffer)
 
double lsst::sphgeom::decodeDouble (uint8_t const *buffer)
 

Detailed Description

This file contains simple helper functions for encoding and decoding primitive types to/from byte strings.

Function Documentation

◆ decodeDouble()

double lsst::sphgeom::decodeDouble ( uint8_t const *  buffer)
inline

decode extracts an IEEE double from the 8 byte little-endian byte sequence in buffer.

◆ encodeDouble()

void lsst::sphgeom::encodeDouble ( double  item,
std::vector< uint8_t > &  buffer 
)
inline

encode appends an IEEE double in little-endian byte order to the end of buffer.