mirror of
https://github.com/tumic0/GPXSee.git
synced 2024-11-24 03:35:53 +01:00
Compare commits
2 Commits
09d0b281c2
...
c4b85ef493
Author | SHA1 | Date | |
---|---|---|---|
c4b85ef493 | |||
c425be3741 |
8
.github/workflows/codeql.yml
vendored
8
.github/workflows/codeql.yml
vendored
@ -18,7 +18,7 @@ jobs:
|
||||
|
||||
steps:
|
||||
- name: Checkout repository
|
||||
uses: actions/checkout@v3
|
||||
uses: actions/checkout@v4
|
||||
|
||||
- name: Install dependencies
|
||||
run: |
|
||||
@ -26,7 +26,7 @@ jobs:
|
||||
sudo apt-get install qtbase5-dev qtbase5-private-dev qtbase5-dev-tools qt5-qmake qttools5-dev-tools libqt5opengl5-dev qtpositioning5-dev libqt5svg5-dev libqt5serialport5-dev
|
||||
|
||||
- name: Initialize CodeQL
|
||||
uses: github/codeql-action/init@v2
|
||||
uses: github/codeql-action/init@v3
|
||||
with:
|
||||
languages: ${{ matrix.language }}
|
||||
# If you wish to specify custom queries, you can do so here or in a config file.
|
||||
@ -37,9 +37,9 @@ jobs:
|
||||
# queries: security-extended,security-and-quality
|
||||
|
||||
- name: Autobuild
|
||||
uses: github/codeql-action/autobuild@v2
|
||||
uses: github/codeql-action/autobuild@v3
|
||||
|
||||
- name: Perform CodeQL Analysis
|
||||
uses: github/codeql-action/analyze@v2
|
||||
uses: github/codeql-action/analyze@v3
|
||||
with:
|
||||
category: "/language:${{matrix.language}}"
|
||||
|
@ -16,15 +16,15 @@ static const quint8 Z[] = {
|
||||
1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1
|
||||
};
|
||||
|
||||
static const int J[] = {
|
||||
static const quint8 J[] = {
|
||||
0, 0, 0, 0, 1, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3,
|
||||
4, 4, 5, 5, 6, 6, 7, 7, 8, 9, 10, 11, 12, 13, 14, 15
|
||||
};
|
||||
|
||||
JLS::JLS(quint16 diff, quint16 factor)
|
||||
JLS::JLS(quint16 maxval, quint16 near)
|
||||
{
|
||||
_maxval = diff;
|
||||
_near = factor;
|
||||
_maxval = maxval;
|
||||
_near = near;
|
||||
|
||||
_range = ((_maxval + _near * 2) / (_near * 2 + 1)) + 1;
|
||||
_qbpp = ceil(log2(_range));
|
||||
@ -189,16 +189,18 @@ bool JLS::readLine(BitStream &bs)
|
||||
else
|
||||
_b[1] = -((1 - _b[1]) >> 1);
|
||||
_n[1] = 0x21;
|
||||
} else {
|
||||
} else
|
||||
_n[1] = _n[1] + 1;
|
||||
}
|
||||
|
||||
if (_b[1] <= -_n[1]) {
|
||||
_b[1] = _b[1] + _n[1];
|
||||
if (_b[1] <= -_n[1])
|
||||
_b[1] = 1 - _n[1];
|
||||
} else if (_b[1] > 0)
|
||||
_b[1] = ((_b[1] - _n[1]) >> 0xf) & (_b[1] - _n[1]);
|
||||
} else if (_b[1] > 0) {
|
||||
_b[1] = _b[1] - _n[1];
|
||||
if (_b[1] > 0)
|
||||
_b[1] = 0;
|
||||
}
|
||||
|
||||
Rc = Rb;
|
||||
Rb = _last[col + 1];
|
||||
|
@ -2,15 +2,15 @@
|
||||
#define IMG_JLS_H
|
||||
|
||||
#include <QVector>
|
||||
#include "bitstream.h"
|
||||
#include "map/matrix.h"
|
||||
#include "subfile.h"
|
||||
|
||||
namespace IMG {
|
||||
|
||||
class JLS
|
||||
{
|
||||
public:
|
||||
JLS(quint16 diff, quint16 factor);
|
||||
JLS(quint16 maxval, quint16 near);
|
||||
|
||||
bool decode(const SubFile *file, SubFile::Handle &hdl, Matrix<qint16> &img);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user