1
0
mirror of https://github.com/tumic0/GPXSee.git synced 2024-11-28 21:51:17 +01:00
GPXSee/src/map/IMG/huffmanstream.cpp

44 lines
623 B
C++
Raw Normal View History

#include "huffmanstream.h"
2021-04-10 15:27:40 +02:00
using namespace IMG;
2021-11-04 23:01:33 +01:00
bool HuffmanDeltaStreamF::init(bool line)
{
if (line) {
if (!(sign(_lonSign) && sign(_latSign)))
return false;
} else {
_lonSign = 0;
_latSign = 0;
}
quint32 eb;
2021-11-04 23:01:33 +01:00
if (!read(1, eb))
return false;
2020-09-29 22:03:26 +02:00
Q_ASSERT(!eb);
if (eb)
return false;
return true;
}
2021-11-04 23:01:33 +01:00
bool HuffmanDeltaStreamR::init()
{
if (!(sign(_lonSign) && sign(_latSign)))
2020-02-02 09:03:35 +01:00
return false;
return true;
}
2020-09-18 20:56:00 +02:00
2021-11-04 23:01:33 +01:00
bool HuffmanDeltaStreamR::init(quint32 data, quint32 dataSize)
2020-09-18 20:56:00 +02:00
{
_symbolData = data;
_symbolDataSize = dataSize;
2021-11-04 23:01:33 +01:00
if (!(sign(_lonSign) && sign(_latSign)))
return false;
2020-09-18 20:56:00 +02:00
return true;
}