submodule
6
.gitmodules
vendored
@@ -1,9 +1,9 @@
|
|||||||
[submodule "android/extern/libvncserver"]
|
[submodule "android/extern/libvncserver"]
|
||||||
path = android/extern/libvncserver
|
path = android/extern/libvncserver
|
||||||
url = ../../gujjwal00/libvncserver.git
|
url = https://github.com/gujjwal00/libvncserver.git
|
||||||
[submodule "android/extern/libjpeg-turbo"]
|
[submodule "android/extern/libjpeg-turbo"]
|
||||||
path = android/extern/libjpeg-turbo
|
path = android/extern/libjpeg-turbo
|
||||||
url = ../../libjpeg-turbo/libjpeg-turbo.git
|
url = https://github.com/libjpeg-turbo/libjpeg-turbo.git
|
||||||
[submodule "android/extern/wolfssl"]
|
[submodule "android/extern/wolfssl"]
|
||||||
path = android/extern/wolfssl
|
path = android/extern/wolfssl
|
||||||
url = ../../wolfSSL/wolfssl.git
|
url = https://github.com/wolfSSL/wolfssl.git
|
||||||
|
|||||||
4
android/extern/libjpeg-turbo/.gitattributes
vendored
@@ -1,4 +0,0 @@
|
|||||||
/appveyor.yml export-ignore
|
|
||||||
/.gitattributes export-ignore
|
|
||||||
/.github export-ignore
|
|
||||||
*.ppm binary
|
|
||||||
@@ -1,95 +0,0 @@
|
|||||||
Contributing to libjpeg-turbo
|
|
||||||
=============================
|
|
||||||
|
|
||||||
libjpeg-turbo is a stable and mature product with a worldwide reach, it is an
|
|
||||||
ISO/ITU-T reference implementation of the JPEG standard, and its maintainer
|
|
||||||
does not earn a salary for maintaining it. Thus, not every code contribution
|
|
||||||
can or will be accepted into the libjpeg-turbo code base. In order to maximize
|
|
||||||
the chances that a code contribution is acceptable, please adhere to the
|
|
||||||
following guidelines:
|
|
||||||
|
|
||||||
1. If the code contribution is a bug fix, then please ensure that enough
|
|
||||||
information is provided so that the maintainer can readily reproduce and
|
|
||||||
document the bug. That information should include:
|
|
||||||
- A clear and concise description of the bug
|
|
||||||
- The steps and (if applicable) images necessary to reproduce the bug
|
|
||||||
- The compilers, operating systems, and CPUs with which the bug was
|
|
||||||
observed
|
|
||||||
- The versions of libjpeg-turbo with which the bug was observed
|
|
||||||
- If the bug is a regression, the specific commit that introduced the bug
|
|
||||||
(use `git bisect` to determine this)
|
|
||||||
|
|
||||||
2. If the code contribution will implement a major new feature, then please
|
|
||||||
contact the project maintainer (through a
|
|
||||||
[GitHub issue](https://github.com/libjpeg-turbo/libjpeg-turbo/issues/new),
|
|
||||||
[direct e-mail](https://libjpeg-turbo.org/About/Contact), or the
|
|
||||||
[libjpeg-turbo-devel mailing list](https://libjpeg-turbo.org/About/MailingLists))
|
|
||||||
prior to implementing the feature. In general, major new features that are
|
|
||||||
potentially disruptive to the quality of libjpeg-turbo are unlikely to be
|
|
||||||
accepted unless:
|
|
||||||
- The new feature is within the existing scope of libjpeg-turbo.
|
|
||||||
- The new feature has been thoroughly regression tested and benchmarked on
|
|
||||||
all of the supported platforms that are potentially affected by it.
|
|
||||||
- The new feature has been documented clearly and concisely in the change
|
|
||||||
log and (if applicable) the libjpeg and TurboJPEG API documentation and
|
|
||||||
man pages.
|
|
||||||
- The code implementing the new feature is formatted consistently with the
|
|
||||||
rest of the libjpeg-turbo code base (use
|
|
||||||
[checkstyle](https://github.com/libjpeg-turbo/checkstyle) to validate
|
|
||||||
this.)
|
|
||||||
- The new feature does not introduce new members into the exposed libjpeg
|
|
||||||
API structures (doing so would break backward ABI compatibility.)
|
|
||||||
- The new feature does not alter existing libjpeg-turbo usage or
|
|
||||||
development workflows.
|
|
||||||
- The code implementing the new feature is elegant, easily maintainable,
|
|
||||||
and causes the least possible amount of disruption to the libjpeg-turbo
|
|
||||||
code base.
|
|
||||||
- The new feature is based on the dev branch of the libjpeg-turbo
|
|
||||||
repository.
|
|
||||||
|
|
||||||
... OR ...
|
|
||||||
|
|
||||||
- Your organization is prepared to pay for the labor necessary to ensure
|
|
||||||
all of the above. Even the most well-written patches can still require
|
|
||||||
a significant amount of labor to clean up, test, and integrate. (See
|
|
||||||
above RE: the maintainer not earning a salary.)
|
|
||||||
|
|
||||||
Specific types of features that *will not* be accepted:
|
|
||||||
|
|
||||||
- Features that extend the scope of libjpeg-turbo to support image formats
|
|
||||||
other than DCT-based JPEG and JFIF
|
|
||||||
- Features that extend the scope of libjpeg-turbo to support image
|
|
||||||
processing algorithms that are not necessary for JPEG compression or
|
|
||||||
decompression
|
|
||||||
- Extensions to the JPEG format that have not been approved by the
|
|
||||||
appropriate standards bodies
|
|
||||||
- Non-trivial performance enhancements that have less than a 5% overall
|
|
||||||
impact on performance
|
|
||||||
|
|
||||||
3. If the code contribution is a build system enhancement, then please be
|
|
||||||
prepared to justify the enhancement. In general, build system enhancements
|
|
||||||
are unlikely to be accepted unless:
|
|
||||||
- The enhancement is potentially beneficial to a significant number of
|
|
||||||
upstream libjpeg-turbo users/developers. (If the enhancement is only
|
|
||||||
beneficial to a downstream project, then it does not belong here.)
|
|
||||||
- The enhancement has been tested with the following CMake versions:
|
|
||||||
- The earliest version of CMake that libjpeg-turbo currently supports
|
|
||||||
(refer to CMakeLists.txt)
|
|
||||||
- The most recent major version of CMake
|
|
||||||
- (if applicable) The earliest version of CMake with which the
|
|
||||||
enhancement can be used
|
|
||||||
- The enhancement has been tested on all of the major platforms (Mac,
|
|
||||||
Linux, Windows/Visual C++, Windows/MinGW) that are potentially affected
|
|
||||||
by it.
|
|
||||||
- The enhancement does not introduce new build system requirements or CMake
|
|
||||||
variables unless absolutely necessary.
|
|
||||||
- The enhancement does not alter existing libjpeg-turbo development
|
|
||||||
workflows.
|
|
||||||
|
|
||||||
Specific types of build system enhancements that *will not* be accepted:
|
|
||||||
|
|
||||||
- Enhancements that allow libjpeg-turbo to be built from a subdirectory
|
|
||||||
of a downstream repository. These enhancements are not maintainable in
|
|
||||||
the upstream libjpeg-turbo build system. Use the CMake
|
|
||||||
`ExternalProject_Add()` function instead.
|
|
||||||
- Enhancements that introduce new (non-CMake-based) build systems
|
|
||||||
@@ -1 +0,0 @@
|
|||||||
github: libjpeg-turbo
|
|
||||||
@@ -1,40 +0,0 @@
|
|||||||
---
|
|
||||||
name: Bug Report
|
|
||||||
about: Inform the libjpeg-turbo maintainer about unexpected, reproducible behavior
|
|
||||||
title: ''
|
|
||||||
labels: bug
|
|
||||||
assignees: dcommander
|
|
||||||
|
|
||||||
---
|
|
||||||
|
|
||||||
**Have you searched the existing issues (both open and closed) in the libjpeg-turbo issue tracker to ensure that this bug report is not a duplicate?**
|
|
||||||
|
|
||||||
|
|
||||||
**Does this bug report describe one of the [two known and unsolvable issues with the JPEG format](https://libjpeg-turbo.org/pmwiki/uploads/About/TwoIssueswiththeJPEGStandard.pdf)?**
|
|
||||||
|
|
||||||
|
|
||||||
**Clear and concise description of the bug:**
|
|
||||||
|
|
||||||
|
|
||||||
**Steps to reproduce the bug (using *only* libjpeg-turbo):**
|
|
||||||
|
|
||||||
|
|
||||||
**Image(s) needed in order to reproduce the bug (if applicable):**
|
|
||||||
|
|
||||||
|
|
||||||
**Expected behavior:**
|
|
||||||
|
|
||||||
|
|
||||||
**Observed behavior:**
|
|
||||||
|
|
||||||
|
|
||||||
**Platform(s) (compiler version, operating system version, CPU) on which the bug was observed:**
|
|
||||||
|
|
||||||
|
|
||||||
**libjpeg-turbo release(s), commit(s), or branch(es) in which the bug was observed (always test the tip of the main branch or the latest [stable pre-release](https://libjpeg-turbo.org/DeveloperInfo/PreReleases) to verify that the bug hasn't already been fixed):**
|
|
||||||
|
|
||||||
|
|
||||||
**If the bug is a regression, the specific commit that introduced the regression (use `git bisect` to determine this):**
|
|
||||||
|
|
||||||
|
|
||||||
**Additional information:**
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
---
|
|
||||||
name: Feature Request
|
|
||||||
about: Suggest new libjpeg-turbo functionality
|
|
||||||
title: ''
|
|
||||||
labels: enhancement
|
|
||||||
assignees: dcommander
|
|
||||||
|
|
||||||
---
|
|
||||||
@@ -1,194 +0,0 @@
|
|||||||
name: Build
|
|
||||||
|
|
||||||
on:
|
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- '**'
|
|
||||||
tags-ignore:
|
|
||||||
- '**'
|
|
||||||
pull_request:
|
|
||||||
workflow_dispatch:
|
|
||||||
|
|
||||||
jobs:
|
|
||||||
linux:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Set global environment variables
|
|
||||||
run: |
|
|
||||||
echo "BRANCH=${GITHUB_BASE_REF:-${GITHUB_REF#refs/heads/}}" >$GITHUB_ENV
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Set up build
|
|
||||||
run: |
|
|
||||||
mkdir -p $HOME/src/ljt.nightly
|
|
||||||
docker pull dcommander/buildljt:$BRANCH
|
|
||||||
git clone --depth=1 https://github.com/libjpeg-turbo/buildscripts.git -b $BRANCH $HOME/src/buildscripts
|
|
||||||
mkdir $HOME/rpmkeys
|
|
||||||
wget --no-check-certificate "http://www.libjpeg-turbo.org/key/LJTPR-GPG-KEY" -O $HOME/rpmkeys/LJTPR-GPG-KEY
|
|
||||||
- name: Configure GPG signing
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
run: |
|
|
||||||
sudo apt install -y gnupg1
|
|
||||||
printf "${{secrets.GPG_KEY}}" | base64 --decode | gpg1 --batch --import -
|
|
||||||
chmod 600 $HOME/.gnupg/gpg.conf
|
|
||||||
echo "GPG_KEY_NAME=\"${{secrets.GPG_KEY_NAME}}\"" >$HOME/src/buildscripts/gpgsign
|
|
||||||
echo "GPG_KEY_ID=${{secrets.GPG_KEY_ID}}" >>$HOME/src/buildscripts/gpgsign
|
|
||||||
echo "GPG_KEY_PASS=${{secrets.GPG_KEY_PASS}}" >>$HOME/src/buildscripts/gpgsign
|
|
||||||
- name: Build
|
|
||||||
run: |
|
|
||||||
docker run -v $HOME/src/ljt.nightly:/root/src/ljt.nightly -v $HOME/src/buildscripts:/root/src/buildscripts -v $GITHUB_WORKSPACE:/root/src/libjpeg-turbo -v $HOME/.gnupg:/root/.gnupg -v $HOME/rpmkeys:/rpmkeys -t dcommander/buildljt:$BRANCH bash -c "rpm --import /rpmkeys/LJTPR-GPG-KEY && ~/src/buildscripts/buildljt -d /root/src/libjpeg-turbo -v"
|
|
||||||
sudo chown -R runner:runner $HOME/src/ljt.nightly
|
|
||||||
mv $HOME/src/ljt.nightly/latest/log-${{github.job}}.txt $HOME/src/ljt.nightly/latest/files/
|
|
||||||
- name: Configure AWS
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
uses: aws-actions/configure-aws-credentials@v1
|
|
||||||
with:
|
|
||||||
aws-access-key-id: ${{secrets.AWS_ACCESS_KEY_ID}}
|
|
||||||
aws-secret-access-key: ${{secrets.AWS_SECRET_ACCESS_KEY}}
|
|
||||||
aws-region: ${{secrets.AWS_REGION}}
|
|
||||||
- name: Deploy
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
run: |
|
|
||||||
aws s3 sync --acl public-read --delete $HOME/src/ljt.nightly/latest/files/ s3://libjpeg-turbo-pr/${{env.BRANCH}}/${{github.job}}/
|
|
||||||
macos:
|
|
||||||
runs-on: macos-11
|
|
||||||
steps:
|
|
||||||
- name: Set global environment variables
|
|
||||||
run: |
|
|
||||||
echo "BRANCH=${GITHUB_BASE_REF:-${GITHUB_REF#refs/heads/}}" >$GITHUB_ENV
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Set up build
|
|
||||||
run: |
|
|
||||||
brew install yasm md5sha1sum
|
|
||||||
sudo xcode-select -s /Applications/Xcode_12.4.app
|
|
||||||
mkdir -p $HOME/src/ljt.nightly
|
|
||||||
git clone --depth=1 https://github.com/libjpeg-turbo/buildscripts.git -b $BRANCH $HOME/src/buildscripts
|
|
||||||
- name: Configure GPG signing
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
run: |
|
|
||||||
printf "${{secrets.GPG_KEY}}" | base64 --decode | gpg --batch --import -
|
|
||||||
echo "GPG_KEY_NAME=\"${{secrets.GPG_KEY_NAME}}\"" >$HOME/src/buildscripts/gpgsign
|
|
||||||
echo "GPG_KEY_ID=${{secrets.GPG_KEY_ID}}" >>$HOME/src/buildscripts/gpgsign
|
|
||||||
echo "GPG_KEY_PASS=${{secrets.GPG_KEY_PASS}}" >>$HOME/src/buildscripts/gpgsign
|
|
||||||
- name: Build
|
|
||||||
run: |
|
|
||||||
$HOME/src/buildscripts/buildljt -d $GITHUB_WORKSPACE -v
|
|
||||||
mv $HOME/src/ljt.nightly/latest/log-${{github.job}}.txt $HOME/src/ljt.nightly/latest/files/
|
|
||||||
- name: Configure AWS
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
uses: aws-actions/configure-aws-credentials@v1
|
|
||||||
with:
|
|
||||||
aws-access-key-id: ${{secrets.AWS_ACCESS_KEY_ID}}
|
|
||||||
aws-secret-access-key: ${{secrets.AWS_SECRET_ACCESS_KEY}}
|
|
||||||
aws-region: ${{secrets.AWS_REGION}}
|
|
||||||
- name: Deploy
|
|
||||||
if: ${{github.event_name != 'pull_request'}}
|
|
||||||
run: |
|
|
||||||
aws s3 sync --acl public-read --delete $HOME/src/ljt.nightly/latest/files/ s3://libjpeg-turbo-pr/${{env.BRANCH}}/${{github.job}}/
|
|
||||||
linux-asan-ubsan:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Set up build
|
|
||||||
run: |
|
|
||||||
sudo apt install -y nasm
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
ASAN_OPTIONS: "detect_leaks=1 symbolize=1"
|
|
||||||
CTEST_OUTPUT_ON_FAILURE: 1
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
pushd build
|
|
||||||
cmake -G"Unix Makefiles" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER=clang -DCMAKE_C_FLAGS_RELWITHDEBINFO="-O1 -g -fsanitize=address,undefined -fno-sanitize-recover=all -fno-omit-frame-pointer" -DENABLE_SHARED=0 ..
|
|
||||||
export NUMCPUS=`grep -c '^processor' /proc/cpuinfo`
|
|
||||||
make -j$NUMCPUS --load-average=$NUMCPUS
|
|
||||||
make test
|
|
||||||
JSIMD_FORCESSE2=1 make test
|
|
||||||
cmake -DFLOATTEST=no-fp-contract ..
|
|
||||||
JSIMD_FORCENONE=1 make test
|
|
||||||
popd
|
|
||||||
linux-12bit:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
CTEST_OUTPUT_ON_FAILURE: 1
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
pushd build
|
|
||||||
cmake -G"Unix Makefiles" -DWITH_12BIT=1 \
|
|
||||||
-DCMAKE_C_FLAGS='--std=gnu90 -Wall -Werror -Wextra -Wpedantic -pedantic-errors -Wdouble-promotion -Wformat-overflow=2 -Wformat-security -Wformat-signedness -Wformat-truncation=2 -Wformat-y2k -Wmissing-include-dirs -Wshift-overflow=2 -Wswitch-bool -Wno-unused-parameter -Wuninitialized -Wstrict-overflow=2 -Wstringop-overflow=4 -Wstringop-truncation -Wduplicated-branches -Wduplicated-cond -Wdeclaration-after-statement -Wshadow -Wunsafe-loop-optimizations -Wundef -Wcast-align -Wno-clobbered -Wjump-misses-init -Wno-sign-compare -Wlogical-op -Waggregate-return -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Wpacked -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -Wdisabled-optimization -Wno-overlength-strings' \
|
|
||||||
..
|
|
||||||
export NUMCPUS=`grep -c '^processor' /proc/cpuinfo`
|
|
||||||
make -j$NUMCPUS --load-average=$NUMCPUS
|
|
||||||
make test
|
|
||||||
popd
|
|
||||||
linux-jpeg7-x32:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Set up build
|
|
||||||
run: |
|
|
||||||
sudo apt update
|
|
||||||
sudo apt -y --install-recommends install libc6-dev-x32 nasm
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
CTEST_OUTPUT_ON_FAILURE: 1
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
pushd build
|
|
||||||
cmake -G"Unix Makefiles" -DWITH_JPEG7=1 -DCMAKE_C_FLAGS=-mx32 \
|
|
||||||
-DCMAKE_C_FLAGS='--std=gnu90 -Wall -Werror -Wextra -Wpedantic -pedantic-errors -Wdouble-promotion -Wformat-overflow=2 -Wformat-security -Wformat-signedness -Wformat-truncation=2 -Wformat-y2k -Wmissing-include-dirs -Wshift-overflow=2 -Wswitch-bool -Wno-unused-parameter -Wuninitialized -Wstrict-overflow=2 -Wstringop-overflow=4 -Wstringop-truncation -Wduplicated-branches -Wduplicated-cond -Wdeclaration-after-statement -Wshadow -Wunsafe-loop-optimizations -Wundef -Wcast-align -Wno-clobbered -Wjump-misses-init -Wno-sign-compare -Wlogical-op -Waggregate-return -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Wpacked -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -Wdisabled-optimization -Wno-overlength-strings' \
|
|
||||||
..
|
|
||||||
export NUMCPUS=`grep -c '^processor' /proc/cpuinfo`
|
|
||||||
make -j$NUMCPUS --load-average=$NUMCPUS
|
|
||||||
make test
|
|
||||||
JSIMD_FORCESSE2=1 make test
|
|
||||||
cmake -DFLOATTEST=no-fp-contract ..
|
|
||||||
JSIMD_FORCENONE=1 make test
|
|
||||||
popd
|
|
||||||
linux-jpeg8:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Set up build
|
|
||||||
run: |
|
|
||||||
sudo apt -y install nasm
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
CTEST_OUTPUT_ON_FAILURE: 1
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
pushd build
|
|
||||||
cmake -G"Unix Makefiles" -DWITH_JPEG8=1 \
|
|
||||||
-DCMAKE_C_FLAGS='--std=gnu90 -Wall -Werror -Wextra -Wpedantic -pedantic-errors -Wdouble-promotion -Wformat-overflow=2 -Wformat-security -Wformat-signedness -Wformat-truncation=2 -Wformat-y2k -Wmissing-include-dirs -Wshift-overflow=2 -Wswitch-bool -Wno-unused-parameter -Wuninitialized -Wstrict-overflow=2 -Wstringop-overflow=4 -Wstringop-truncation -Wduplicated-branches -Wduplicated-cond -Wdeclaration-after-statement -Wshadow -Wunsafe-loop-optimizations -Wundef -Wcast-align -Wno-clobbered -Wjump-misses-init -Wno-sign-compare -Wlogical-op -Waggregate-return -Wstrict-prototypes -Wold-style-definition -Wmissing-prototypes -Wmissing-declarations -Wpacked -Wredundant-decls -Wnested-externs -Winline -Wno-long-long -Wdisabled-optimization -Wno-overlength-strings' \
|
|
||||||
..
|
|
||||||
export NUMCPUS=`grep -c '^processor' /proc/cpuinfo`
|
|
||||||
make -j$NUMCPUS --load-average=$NUMCPUS
|
|
||||||
make test
|
|
||||||
JSIMD_FORCESSE2=1 make test
|
|
||||||
cmake -DFLOATTEST=no-fp-contract ..
|
|
||||||
JSIMD_FORCENONE=1 make test
|
|
||||||
popd
|
|
||||||
linux-msan:
|
|
||||||
runs-on: ubuntu-latest
|
|
||||||
steps:
|
|
||||||
- name: Check out code
|
|
||||||
uses: actions/checkout@v3
|
|
||||||
- name: Build
|
|
||||||
env:
|
|
||||||
CTEST_OUTPUT_ON_FAILURE: 1
|
|
||||||
run: |
|
|
||||||
mkdir build
|
|
||||||
pushd build
|
|
||||||
cmake -G"Unix Makefiles" -DCMAKE_BUILD_TYPE=RelWithDebInfo -DCMAKE_C_COMPILER=clang -DCMAKE_C_FLAGS_RELWITHDEBINFO="-O3 -g -fsanitize=memory -fno-sanitize-recover=all -fPIE" -DWITH_SIMD=0 ..
|
|
||||||
export NUMCPUS=`grep -c '^processor' /proc/cpuinfo`
|
|
||||||
make -j$NUMCPUS --load-average=$NUMCPUS
|
|
||||||
make test
|
|
||||||
popd
|
|
||||||
726
android/extern/libjpeg-turbo/BUILDING.md
vendored
@@ -1,726 +0,0 @@
|
|||||||
Building libjpeg-turbo
|
|
||||||
======================
|
|
||||||
|
|
||||||
|
|
||||||
Build Requirements
|
|
||||||
------------------
|
|
||||||
|
|
||||||
|
|
||||||
### All Systems
|
|
||||||
|
|
||||||
- [CMake](http://www.cmake.org) v2.8.12 or later
|
|
||||||
|
|
||||||
- [NASM](http://www.nasm.us) or [Yasm](http://yasm.tortall.net)
|
|
||||||
(if building x86 or x86-64 SIMD extensions)
|
|
||||||
* If using NASM, 2.13 or later is required.
|
|
||||||
* If using Yasm, 1.2.0 or later is required.
|
|
||||||
* If building on macOS, NASM or Yasm can be obtained from
|
|
||||||
[MacPorts](http://www.macports.org/) or [Homebrew](http://brew.sh/).
|
|
||||||
- NOTE: Currently, if it is desirable to hide the SIMD function symbols in
|
|
||||||
Mac executables or shared libraries that statically link with
|
|
||||||
libjpeg-turbo, then NASM 2.14 or later or Yasm must be used when
|
|
||||||
building libjpeg-turbo.
|
|
||||||
* If NASM or Yasm is not in your `PATH`, then you can specify the full path
|
|
||||||
to the assembler by using either the `CMAKE_ASM_NASM_COMPILER` CMake
|
|
||||||
variable or the `ASM_NASM` environment variable. On Windows, use forward
|
|
||||||
slashes rather than backslashes in the path (for example,
|
|
||||||
**c:/nasm/nasm.exe**).
|
|
||||||
* NASM and Yasm are located in the CRB (Code Ready Builder) or PowerTools
|
|
||||||
repository on Red Hat Enterprise Linux 8+ and derivatives, which is not
|
|
||||||
enabled by default.
|
|
||||||
|
|
||||||
### Un*x Platforms (including Linux, Mac, FreeBSD, Solaris, and Cygwin)
|
|
||||||
|
|
||||||
- GCC v4.1 (or later) or Clang recommended for best performance
|
|
||||||
|
|
||||||
- If building the TurboJPEG Java wrapper, JDK or OpenJDK 1.5 or later is
|
|
||||||
required. Most modern Linux distributions, as well as Solaris 10 and later,
|
|
||||||
include JDK or OpenJDK. For other systems, you can obtain the Oracle Java
|
|
||||||
Development Kit from
|
|
||||||
<http://www.oracle.com/technetwork/java/javase/downloads>.
|
|
||||||
|
|
||||||
* If using JDK 11 or later, CMake 3.10.x or later must also be used.
|
|
||||||
|
|
||||||
### Windows
|
|
||||||
|
|
||||||
- Microsoft Visual C++ 2005 or later
|
|
||||||
|
|
||||||
If you don't already have Visual C++, then the easiest way to get it is by
|
|
||||||
installing
|
|
||||||
[Visual Studio Community Edition](https://visualstudio.microsoft.com),
|
|
||||||
which includes everything necessary to build libjpeg-turbo.
|
|
||||||
|
|
||||||
* You can also download and install the standalone Windows SDK (for Windows 7
|
|
||||||
or later), which includes command-line versions of the 32-bit and 64-bit
|
|
||||||
Visual C++ compilers.
|
|
||||||
* If you intend to build libjpeg-turbo from the command line, then add the
|
|
||||||
appropriate compiler and SDK directories to the `INCLUDE`, `LIB`, and
|
|
||||||
`PATH` environment variables. This is generally accomplished by
|
|
||||||
executing `vcvars32.bat` or `vcvars64.bat`, which are located in the same
|
|
||||||
directory as the compiler.
|
|
||||||
* If built with Visual C++ 2015 or later, the libjpeg-turbo static libraries
|
|
||||||
cannot be used with earlier versions of Visual C++, and vice versa.
|
|
||||||
* The libjpeg API DLL (**jpeg{version}.dll**) will depend on the C run-time
|
|
||||||
DLLs corresponding to the version of Visual C++ that was used to build it.
|
|
||||||
|
|
||||||
... OR ...
|
|
||||||
|
|
||||||
- MinGW
|
|
||||||
|
|
||||||
[MSYS2](http://msys2.github.io/) or [tdm-gcc](http://tdm-gcc.tdragon.net/)
|
|
||||||
recommended if building on a Windows machine. Both distributions install a
|
|
||||||
Start Menu link that can be used to launch a command prompt with the
|
|
||||||
appropriate compiler paths automatically set.
|
|
||||||
|
|
||||||
- If building the TurboJPEG Java wrapper, JDK 1.5 or later is required. This
|
|
||||||
can be downloaded from
|
|
||||||
<http://www.oracle.com/technetwork/java/javase/downloads>.
|
|
||||||
|
|
||||||
* If using JDK 11 or later, CMake 3.10.x or later must also be used.
|
|
||||||
|
|
||||||
|
|
||||||
Sub-Project Builds
|
|
||||||
------------------
|
|
||||||
|
|
||||||
The libjpeg-turbo build system does not support being included as a sub-project
|
|
||||||
using the CMake `add_subdirectory()` function. Use the CMake
|
|
||||||
`ExternalProject_Add()` function instead.
|
|
||||||
|
|
||||||
|
|
||||||
Out-of-Tree Builds
|
|
||||||
------------------
|
|
||||||
|
|
||||||
Binary objects, libraries, and executables are generated in the directory from
|
|
||||||
which CMake is executed (the "binary directory"), and this directory need not
|
|
||||||
necessarily be the same as the libjpeg-turbo source directory. You can create
|
|
||||||
multiple independent binary directories, in which different versions of
|
|
||||||
libjpeg-turbo can be built from the same source tree using different compilers
|
|
||||||
or settings. In the sections below, *{build_directory}* refers to the binary
|
|
||||||
directory, whereas *{source_directory}* refers to the libjpeg-turbo source
|
|
||||||
directory. For in-tree builds, these directories are the same.
|
|
||||||
|
|
||||||
|
|
||||||
Ninja
|
|
||||||
-----
|
|
||||||
|
|
||||||
If using Ninja, then replace `make` or `nmake` with `ninja`, and replace the
|
|
||||||
CMake generator (specified with the `-G` option) with `Ninja`, in all of the
|
|
||||||
procedures and recipes below.
|
|
||||||
|
|
||||||
|
|
||||||
Build Procedure
|
|
||||||
---------------
|
|
||||||
|
|
||||||
NOTE: The build procedures below assume that CMake is invoked from the command
|
|
||||||
line, but all of these procedures can be adapted to the CMake GUI as
|
|
||||||
well.
|
|
||||||
|
|
||||||
|
|
||||||
### Un*x
|
|
||||||
|
|
||||||
The following procedure will build libjpeg-turbo on Unix and Unix-like systems.
|
|
||||||
(On Solaris, this generates a 32-bit build. See "Build Recipes" below for
|
|
||||||
64-bit build instructions.)
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" [additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
This will generate the following files under *{build_directory}*:
|
|
||||||
|
|
||||||
**libjpeg.a**<br>
|
|
||||||
Static link library for the libjpeg API
|
|
||||||
|
|
||||||
**libjpeg.so.{version}** (Linux, Unix)<br>
|
|
||||||
**libjpeg.{version}.dylib** (Mac)<br>
|
|
||||||
**cygjpeg-{version}.dll** (Cygwin)<br>
|
|
||||||
Shared library for the libjpeg API
|
|
||||||
|
|
||||||
By default, *{version}* is 62.2.0, 7.2.0, or 8.1.2, depending on whether
|
|
||||||
libjpeg v6b (default), v7, or v8 emulation is enabled. If using Cygwin,
|
|
||||||
*{version}* is 62, 7, or 8.
|
|
||||||
|
|
||||||
**libjpeg.so** (Linux, Unix)<br>
|
|
||||||
**libjpeg.dylib** (Mac)<br>
|
|
||||||
Development symlink for the libjpeg API
|
|
||||||
|
|
||||||
**libjpeg.dll.a** (Cygwin)<br>
|
|
||||||
Import library for the libjpeg API
|
|
||||||
|
|
||||||
**libturbojpeg.a**<br>
|
|
||||||
Static link library for the TurboJPEG API
|
|
||||||
|
|
||||||
**libturbojpeg.so.0.2.0** (Linux, Unix)<br>
|
|
||||||
**libturbojpeg.0.2.0.dylib** (Mac)<br>
|
|
||||||
**cygturbojpeg-0.dll** (Cygwin)<br>
|
|
||||||
Shared library for the TurboJPEG API
|
|
||||||
|
|
||||||
**libturbojpeg.so** (Linux, Unix)<br>
|
|
||||||
**libturbojpeg.dylib** (Mac)<br>
|
|
||||||
Development symlink for the TurboJPEG API
|
|
||||||
|
|
||||||
**libturbojpeg.dll.a** (Cygwin)<br>
|
|
||||||
Import library for the TurboJPEG API
|
|
||||||
|
|
||||||
|
|
||||||
### Visual C++ (Command Line)
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"NMake Makefiles" -DCMAKE_BUILD_TYPE=Release [additional CMake flags] {source_directory}
|
|
||||||
nmake
|
|
||||||
|
|
||||||
This will build either a 32-bit or a 64-bit version of libjpeg-turbo, depending
|
|
||||||
on which version of **cl.exe** is in the `PATH`.
|
|
||||||
|
|
||||||
The following files will be generated under *{build_directory}*:
|
|
||||||
|
|
||||||
**jpeg-static.lib**<br>
|
|
||||||
Static link library for the libjpeg API
|
|
||||||
|
|
||||||
**jpeg{version}.dll**<br>
|
|
||||||
DLL for the libjpeg API
|
|
||||||
|
|
||||||
**jpeg.lib**<br>
|
|
||||||
Import library for the libjpeg API
|
|
||||||
|
|
||||||
**turbojpeg-static.lib**<br>
|
|
||||||
Static link library for the TurboJPEG API
|
|
||||||
|
|
||||||
**turbojpeg.dll**<br>
|
|
||||||
DLL for the TurboJPEG API
|
|
||||||
|
|
||||||
**turbojpeg.lib**<br>
|
|
||||||
Import library for the TurboJPEG API
|
|
||||||
|
|
||||||
*{version}* is 62, 7, or 8, depending on whether libjpeg v6b (default), v7, or
|
|
||||||
v8 emulation is enabled.
|
|
||||||
|
|
||||||
|
|
||||||
### Visual C++ (IDE)
|
|
||||||
|
|
||||||
Choose the appropriate CMake generator option for your version of Visual Studio
|
|
||||||
(run `cmake` with no arguments for a list of available generators.) For
|
|
||||||
instance:
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Visual Studio 10" [additional CMake flags] {source_directory}
|
|
||||||
|
|
||||||
NOTE: Add "Win64" to the generator name (for example, "Visual Studio 10 Win64")
|
|
||||||
to build a 64-bit version of libjpeg-turbo. A separate build directory must be
|
|
||||||
used for 32-bit and 64-bit builds.
|
|
||||||
|
|
||||||
You can then open **ALL_BUILD.vcproj** in Visual Studio and build one of the
|
|
||||||
configurations in that project ("Debug", "Release", etc.) to generate a full
|
|
||||||
build of libjpeg-turbo.
|
|
||||||
|
|
||||||
This will generate the following files under *{build_directory}*:
|
|
||||||
|
|
||||||
**{configuration}/jpeg-static.lib**<br>
|
|
||||||
Static link library for the libjpeg API
|
|
||||||
|
|
||||||
**{configuration}/jpeg{version}.dll**<br>
|
|
||||||
DLL for the libjpeg API
|
|
||||||
|
|
||||||
**{configuration}/jpeg.lib**<br>
|
|
||||||
Import library for the libjpeg API
|
|
||||||
|
|
||||||
**{configuration}/turbojpeg-static.lib**<br>
|
|
||||||
Static link library for the TurboJPEG API
|
|
||||||
|
|
||||||
**{configuration}/turbojpeg.dll**<br>
|
|
||||||
DLL for the TurboJPEG API
|
|
||||||
|
|
||||||
**{configuration}/turbojpeg.lib**<br>
|
|
||||||
Import library for the TurboJPEG API
|
|
||||||
|
|
||||||
*{configuration}* is Debug, Release, RelWithDebInfo, or MinSizeRel, depending
|
|
||||||
on the configuration you built in the IDE, and *{version}* is 62, 7, or 8,
|
|
||||||
depending on whether libjpeg v6b (default), v7, or v8 emulation is enabled.
|
|
||||||
|
|
||||||
|
|
||||||
### MinGW
|
|
||||||
|
|
||||||
NOTE: This assumes that you are building on a Windows machine using the MSYS
|
|
||||||
environment. If you are cross-compiling on a Un*x platform (including Mac and
|
|
||||||
Cygwin), then see "Build Recipes" below.
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"MSYS Makefiles" [additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
This will generate the following files under *{build_directory}*:
|
|
||||||
|
|
||||||
**libjpeg.a**<br>
|
|
||||||
Static link library for the libjpeg API
|
|
||||||
|
|
||||||
**libjpeg-{version}.dll**<br>
|
|
||||||
DLL for the libjpeg API
|
|
||||||
|
|
||||||
**libjpeg.dll.a**<br>
|
|
||||||
Import library for the libjpeg API
|
|
||||||
|
|
||||||
**libturbojpeg.a**<br>
|
|
||||||
Static link library for the TurboJPEG API
|
|
||||||
|
|
||||||
**libturbojpeg.dll**<br>
|
|
||||||
DLL for the TurboJPEG API
|
|
||||||
|
|
||||||
**libturbojpeg.dll.a**<br>
|
|
||||||
Import library for the TurboJPEG API
|
|
||||||
|
|
||||||
*{version}* is 62, 7, or 8, depending on whether libjpeg v6b (default), v7, or
|
|
||||||
v8 emulation is enabled.
|
|
||||||
|
|
||||||
|
|
||||||
### Debug Build
|
|
||||||
|
|
||||||
Add `-DCMAKE_BUILD_TYPE=Debug` to the CMake command line. Or, if building
|
|
||||||
with NMake, remove `-DCMAKE_BUILD_TYPE=Release` (Debug builds are the default
|
|
||||||
with NMake.)
|
|
||||||
|
|
||||||
|
|
||||||
### libjpeg v7 or v8 API/ABI Emulation
|
|
||||||
|
|
||||||
Add `-DWITH_JPEG7=1` to the CMake command line to build a version of
|
|
||||||
libjpeg-turbo that is API/ABI-compatible with libjpeg v7. Add `-DWITH_JPEG8=1`
|
|
||||||
to the CMake command line to build a version of libjpeg-turbo that is
|
|
||||||
API/ABI-compatible with libjpeg v8. See [README.md](README.md) for more
|
|
||||||
information about libjpeg v7 and v8 emulation.
|
|
||||||
|
|
||||||
|
|
||||||
### In-Memory Source/Destination Managers
|
|
||||||
|
|
||||||
When using libjpeg v6b or v7 API/ABI emulation, add `-DWITH_MEM_SRCDST=0` to
|
|
||||||
the CMake command line to build a version of libjpeg-turbo that lacks the
|
|
||||||
`jpeg_mem_src()` and `jpeg_mem_dest()` functions. These functions were not
|
|
||||||
part of the original libjpeg v6b and v7 APIs, so removing them ensures strict
|
|
||||||
conformance with those APIs. See [README.md](README.md) for more information.
|
|
||||||
|
|
||||||
|
|
||||||
### Arithmetic Coding Support
|
|
||||||
|
|
||||||
Since the patent on arithmetic coding has expired, this functionality has been
|
|
||||||
included in this release of libjpeg-turbo. libjpeg-turbo's implementation is
|
|
||||||
based on the implementation in libjpeg v8, but it works when emulating libjpeg
|
|
||||||
v7 or v6b as well. The default is to enable both arithmetic encoding and
|
|
||||||
decoding, but those who have philosophical objections to arithmetic coding can
|
|
||||||
add `-DWITH_ARITH_ENC=0` or `-DWITH_ARITH_DEC=0` to the CMake command line to
|
|
||||||
disable encoding or decoding (respectively.)
|
|
||||||
|
|
||||||
|
|
||||||
### TurboJPEG Java Wrapper
|
|
||||||
|
|
||||||
Add `-DWITH_JAVA=1` to the CMake command line to incorporate an optional Java
|
|
||||||
Native Interface (JNI) wrapper into the TurboJPEG shared library and build the
|
|
||||||
Java front-end classes to support it. This allows the TurboJPEG shared library
|
|
||||||
to be used directly from Java applications. See [java/README](java/README) for
|
|
||||||
more details.
|
|
||||||
|
|
||||||
If Java is not in your `PATH`, or if you wish to use an alternate JDK to
|
|
||||||
build/test libjpeg-turbo, then (prior to running CMake) set the `JAVA_HOME`
|
|
||||||
environment variable to the location of the JDK that you wish to use. The
|
|
||||||
`Java_JAVAC_EXECUTABLE`, `Java_JAVA_EXECUTABLE`, and `Java_JAR_EXECUTABLE`
|
|
||||||
CMake variables can also be used to specify alternate commands or locations for
|
|
||||||
javac, jar, and java (respectively.) You can also set the
|
|
||||||
`CMAKE_JAVA_COMPILE_FLAGS` CMake variable or the `JAVAFLAGS` environment
|
|
||||||
variable to specify arguments that should be passed to the Java compiler when
|
|
||||||
building the TurboJPEG classes, and the `JAVAARGS` CMake variable to specify
|
|
||||||
arguments that should be passed to the JRE when running the TurboJPEG Java unit
|
|
||||||
tests.
|
|
||||||
|
|
||||||
|
|
||||||
Build Recipes
|
|
||||||
-------------
|
|
||||||
|
|
||||||
|
|
||||||
### 32-bit Build on 64-bit Linux/Unix
|
|
||||||
|
|
||||||
Use export/setenv to set the following environment variables before running
|
|
||||||
CMake:
|
|
||||||
|
|
||||||
CFLAGS=-m32
|
|
||||||
LDFLAGS=-m32
|
|
||||||
|
|
||||||
|
|
||||||
### 64-bit Build on Solaris
|
|
||||||
|
|
||||||
Use export/setenv to set the following environment variables before running
|
|
||||||
CMake:
|
|
||||||
|
|
||||||
CFLAGS=-m64
|
|
||||||
LDFLAGS=-m64
|
|
||||||
|
|
||||||
|
|
||||||
### Other Compilers
|
|
||||||
|
|
||||||
On Un*x systems, prior to running CMake, you can set the `CC` environment
|
|
||||||
variable to the command used to invoke the C compiler.
|
|
||||||
|
|
||||||
|
|
||||||
### 32-bit MinGW Build on Un*x (including Mac and Cygwin)
|
|
||||||
|
|
||||||
Create a file called **toolchain.cmake** under *{build_directory}*, with the
|
|
||||||
following contents:
|
|
||||||
|
|
||||||
set(CMAKE_SYSTEM_NAME Windows)
|
|
||||||
set(CMAKE_SYSTEM_PROCESSOR X86)
|
|
||||||
set(CMAKE_C_COMPILER {mingw_binary_path}/i686-w64-mingw32-gcc)
|
|
||||||
set(CMAKE_RC_COMPILER {mingw_binary_path}/i686-w64-mingw32-windres)
|
|
||||||
|
|
||||||
*{mingw\_binary\_path}* is the directory under which the MinGW binaries are
|
|
||||||
located (usually **/usr/bin**.) Next, execute the following commands:
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain.cmake \
|
|
||||||
-DCMAKE_INSTALL_PREFIX={install_path} \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
*{install\_path}* is the path under which the libjpeg-turbo binaries should be
|
|
||||||
installed.
|
|
||||||
|
|
||||||
|
|
||||||
### 64-bit MinGW Build on Un*x (including Mac and Cygwin)
|
|
||||||
|
|
||||||
Create a file called **toolchain.cmake** under *{build_directory}*, with the
|
|
||||||
following contents:
|
|
||||||
|
|
||||||
set(CMAKE_SYSTEM_NAME Windows)
|
|
||||||
set(CMAKE_SYSTEM_PROCESSOR AMD64)
|
|
||||||
set(CMAKE_C_COMPILER {mingw_binary_path}/x86_64-w64-mingw32-gcc)
|
|
||||||
set(CMAKE_RC_COMPILER {mingw_binary_path}/x86_64-w64-mingw32-windres)
|
|
||||||
|
|
||||||
*{mingw\_binary\_path}* is the directory under which the MinGW binaries are
|
|
||||||
located (usually **/usr/bin**.) Next, execute the following commands:
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain.cmake \
|
|
||||||
-DCMAKE_INSTALL_PREFIX={install_path} \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
*{install\_path}* is the path under which the libjpeg-turbo binaries should be
|
|
||||||
installed.
|
|
||||||
|
|
||||||
|
|
||||||
Building libjpeg-turbo for iOS
|
|
||||||
------------------------------
|
|
||||||
|
|
||||||
iOS platforms, such as the iPhone and iPad, use Arm processors, and all
|
|
||||||
currently supported models include Neon instructions. Thus, they can take
|
|
||||||
advantage of libjpeg-turbo's SIMD extensions to significantly accelerate JPEG
|
|
||||||
compression/decompression. This section describes how to build libjpeg-turbo
|
|
||||||
for these platforms.
|
|
||||||
|
|
||||||
|
|
||||||
### Armv8 (64-bit)
|
|
||||||
|
|
||||||
**Xcode 5 or later required, Xcode 6.3.x or later recommended**
|
|
||||||
|
|
||||||
The following script demonstrates how to build libjpeg-turbo to run on the
|
|
||||||
iPhone 5S/iPad Mini 2/iPad Air and newer.
|
|
||||||
|
|
||||||
IOS_PLATFORMDIR=/Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform
|
|
||||||
IOS_SYSROOT=($IOS_PLATFORMDIR/Developer/SDKs/iPhoneOS*.sdk)
|
|
||||||
export CFLAGS="-Wall -arch arm64 -miphoneos-version-min=8.0 -funwind-tables"
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
|
|
||||||
cat <<EOF >toolchain.cmake
|
|
||||||
set(CMAKE_SYSTEM_NAME Darwin)
|
|
||||||
set(CMAKE_SYSTEM_PROCESSOR aarch64)
|
|
||||||
set(CMAKE_C_COMPILER /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang)
|
|
||||||
EOF
|
|
||||||
|
|
||||||
cmake -G"Unix Makefiles" -DCMAKE_TOOLCHAIN_FILE=toolchain.cmake \
|
|
||||||
-DCMAKE_OSX_SYSROOT=${IOS_SYSROOT[0]} \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
Replace `iPhoneOS` with `iPhoneSimulator` and `-miphoneos-version-min` with
|
|
||||||
`-miphonesimulator-version-min` to build libjpeg-turbo for the iOS simulator on
|
|
||||||
Macs with Apple silicon CPUs.
|
|
||||||
|
|
||||||
|
|
||||||
Building libjpeg-turbo for Android
|
|
||||||
----------------------------------
|
|
||||||
|
|
||||||
Building libjpeg-turbo for Android platforms requires v13b or later of the
|
|
||||||
[Android NDK](https://developer.android.com/tools/sdk/ndk).
|
|
||||||
|
|
||||||
|
|
||||||
### Armv7 (32-bit)
|
|
||||||
|
|
||||||
**NDK r19 or later with Clang recommended**
|
|
||||||
|
|
||||||
The following is a general recipe script that can be modified for your specific
|
|
||||||
needs.
|
|
||||||
|
|
||||||
# Set these variables to suit your needs
|
|
||||||
NDK_PATH={full path to the NDK directory-- for example,
|
|
||||||
/opt/android/android-ndk-r16b}
|
|
||||||
TOOLCHAIN={"gcc" or "clang"-- "gcc" must be used with NDK r16b and earlier,
|
|
||||||
and "clang" must be used with NDK r17c and later}
|
|
||||||
ANDROID_VERSION={the minimum version of Android to support-- for example,
|
|
||||||
"16", "19", etc.}
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" \
|
|
||||||
-DANDROID_ABI=armeabi-v7a \
|
|
||||||
-DANDROID_ARM_MODE=arm \
|
|
||||||
-DANDROID_PLATFORM=android-${ANDROID_VERSION} \
|
|
||||||
-DANDROID_TOOLCHAIN=${TOOLCHAIN} \
|
|
||||||
-DCMAKE_ASM_FLAGS="--target=arm-linux-androideabi${ANDROID_VERSION}" \
|
|
||||||
-DCMAKE_TOOLCHAIN_FILE=${NDK_PATH}/build/cmake/android.toolchain.cmake \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
|
|
||||||
### Armv8 (64-bit)
|
|
||||||
|
|
||||||
**Clang recommended**
|
|
||||||
|
|
||||||
The following is a general recipe script that can be modified for your specific
|
|
||||||
needs.
|
|
||||||
|
|
||||||
# Set these variables to suit your needs
|
|
||||||
NDK_PATH={full path to the NDK directory-- for example,
|
|
||||||
/opt/android/android-ndk-r16b}
|
|
||||||
TOOLCHAIN={"gcc" or "clang"-- "gcc" must be used with NDK r14b and earlier,
|
|
||||||
and "clang" must be used with NDK r17c and later}
|
|
||||||
ANDROID_VERSION={the minimum version of Android to support. "21" or later
|
|
||||||
is required for a 64-bit build.}
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" \
|
|
||||||
-DANDROID_ABI=arm64-v8a \
|
|
||||||
-DANDROID_ARM_MODE=arm \
|
|
||||||
-DANDROID_PLATFORM=android-${ANDROID_VERSION} \
|
|
||||||
-DANDROID_TOOLCHAIN=${TOOLCHAIN} \
|
|
||||||
-DCMAKE_ASM_FLAGS="--target=aarch64-linux-android${ANDROID_VERSION}" \
|
|
||||||
-DCMAKE_TOOLCHAIN_FILE=${NDK_PATH}/build/cmake/android.toolchain.cmake \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
|
|
||||||
### x86 (32-bit)
|
|
||||||
|
|
||||||
The following is a general recipe script that can be modified for your specific
|
|
||||||
needs.
|
|
||||||
|
|
||||||
# Set these variables to suit your needs
|
|
||||||
NDK_PATH={full path to the NDK directory-- for example,
|
|
||||||
/opt/android/android-ndk-r16b}
|
|
||||||
TOOLCHAIN={"gcc" or "clang"-- "gcc" must be used with NDK r14b and earlier,
|
|
||||||
and "clang" must be used with NDK r17c and later}
|
|
||||||
ANDROID_VERSION={The minimum version of Android to support-- for example,
|
|
||||||
"16", "19", etc.}
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" \
|
|
||||||
-DANDROID_ABI=x86 \
|
|
||||||
-DANDROID_PLATFORM=android-${ANDROID_VERSION} \
|
|
||||||
-DANDROID_TOOLCHAIN=${TOOLCHAIN} \
|
|
||||||
-DCMAKE_TOOLCHAIN_FILE=${NDK_PATH}/build/cmake/android.toolchain.cmake \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
|
|
||||||
### x86-64 (64-bit)
|
|
||||||
|
|
||||||
The following is a general recipe script that can be modified for your specific
|
|
||||||
needs.
|
|
||||||
|
|
||||||
# Set these variables to suit your needs
|
|
||||||
NDK_PATH={full path to the NDK directory-- for example,
|
|
||||||
/opt/android/android-ndk-r16b}
|
|
||||||
TOOLCHAIN={"gcc" or "clang"-- "gcc" must be used with NDK r14b and earlier,
|
|
||||||
and "clang" must be used with NDK r17c and later}
|
|
||||||
ANDROID_VERSION={the minimum version of Android to support. "21" or later
|
|
||||||
is required for a 64-bit build.}
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
cmake -G"Unix Makefiles" \
|
|
||||||
-DANDROID_ABI=x86_64 \
|
|
||||||
-DANDROID_PLATFORM=android-${ANDROID_VERSION} \
|
|
||||||
-DANDROID_TOOLCHAIN=${TOOLCHAIN} \
|
|
||||||
-DCMAKE_TOOLCHAIN_FILE=${NDK_PATH}/build/cmake/android.toolchain.cmake \
|
|
||||||
[additional CMake flags] {source_directory}
|
|
||||||
make
|
|
||||||
|
|
||||||
|
|
||||||
Advanced CMake Options
|
|
||||||
----------------------
|
|
||||||
|
|
||||||
To list and configure other CMake options not specifically mentioned in this
|
|
||||||
guide, run
|
|
||||||
|
|
||||||
ccmake {source_directory}
|
|
||||||
|
|
||||||
or
|
|
||||||
|
|
||||||
cmake-gui {source_directory}
|
|
||||||
|
|
||||||
from the build directory after initially configuring the build. CCMake is a
|
|
||||||
text-based interactive version of CMake, and CMake-GUI is a GUI version. Both
|
|
||||||
will display all variables that are relevant to the libjpeg-turbo build, their
|
|
||||||
current values, and a help string describing what they do.
|
|
||||||
|
|
||||||
|
|
||||||
Installing libjpeg-turbo
|
|
||||||
========================
|
|
||||||
|
|
||||||
You can use the build system to install libjpeg-turbo (as opposed to creating
|
|
||||||
an installer package.) To do this, run `make install` or `nmake install`
|
|
||||||
(or build the "install" target in the Visual Studio IDE.) Running
|
|
||||||
`make uninstall` or `nmake uninstall` (or building the "uninstall" target in
|
|
||||||
the Visual Studio IDE) will uninstall libjpeg-turbo.
|
|
||||||
|
|
||||||
The `CMAKE_INSTALL_PREFIX` CMake variable can be modified in order to install
|
|
||||||
libjpeg-turbo into a directory of your choosing. If you don't specify
|
|
||||||
`CMAKE_INSTALL_PREFIX`, then the default is:
|
|
||||||
|
|
||||||
**c:\libjpeg-turbo**<br>
|
|
||||||
Visual Studio 32-bit build
|
|
||||||
|
|
||||||
**c:\libjpeg-turbo64**<br>
|
|
||||||
Visual Studio 64-bit build
|
|
||||||
|
|
||||||
**c:\libjpeg-turbo-gcc**<br>
|
|
||||||
MinGW 32-bit build
|
|
||||||
|
|
||||||
**c:\libjpeg-turbo-gcc64**<br>
|
|
||||||
MinGW 64-bit build
|
|
||||||
|
|
||||||
**/opt/libjpeg-turbo**<br>
|
|
||||||
Un*x
|
|
||||||
|
|
||||||
The default value of `CMAKE_INSTALL_PREFIX` causes the libjpeg-turbo files to
|
|
||||||
be installed with a directory structure resembling that of the official
|
|
||||||
libjpeg-turbo binary packages. Changing the value of `CMAKE_INSTALL_PREFIX`
|
|
||||||
(for instance, to **/usr/local**) causes the libjpeg-turbo files to be
|
|
||||||
installed with a directory structure that conforms to GNU standards.
|
|
||||||
|
|
||||||
The `CMAKE_INSTALL_BINDIR`, `CMAKE_INSTALL_DATAROOTDIR`,
|
|
||||||
`CMAKE_INSTALL_DOCDIR`, `CMAKE_INSTALL_INCLUDEDIR`, `CMAKE_INSTALL_JAVADIR`,
|
|
||||||
`CMAKE_INSTALL_LIBDIR`, and `CMAKE_INSTALL_MANDIR` CMake variables allow a
|
|
||||||
finer degree of control over where specific files in the libjpeg-turbo
|
|
||||||
distribution should be installed. These directory variables can either be
|
|
||||||
specified as absolute paths or as paths relative to `CMAKE_INSTALL_PREFIX` (for
|
|
||||||
instance, setting `CMAKE_INSTALL_DOCDIR` to **doc** would cause the
|
|
||||||
documentation to be installed in **${CMAKE\_INSTALL\_PREFIX}/doc**.) If a
|
|
||||||
directory variable contains the name of another directory variable in angle
|
|
||||||
brackets, then its final value will depend on the final value of that other
|
|
||||||
variable. For instance, the default value of `CMAKE_INSTALL_MANDIR` is
|
|
||||||
**\<CMAKE\_INSTALL\_DATAROOTDIR\>/man**.
|
|
||||||
|
|
||||||
NOTE: If setting one of these directory variables to a relative path using the
|
|
||||||
CMake command line, you must specify that the variable is of type `PATH`.
|
|
||||||
For example:
|
|
||||||
|
|
||||||
cmake -G"{generator type}" -DCMAKE_INSTALL_LIBDIR:PATH=lib {source_directory}
|
|
||||||
|
|
||||||
Otherwise, CMake will assume that the path is relative to the build directory
|
|
||||||
rather than the install directory.
|
|
||||||
|
|
||||||
|
|
||||||
Creating Distribution Packages
|
|
||||||
==============================
|
|
||||||
|
|
||||||
The following commands can be used to create various types of distribution
|
|
||||||
packages:
|
|
||||||
|
|
||||||
|
|
||||||
Linux
|
|
||||||
-----
|
|
||||||
|
|
||||||
make rpm
|
|
||||||
|
|
||||||
Create Red Hat-style binary RPM package. Requires RPM v4 or later.
|
|
||||||
|
|
||||||
make srpm
|
|
||||||
|
|
||||||
This runs `make dist` to create a pristine source tarball, then creates a
|
|
||||||
Red Hat-style source RPM package from the tarball. Requires RPM v4 or later.
|
|
||||||
|
|
||||||
make deb
|
|
||||||
|
|
||||||
Create Debian-style binary package. Requires dpkg.
|
|
||||||
|
|
||||||
|
|
||||||
Mac
|
|
||||||
---
|
|
||||||
|
|
||||||
make dmg
|
|
||||||
|
|
||||||
Create Mac package/disk image. This requires pkgbuild and productbuild, which
|
|
||||||
are installed by default on OS X/macOS 10.7 and later.
|
|
||||||
|
|
||||||
In order to create a Mac package/disk image that contains universal
|
|
||||||
x86-64/Arm binaries, set the following CMake variable:
|
|
||||||
|
|
||||||
* `ARMV8_BUILD`: Directory containing an Armv8 (64-bit) iOS or macOS build of
|
|
||||||
libjpeg-turbo to include in the universal binaries
|
|
||||||
|
|
||||||
You should first use CMake to configure an Armv8 sub-build of libjpeg-turbo
|
|
||||||
(see "Building libjpeg-turbo for iOS" above, if applicable) in a build
|
|
||||||
directory that matches the one specified in the aforementioned CMake variable.
|
|
||||||
Next, configure the primary (x86-64) build of libjpeg-turbo as an out-of-tree
|
|
||||||
build, specifying the aforementioned CMake variable, and build it. Once the
|
|
||||||
primary build has been built, run `make dmg` from the build directory. The
|
|
||||||
packaging system will build the sub-build, use lipo to combine it with the
|
|
||||||
primary build into a single set of universal binaries, then package the
|
|
||||||
universal binaries.
|
|
||||||
|
|
||||||
|
|
||||||
Windows
|
|
||||||
-------
|
|
||||||
|
|
||||||
If using NMake:
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
nmake installer
|
|
||||||
|
|
||||||
If using MinGW:
|
|
||||||
|
|
||||||
cd {build_directory}
|
|
||||||
make installer
|
|
||||||
|
|
||||||
If using the Visual Studio IDE, build the "installer" target.
|
|
||||||
|
|
||||||
The installer package (libjpeg-turbo-*{version}*[-gcc|-vc][64].exe) will be
|
|
||||||
located under *{build_directory}*. If building using the Visual Studio IDE,
|
|
||||||
then the installer package will be located in a subdirectory with the same name
|
|
||||||
as the configuration you built (such as *{build_directory}*\Debug\ or
|
|
||||||
*{build_directory}*\Release\).
|
|
||||||
|
|
||||||
Building a Windows installer requires the
|
|
||||||
[Nullsoft Install System](http://nsis.sourceforge.net/). makensis.exe should
|
|
||||||
be in your `PATH`.
|
|
||||||
|
|
||||||
|
|
||||||
Regression testing
|
|
||||||
==================
|
|
||||||
|
|
||||||
The most common way to test libjpeg-turbo is by invoking `make test` (Un*x) or
|
|
||||||
`nmake test` (Windows command line) or by building the "RUN_TESTS" target
|
|
||||||
(Visual Studio IDE), once the build has completed. This runs a series of tests
|
|
||||||
to ensure that mathematical compatibility has been maintained between
|
|
||||||
libjpeg-turbo and libjpeg v6b. This also invokes the TurboJPEG unit tests,
|
|
||||||
which ensure that the colorspace extensions, YUV encoding, decompression
|
|
||||||
scaling, and other features of the TurboJPEG C and Java APIs are working
|
|
||||||
properly (and, by extension, that the equivalent features of the underlying
|
|
||||||
libjpeg API are also working.)
|
|
||||||
|
|
||||||
Invoking `make testclean` (Un*x) or `nmake testclean` (Windows command line) or
|
|
||||||
building the "testclean" target (Visual Studio IDE) will clean up the output
|
|
||||||
images generated by the tests.
|
|
||||||
|
|
||||||
On Un*x platforms, more extensive tests of the TurboJPEG C and Java wrappers
|
|
||||||
can be run by invoking `make tjtest`. These extended TurboJPEG tests
|
|
||||||
essentially iterate through all of the available features of the TurboJPEG APIs
|
|
||||||
that are not covered by the TurboJPEG unit tests (including the lossless
|
|
||||||
transform options) and compare the images generated by each feature to images
|
|
||||||
generated using the equivalent feature in the libjpeg API. The extended
|
|
||||||
TurboJPEG tests are meant to test for regressions in the TurboJPEG wrappers,
|
|
||||||
not in the underlying libjpeg API library.
|
|
||||||
1559
android/extern/libjpeg-turbo/CMakeLists.txt
vendored
1929
android/extern/libjpeg-turbo/ChangeLog.md
vendored
132
android/extern/libjpeg-turbo/LICENSE.md
vendored
@@ -1,132 +0,0 @@
|
|||||||
libjpeg-turbo Licenses
|
|
||||||
======================
|
|
||||||
|
|
||||||
libjpeg-turbo is covered by three compatible BSD-style open source licenses:
|
|
||||||
|
|
||||||
- The IJG (Independent JPEG Group) License, which is listed in
|
|
||||||
[README.ijg](README.ijg)
|
|
||||||
|
|
||||||
This license applies to the libjpeg API library and associated programs
|
|
||||||
(any code inherited from libjpeg, and any modifications to that code.)
|
|
||||||
|
|
||||||
- The Modified (3-clause) BSD License, which is listed below
|
|
||||||
|
|
||||||
This license covers the TurboJPEG API library and associated programs, as
|
|
||||||
well as the build system.
|
|
||||||
|
|
||||||
- The [zlib License](https://opensource.org/licenses/Zlib)
|
|
||||||
|
|
||||||
This license is a subset of the other two, and it covers the libjpeg-turbo
|
|
||||||
SIMD extensions.
|
|
||||||
|
|
||||||
|
|
||||||
Complying with the libjpeg-turbo Licenses
|
|
||||||
=========================================
|
|
||||||
|
|
||||||
This section provides a roll-up of the libjpeg-turbo licensing terms, to the
|
|
||||||
best of our understanding.
|
|
||||||
|
|
||||||
1. If you are distributing a modified version of the libjpeg-turbo source,
|
|
||||||
then:
|
|
||||||
|
|
||||||
1. You cannot alter or remove any existing copyright or license notices
|
|
||||||
from the source.
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- Clause 1 of the IJG License
|
|
||||||
- Clause 1 of the Modified BSD License
|
|
||||||
- Clauses 1 and 3 of the zlib License
|
|
||||||
|
|
||||||
2. You must add your own copyright notice to the header of each source
|
|
||||||
file you modified, so others can tell that you modified that file (if
|
|
||||||
there is not an existing copyright header in that file, then you can
|
|
||||||
simply add a notice stating that you modified the file.)
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- Clause 1 of the IJG License
|
|
||||||
- Clause 2 of the zlib License
|
|
||||||
|
|
||||||
3. You must include the IJG README file, and you must not alter any of the
|
|
||||||
copyright or license text in that file.
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- Clause 1 of the IJG License
|
|
||||||
|
|
||||||
2. If you are distributing only libjpeg-turbo binaries without the source, or
|
|
||||||
if you are distributing an application that statically links with
|
|
||||||
libjpeg-turbo, then:
|
|
||||||
|
|
||||||
1. Your product documentation must include a message stating:
|
|
||||||
|
|
||||||
This software is based in part on the work of the Independent JPEG
|
|
||||||
Group.
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- Clause 2 of the IJG license
|
|
||||||
|
|
||||||
2. If your binary distribution includes or uses the TurboJPEG API, then
|
|
||||||
your product documentation must include the text of the Modified BSD
|
|
||||||
License (see below.)
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- Clause 2 of the Modified BSD License
|
|
||||||
|
|
||||||
3. You cannot use the name of the IJG or The libjpeg-turbo Project or the
|
|
||||||
contributors thereof in advertising, publicity, etc.
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- IJG License
|
|
||||||
- Clause 3 of the Modified BSD License
|
|
||||||
|
|
||||||
4. The IJG and The libjpeg-turbo Project do not warrant libjpeg-turbo to be
|
|
||||||
free of defects, nor do we accept any liability for undesirable
|
|
||||||
consequences resulting from your use of the software.
|
|
||||||
|
|
||||||
**Origin**
|
|
||||||
- IJG License
|
|
||||||
- Modified BSD License
|
|
||||||
- zlib License
|
|
||||||
|
|
||||||
|
|
||||||
The Modified (3-clause) BSD License
|
|
||||||
===================================
|
|
||||||
|
|
||||||
Copyright (C)2009-2023 D. R. Commander. All Rights Reserved.<br>
|
|
||||||
Copyright (C)2015 Viktor Szathmáry. All Rights Reserved.
|
|
||||||
|
|
||||||
Redistribution and use in source and binary forms, with or without
|
|
||||||
modification, are permitted provided that the following conditions are met:
|
|
||||||
|
|
||||||
- Redistributions of source code must retain the above copyright notice,
|
|
||||||
this list of conditions and the following disclaimer.
|
|
||||||
- Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
this list of conditions and the following disclaimer in the documentation
|
|
||||||
and/or other materials provided with the distribution.
|
|
||||||
- Neither the name of the libjpeg-turbo Project nor the names of its
|
|
||||||
contributors may be used to endorse or promote products derived from this
|
|
||||||
software without specific prior written permission.
|
|
||||||
|
|
||||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS",
|
|
||||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
||||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
|
|
||||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
||||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
||||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
||||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
||||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
||||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
||||||
POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
|
|
||||||
|
|
||||||
Why Three Licenses?
|
|
||||||
===================
|
|
||||||
|
|
||||||
The zlib License could have been used instead of the Modified (3-clause) BSD
|
|
||||||
License, and since the IJG License effectively subsumes the distribution
|
|
||||||
conditions of the zlib License, this would have effectively placed
|
|
||||||
libjpeg-turbo binary distributions under the IJG License. However, the IJG
|
|
||||||
License specifically refers to the Independent JPEG Group and does not extend
|
|
||||||
attribution and endorsement protections to other entities. Thus, it was
|
|
||||||
desirable to choose a license that granted us the same protections for new code
|
|
||||||
that were granted to the IJG for code derived from their software.
|
|
||||||
258
android/extern/libjpeg-turbo/README.ijg
vendored
@@ -1,258 +0,0 @@
|
|||||||
libjpeg-turbo note: This file has been modified by The libjpeg-turbo Project
|
|
||||||
to include only information relevant to libjpeg-turbo, to wordsmith certain
|
|
||||||
sections, and to remove impolitic language that existed in the libjpeg v8
|
|
||||||
README. It is included only for reference. Please see README.md for
|
|
||||||
information specific to libjpeg-turbo.
|
|
||||||
|
|
||||||
|
|
||||||
The Independent JPEG Group's JPEG software
|
|
||||||
==========================================
|
|
||||||
|
|
||||||
This distribution contains a release of the Independent JPEG Group's free JPEG
|
|
||||||
software. You are welcome to redistribute this software and to use it for any
|
|
||||||
purpose, subject to the conditions under LEGAL ISSUES, below.
|
|
||||||
|
|
||||||
This software is the work of Tom Lane, Guido Vollbeding, Philip Gladstone,
|
|
||||||
Bill Allombert, Jim Boucher, Lee Crocker, Bob Friesenhahn, Ben Jackson,
|
|
||||||
Julian Minguillon, Luis Ortiz, George Phillips, Davide Rossi, Ge' Weijers,
|
|
||||||
and other members of the Independent JPEG Group.
|
|
||||||
|
|
||||||
IJG is not affiliated with the ISO/IEC JTC1/SC29/WG1 standards committee
|
|
||||||
(also known as JPEG, together with ITU-T SG16).
|
|
||||||
|
|
||||||
|
|
||||||
DOCUMENTATION ROADMAP
|
|
||||||
=====================
|
|
||||||
|
|
||||||
This file contains the following sections:
|
|
||||||
|
|
||||||
OVERVIEW General description of JPEG and the IJG software.
|
|
||||||
LEGAL ISSUES Copyright, lack of warranty, terms of distribution.
|
|
||||||
REFERENCES Where to learn more about JPEG.
|
|
||||||
ARCHIVE LOCATIONS Where to find newer versions of this software.
|
|
||||||
FILE FORMAT WARS Software *not* to get.
|
|
||||||
TO DO Plans for future IJG releases.
|
|
||||||
|
|
||||||
Other documentation files in the distribution are:
|
|
||||||
|
|
||||||
User documentation:
|
|
||||||
usage.txt Usage instructions for cjpeg, djpeg, jpegtran,
|
|
||||||
rdjpgcom, and wrjpgcom.
|
|
||||||
*.1 Unix-style man pages for programs (same info as usage.txt).
|
|
||||||
wizard.txt Advanced usage instructions for JPEG wizards only.
|
|
||||||
change.log Version-to-version change highlights.
|
|
||||||
Programmer and internal documentation:
|
|
||||||
libjpeg.txt How to use the JPEG library in your own programs.
|
|
||||||
example.txt Sample code for calling the JPEG library.
|
|
||||||
structure.txt Overview of the JPEG library's internal structure.
|
|
||||||
coderules.txt Coding style rules --- please read if you contribute code.
|
|
||||||
|
|
||||||
Please read at least usage.txt. Some information can also be found in the JPEG
|
|
||||||
FAQ (Frequently Asked Questions) article. See ARCHIVE LOCATIONS below to find
|
|
||||||
out where to obtain the FAQ article.
|
|
||||||
|
|
||||||
If you want to understand how the JPEG code works, we suggest reading one or
|
|
||||||
more of the REFERENCES, then looking at the documentation files (in roughly
|
|
||||||
the order listed) before diving into the code.
|
|
||||||
|
|
||||||
|
|
||||||
OVERVIEW
|
|
||||||
========
|
|
||||||
|
|
||||||
This package contains C software to implement JPEG image encoding, decoding,
|
|
||||||
and transcoding. JPEG (pronounced "jay-peg") is a standardized compression
|
|
||||||
method for full-color and grayscale images. JPEG's strong suit is compressing
|
|
||||||
photographic images or other types of images that have smooth color and
|
|
||||||
brightness transitions between neighboring pixels. Images with sharp lines or
|
|
||||||
other abrupt features may not compress well with JPEG, and a higher JPEG
|
|
||||||
quality may have to be used to avoid visible compression artifacts with such
|
|
||||||
images.
|
|
||||||
|
|
||||||
JPEG is lossy, meaning that the output pixels are not necessarily identical to
|
|
||||||
the input pixels. However, on photographic content and other "smooth" images,
|
|
||||||
very good compression ratios can be obtained with no visible compression
|
|
||||||
artifacts, and extremely high compression ratios are possible if you are
|
|
||||||
willing to sacrifice image quality (by reducing the "quality" setting in the
|
|
||||||
compressor.)
|
|
||||||
|
|
||||||
This software implements JPEG baseline, extended-sequential, and progressive
|
|
||||||
compression processes. Provision is made for supporting all variants of these
|
|
||||||
processes, although some uncommon parameter settings aren't implemented yet.
|
|
||||||
We have made no provision for supporting the hierarchical or lossless
|
|
||||||
processes defined in the standard.
|
|
||||||
|
|
||||||
We provide a set of library routines for reading and writing JPEG image files,
|
|
||||||
plus two sample applications "cjpeg" and "djpeg", which use the library to
|
|
||||||
perform conversion between JPEG and some other popular image file formats.
|
|
||||||
The library is intended to be reused in other applications.
|
|
||||||
|
|
||||||
In order to support file conversion and viewing software, we have included
|
|
||||||
considerable functionality beyond the bare JPEG coding/decoding capability;
|
|
||||||
for example, the color quantization modules are not strictly part of JPEG
|
|
||||||
decoding, but they are essential for output to colormapped file formats or
|
|
||||||
colormapped displays. These extra functions can be compiled out of the
|
|
||||||
library if not required for a particular application.
|
|
||||||
|
|
||||||
We have also included "jpegtran", a utility for lossless transcoding between
|
|
||||||
different JPEG processes, and "rdjpgcom" and "wrjpgcom", two simple
|
|
||||||
applications for inserting and extracting textual comments in JFIF files.
|
|
||||||
|
|
||||||
The emphasis in designing this software has been on achieving portability and
|
|
||||||
flexibility, while also making it fast enough to be useful. In particular,
|
|
||||||
the software is not intended to be read as a tutorial on JPEG. (See the
|
|
||||||
REFERENCES section for introductory material.) Rather, it is intended to
|
|
||||||
be reliable, portable, industrial-strength code. We do not claim to have
|
|
||||||
achieved that goal in every aspect of the software, but we strive for it.
|
|
||||||
|
|
||||||
We welcome the use of this software as a component of commercial products.
|
|
||||||
No royalty is required, but we do ask for an acknowledgement in product
|
|
||||||
documentation, as described under LEGAL ISSUES.
|
|
||||||
|
|
||||||
|
|
||||||
LEGAL ISSUES
|
|
||||||
============
|
|
||||||
|
|
||||||
In plain English:
|
|
||||||
|
|
||||||
1. We don't promise that this software works. (But if you find any bugs,
|
|
||||||
please let us know!)
|
|
||||||
2. You can use this software for whatever you want. You don't have to pay us.
|
|
||||||
3. You may not pretend that you wrote this software. If you use it in a
|
|
||||||
program, you must acknowledge somewhere in your documentation that
|
|
||||||
you've used the IJG code.
|
|
||||||
|
|
||||||
In legalese:
|
|
||||||
|
|
||||||
The authors make NO WARRANTY or representation, either express or implied,
|
|
||||||
with respect to this software, its quality, accuracy, merchantability, or
|
|
||||||
fitness for a particular purpose. This software is provided "AS IS", and you,
|
|
||||||
its user, assume the entire risk as to its quality and accuracy.
|
|
||||||
|
|
||||||
This software is copyright (C) 1991-2020, Thomas G. Lane, Guido Vollbeding.
|
|
||||||
All Rights Reserved except as specified below.
|
|
||||||
|
|
||||||
Permission is hereby granted to use, copy, modify, and distribute this
|
|
||||||
software (or portions thereof) for any purpose, without fee, subject to these
|
|
||||||
conditions:
|
|
||||||
(1) If any part of the source code for this software is distributed, then this
|
|
||||||
README file must be included, with this copyright and no-warranty notice
|
|
||||||
unaltered; and any additions, deletions, or changes to the original files
|
|
||||||
must be clearly indicated in accompanying documentation.
|
|
||||||
(2) If only executable code is distributed, then the accompanying
|
|
||||||
documentation must state that "this software is based in part on the work of
|
|
||||||
the Independent JPEG Group".
|
|
||||||
(3) Permission for use of this software is granted only if the user accepts
|
|
||||||
full responsibility for any undesirable consequences; the authors accept
|
|
||||||
NO LIABILITY for damages of any kind.
|
|
||||||
|
|
||||||
These conditions apply to any software derived from or based on the IJG code,
|
|
||||||
not just to the unmodified library. If you use our work, you ought to
|
|
||||||
acknowledge us.
|
|
||||||
|
|
||||||
Permission is NOT granted for the use of any IJG author's name or company name
|
|
||||||
in advertising or publicity relating to this software or products derived from
|
|
||||||
it. This software may be referred to only as "the Independent JPEG Group's
|
|
||||||
software".
|
|
||||||
|
|
||||||
We specifically permit and encourage the use of this software as the basis of
|
|
||||||
commercial products, provided that all warranty or liability claims are
|
|
||||||
assumed by the product vendor.
|
|
||||||
|
|
||||||
|
|
||||||
REFERENCES
|
|
||||||
==========
|
|
||||||
|
|
||||||
We recommend reading one or more of these references before trying to
|
|
||||||
understand the innards of the JPEG software.
|
|
||||||
|
|
||||||
The best short technical introduction to the JPEG compression algorithm is
|
|
||||||
Wallace, Gregory K. "The JPEG Still Picture Compression Standard",
|
|
||||||
Communications of the ACM, April 1991 (vol. 34 no. 4), pp. 30-44.
|
|
||||||
(Adjacent articles in that issue discuss MPEG motion picture compression,
|
|
||||||
applications of JPEG, and related topics.) If you don't have the CACM issue
|
|
||||||
handy, a PDF file containing a revised version of Wallace's article is
|
|
||||||
available at http://www.ijg.org/files/Wallace.JPEG.pdf. The file (actually
|
|
||||||
a preprint for an article that appeared in IEEE Trans. Consumer Electronics)
|
|
||||||
omits the sample images that appeared in CACM, but it includes corrections
|
|
||||||
and some added material. Note: the Wallace article is copyright ACM and IEEE,
|
|
||||||
and it may not be used for commercial purposes.
|
|
||||||
|
|
||||||
A somewhat less technical, more leisurely introduction to JPEG can be found in
|
|
||||||
"The Data Compression Book" by Mark Nelson and Jean-loup Gailly, published by
|
|
||||||
M&T Books (New York), 2nd ed. 1996, ISBN 1-55851-434-1. This book provides
|
|
||||||
good explanations and example C code for a multitude of compression methods
|
|
||||||
including JPEG. It is an excellent source if you are comfortable reading C
|
|
||||||
code but don't know much about data compression in general. The book's JPEG
|
|
||||||
sample code is far from industrial-strength, but when you are ready to look
|
|
||||||
at a full implementation, you've got one here...
|
|
||||||
|
|
||||||
The best currently available description of JPEG is the textbook "JPEG Still
|
|
||||||
Image Data Compression Standard" by William B. Pennebaker and Joan L.
|
|
||||||
Mitchell, published by Van Nostrand Reinhold, 1993, ISBN 0-442-01272-1.
|
|
||||||
Price US$59.95, 638 pp. The book includes the complete text of the ISO JPEG
|
|
||||||
standards (DIS 10918-1 and draft DIS 10918-2).
|
|
||||||
|
|
||||||
The original JPEG standard is divided into two parts, Part 1 being the actual
|
|
||||||
specification, while Part 2 covers compliance testing methods. Part 1 is
|
|
||||||
titled "Digital Compression and Coding of Continuous-tone Still Images,
|
|
||||||
Part 1: Requirements and guidelines" and has document numbers ISO/IEC IS
|
|
||||||
10918-1, ITU-T T.81. Part 2 is titled "Digital Compression and Coding of
|
|
||||||
Continuous-tone Still Images, Part 2: Compliance testing" and has document
|
|
||||||
numbers ISO/IEC IS 10918-2, ITU-T T.83.
|
|
||||||
|
|
||||||
The JPEG standard does not specify all details of an interchangeable file
|
|
||||||
format. For the omitted details, we follow the "JFIF" conventions, revision
|
|
||||||
1.02. JFIF version 1 has been adopted as ISO/IEC 10918-5 (05/2013) and
|
|
||||||
Recommendation ITU-T T.871 (05/2011): Information technology - Digital
|
|
||||||
compression and coding of continuous-tone still images: JPEG File Interchange
|
|
||||||
Format (JFIF). It is available as a free download in PDF file format from
|
|
||||||
https://www.iso.org/standard/54989.html and http://www.itu.int/rec/T-REC-T.871.
|
|
||||||
A PDF file of the older JFIF 1.02 specification is available at
|
|
||||||
http://www.w3.org/Graphics/JPEG/jfif3.pdf.
|
|
||||||
|
|
||||||
The TIFF 6.0 file format specification can be obtained from
|
|
||||||
http://mirrors.ctan.org/graphics/tiff/TIFF6.ps.gz. The JPEG incorporation
|
|
||||||
scheme found in the TIFF 6.0 spec of 3-June-92 has a number of serious
|
|
||||||
problems. IJG does not recommend use of the TIFF 6.0 design (TIFF Compression
|
|
||||||
tag 6). Instead, we recommend the JPEG design proposed by TIFF Technical Note
|
|
||||||
#2 (Compression tag 7). Copies of this Note can be obtained from
|
|
||||||
http://www.ijg.org/files/. It is expected that the next revision
|
|
||||||
of the TIFF spec will replace the 6.0 JPEG design with the Note's design.
|
|
||||||
Although IJG's own code does not support TIFF/JPEG, the free libtiff library
|
|
||||||
uses our library to implement TIFF/JPEG per the Note.
|
|
||||||
|
|
||||||
|
|
||||||
ARCHIVE LOCATIONS
|
|
||||||
=================
|
|
||||||
|
|
||||||
The "official" archive site for this software is www.ijg.org.
|
|
||||||
The most recent released version can always be found there in
|
|
||||||
directory "files".
|
|
||||||
|
|
||||||
The JPEG FAQ (Frequently Asked Questions) article is a source of some
|
|
||||||
general information about JPEG. It is available at
|
|
||||||
http://www.faqs.org/faqs/jpeg-faq.
|
|
||||||
|
|
||||||
|
|
||||||
FILE FORMAT COMPATIBILITY
|
|
||||||
=========================
|
|
||||||
|
|
||||||
This software implements ITU T.81 | ISO/IEC 10918 with some extensions from
|
|
||||||
ITU T.871 | ISO/IEC 10918-5 (JPEG File Interchange Format-- see REFERENCES).
|
|
||||||
Informally, the term "JPEG image" or "JPEG file" most often refers to JFIF or
|
|
||||||
a subset thereof, but there are other formats containing the name "JPEG" that
|
|
||||||
are incompatible with the DCT-based JPEG standard or with JFIF (for instance,
|
|
||||||
JPEG 2000 and JPEG XR). This software therefore does not support these
|
|
||||||
formats. Indeed, one of the original reasons for developing this free software
|
|
||||||
was to help force convergence on a common, interoperable format standard for
|
|
||||||
JPEG files.
|
|
||||||
|
|
||||||
JFIF is a minimal or "low end" representation. TIFF/JPEG (TIFF revision 6.0 as
|
|
||||||
modified by TIFF Technical Note #2) can be used for "high end" applications
|
|
||||||
that need to record a lot of additional data about an image.
|
|
||||||
|
|
||||||
|
|
||||||
TO DO
|
|
||||||
=====
|
|
||||||
|
|
||||||
Please send bug reports, offers of help, etc. to jpeg-info@jpegclub.org.
|
|
||||||
357
android/extern/libjpeg-turbo/README.md
vendored
@@ -1,357 +0,0 @@
|
|||||||
Background
|
|
||||||
==========
|
|
||||||
|
|
||||||
libjpeg-turbo is a JPEG image codec that uses SIMD instructions to accelerate
|
|
||||||
baseline JPEG compression and decompression on x86, x86-64, Arm, PowerPC, and
|
|
||||||
MIPS systems, as well as progressive JPEG compression on x86, x86-64, and Arm
|
|
||||||
systems. On such systems, libjpeg-turbo is generally 2-6x as fast as libjpeg,
|
|
||||||
all else being equal. On other types of systems, libjpeg-turbo can still
|
|
||||||
outperform libjpeg by a significant amount, by virtue of its highly-optimized
|
|
||||||
Huffman coding routines. In many cases, the performance of libjpeg-turbo
|
|
||||||
rivals that of proprietary high-speed JPEG codecs.
|
|
||||||
|
|
||||||
libjpeg-turbo implements both the traditional libjpeg API as well as the less
|
|
||||||
powerful but more straightforward TurboJPEG API. libjpeg-turbo also features
|
|
||||||
colorspace extensions that allow it to compress from/decompress to 32-bit and
|
|
||||||
big-endian pixel buffers (RGBX, XBGR, etc.), as well as a full-featured Java
|
|
||||||
interface.
|
|
||||||
|
|
||||||
libjpeg-turbo was originally based on libjpeg/SIMD, an MMX-accelerated
|
|
||||||
derivative of libjpeg v6b developed by Miyasaka Masaru. The TigerVNC and
|
|
||||||
VirtualGL projects made numerous enhancements to the codec in 2009, and in
|
|
||||||
early 2010, libjpeg-turbo spun off into an independent project, with the goal
|
|
||||||
of making high-speed JPEG compression/decompression technology available to a
|
|
||||||
broader range of users and developers.
|
|
||||||
|
|
||||||
|
|
||||||
License
|
|
||||||
=======
|
|
||||||
|
|
||||||
libjpeg-turbo is covered by three compatible BSD-style open source licenses.
|
|
||||||
Refer to [LICENSE.md](LICENSE.md) for a roll-up of license terms.
|
|
||||||
|
|
||||||
|
|
||||||
Building libjpeg-turbo
|
|
||||||
======================
|
|
||||||
|
|
||||||
Refer to [BUILDING.md](BUILDING.md) for complete instructions.
|
|
||||||
|
|
||||||
|
|
||||||
Using libjpeg-turbo
|
|
||||||
===================
|
|
||||||
|
|
||||||
libjpeg-turbo includes two APIs that can be used to compress and decompress
|
|
||||||
JPEG images:
|
|
||||||
|
|
||||||
- **TurboJPEG API**<br>
|
|
||||||
This API provides an easy-to-use interface for compressing and decompressing
|
|
||||||
JPEG images in memory. It also provides some functionality that would not be
|
|
||||||
straightforward to achieve using the underlying libjpeg API, such as
|
|
||||||
generating planar YUV images and performing multiple simultaneous lossless
|
|
||||||
transforms on an image. The Java interface for libjpeg-turbo is written on
|
|
||||||
top of the TurboJPEG API. The TurboJPEG API is recommended for first-time
|
|
||||||
users of libjpeg-turbo. Refer to [tjexample.c](tjexample.c) and
|
|
||||||
[TJExample.java](java/TJExample.java) for examples of its usage and to
|
|
||||||
<http://libjpeg-turbo.org/Documentation/Documentation> for API documentation.
|
|
||||||
|
|
||||||
- **libjpeg API**<br>
|
|
||||||
This is the de facto industry-standard API for compressing and decompressing
|
|
||||||
JPEG images. It is more difficult to use than the TurboJPEG API but also
|
|
||||||
more powerful. The libjpeg API implementation in libjpeg-turbo is both
|
|
||||||
API/ABI-compatible and mathematically compatible with libjpeg v6b. It can
|
|
||||||
also optionally be configured to be API/ABI-compatible with libjpeg v7 and v8
|
|
||||||
(see below.) Refer to [cjpeg.c](cjpeg.c) and [djpeg.c](djpeg.c) for examples
|
|
||||||
of its usage and to [libjpeg.txt](libjpeg.txt) for API documentation.
|
|
||||||
|
|
||||||
There is no significant performance advantage to either API when both are used
|
|
||||||
to perform similar operations.
|
|
||||||
|
|
||||||
Colorspace Extensions
|
|
||||||
---------------------
|
|
||||||
|
|
||||||
libjpeg-turbo includes extensions that allow JPEG images to be compressed
|
|
||||||
directly from (and decompressed directly to) buffers that use BGR, BGRX,
|
|
||||||
RGBX, XBGR, and XRGB pixel ordering. This is implemented with ten new
|
|
||||||
colorspace constants:
|
|
||||||
|
|
||||||
JCS_EXT_RGB /* red/green/blue */
|
|
||||||
JCS_EXT_RGBX /* red/green/blue/x */
|
|
||||||
JCS_EXT_BGR /* blue/green/red */
|
|
||||||
JCS_EXT_BGRX /* blue/green/red/x */
|
|
||||||
JCS_EXT_XBGR /* x/blue/green/red */
|
|
||||||
JCS_EXT_XRGB /* x/red/green/blue */
|
|
||||||
JCS_EXT_RGBA /* red/green/blue/alpha */
|
|
||||||
JCS_EXT_BGRA /* blue/green/red/alpha */
|
|
||||||
JCS_EXT_ABGR /* alpha/blue/green/red */
|
|
||||||
JCS_EXT_ARGB /* alpha/red/green/blue */
|
|
||||||
|
|
||||||
Setting `cinfo.in_color_space` (compression) or `cinfo.out_color_space`
|
|
||||||
(decompression) to one of these values will cause libjpeg-turbo to read the
|
|
||||||
red, green, and blue values from (or write them to) the appropriate position in
|
|
||||||
the pixel when compressing from/decompressing to an RGB buffer.
|
|
||||||
|
|
||||||
Your application can check for the existence of these extensions at compile
|
|
||||||
time with:
|
|
||||||
|
|
||||||
#ifdef JCS_EXTENSIONS
|
|
||||||
|
|
||||||
At run time, attempting to use these extensions with a libjpeg implementation
|
|
||||||
that does not support them will result in a "Bogus input colorspace" error.
|
|
||||||
Applications can trap this error in order to test whether run-time support is
|
|
||||||
available for the colorspace extensions.
|
|
||||||
|
|
||||||
When using the RGBX, BGRX, XBGR, and XRGB colorspaces during decompression, the
|
|
||||||
X byte is undefined, and in order to ensure the best performance, libjpeg-turbo
|
|
||||||
can set that byte to whatever value it wishes. If an application expects the X
|
|
||||||
byte to be used as an alpha channel, then it should specify `JCS_EXT_RGBA`,
|
|
||||||
`JCS_EXT_BGRA`, `JCS_EXT_ABGR`, or `JCS_EXT_ARGB`. When these colorspace
|
|
||||||
constants are used, the X byte is guaranteed to be 0xFF, which is interpreted
|
|
||||||
as opaque.
|
|
||||||
|
|
||||||
Your application can check for the existence of the alpha channel colorspace
|
|
||||||
extensions at compile time with:
|
|
||||||
|
|
||||||
#ifdef JCS_ALPHA_EXTENSIONS
|
|
||||||
|
|
||||||
[jcstest.c](jcstest.c), located in the libjpeg-turbo source tree, demonstrates
|
|
||||||
how to check for the existence of the colorspace extensions at compile time and
|
|
||||||
run time.
|
|
||||||
|
|
||||||
libjpeg v7 and v8 API/ABI Emulation
|
|
||||||
-----------------------------------
|
|
||||||
|
|
||||||
With libjpeg v7 and v8, new features were added that necessitated extending the
|
|
||||||
compression and decompression structures. Unfortunately, due to the exposed
|
|
||||||
nature of those structures, extending them also necessitated breaking backward
|
|
||||||
ABI compatibility with previous libjpeg releases. Thus, programs that were
|
|
||||||
built to use libjpeg v7 or v8 did not work with libjpeg-turbo, since it is
|
|
||||||
based on the libjpeg v6b code base. Although libjpeg v7 and v8 are not
|
|
||||||
as widely used as v6b, enough programs (including a few Linux distros) made
|
|
||||||
the switch that there was a demand to emulate the libjpeg v7 and v8 ABIs
|
|
||||||
in libjpeg-turbo. It should be noted, however, that this feature was added
|
|
||||||
primarily so that applications that had already been compiled to use libjpeg
|
|
||||||
v7+ could take advantage of accelerated baseline JPEG encoding/decoding
|
|
||||||
without recompiling. libjpeg-turbo does not claim to support all of the
|
|
||||||
libjpeg v7+ features, nor to produce identical output to libjpeg v7+ in all
|
|
||||||
cases (see below.)
|
|
||||||
|
|
||||||
By passing an argument of `-DWITH_JPEG7=1` or `-DWITH_JPEG8=1` to `cmake`, you
|
|
||||||
can build a version of libjpeg-turbo that emulates the libjpeg v7 or v8 ABI, so
|
|
||||||
that programs that are built against libjpeg v7 or v8 can be run with
|
|
||||||
libjpeg-turbo. The following section describes which libjpeg v7+ features are
|
|
||||||
supported and which aren't.
|
|
||||||
|
|
||||||
### Support for libjpeg v7 and v8 Features
|
|
||||||
|
|
||||||
#### Fully supported
|
|
||||||
|
|
||||||
- **libjpeg API: IDCT scaling extensions in decompressor**<br>
|
|
||||||
libjpeg-turbo supports IDCT scaling with scaling factors of 1/8, 1/4, 3/8,
|
|
||||||
1/2, 5/8, 3/4, 7/8, 9/8, 5/4, 11/8, 3/2, 13/8, 7/4, 15/8, and 2/1 (only 1/4
|
|
||||||
and 1/2 are SIMD-accelerated.)
|
|
||||||
|
|
||||||
- **libjpeg API: Arithmetic coding**
|
|
||||||
|
|
||||||
- **libjpeg API: In-memory source and destination managers**<br>
|
|
||||||
See notes below.
|
|
||||||
|
|
||||||
- **cjpeg: Separate quality settings for luminance and chrominance**<br>
|
|
||||||
Note that the libpjeg v7+ API was extended to accommodate this feature only
|
|
||||||
for convenience purposes. It has always been possible to implement this
|
|
||||||
feature with libjpeg v6b (see rdswitch.c for an example.)
|
|
||||||
|
|
||||||
- **cjpeg: 32-bit BMP support**
|
|
||||||
|
|
||||||
- **cjpeg: `-rgb` option**
|
|
||||||
|
|
||||||
- **jpegtran: Lossless cropping**
|
|
||||||
|
|
||||||
- **jpegtran: `-perfect` option**
|
|
||||||
|
|
||||||
- **jpegtran: Forcing width/height when performing lossless crop**
|
|
||||||
|
|
||||||
- **rdjpgcom: `-raw` option**
|
|
||||||
|
|
||||||
- **rdjpgcom: Locale awareness**
|
|
||||||
|
|
||||||
|
|
||||||
#### Not supported
|
|
||||||
|
|
||||||
NOTE: As of this writing, extensive research has been conducted into the
|
|
||||||
usefulness of DCT scaling as a means of data reduction and SmartScale as a
|
|
||||||
means of quality improvement. Readers are invited to peruse the research at
|
|
||||||
<http://www.libjpeg-turbo.org/About/SmartScale> and draw their own conclusions,
|
|
||||||
but it is the general belief of our project that these features have not
|
|
||||||
demonstrated sufficient usefulness to justify inclusion in libjpeg-turbo.
|
|
||||||
|
|
||||||
- **libjpeg API: DCT scaling in compressor**<br>
|
|
||||||
`cinfo.scale_num` and `cinfo.scale_denom` are silently ignored.
|
|
||||||
There is no technical reason why DCT scaling could not be supported when
|
|
||||||
emulating the libjpeg v7+ API/ABI, but without the SmartScale extension (see
|
|
||||||
below), only scaling factors of 1/2, 8/15, 4/7, 8/13, 2/3, 8/11, 4/5, and
|
|
||||||
8/9 would be available, which is of limited usefulness.
|
|
||||||
|
|
||||||
- **libjpeg API: SmartScale**<br>
|
|
||||||
`cinfo.block_size` is silently ignored.
|
|
||||||
SmartScale is an extension to the JPEG format that allows for DCT block
|
|
||||||
sizes other than 8x8. Providing support for this new format would be
|
|
||||||
feasible (particularly without full acceleration.) However, until/unless
|
|
||||||
the format becomes either an official industry standard or, at minimum, an
|
|
||||||
accepted solution in the community, we are hesitant to implement it, as
|
|
||||||
there is no sense of whether or how it might change in the future. It is
|
|
||||||
our belief that SmartScale has not demonstrated sufficient usefulness as a
|
|
||||||
lossless format nor as a means of quality enhancement, and thus our primary
|
|
||||||
interest in providing this feature would be as a means of supporting
|
|
||||||
additional DCT scaling factors.
|
|
||||||
|
|
||||||
- **libjpeg API: Fancy downsampling in compressor**<br>
|
|
||||||
`cinfo.do_fancy_downsampling` is silently ignored.
|
|
||||||
This requires the DCT scaling feature, which is not supported.
|
|
||||||
|
|
||||||
- **jpegtran: Scaling**<br>
|
|
||||||
This requires both the DCT scaling and SmartScale features, which are not
|
|
||||||
supported.
|
|
||||||
|
|
||||||
- **Lossless RGB JPEG files**<br>
|
|
||||||
This requires the SmartScale feature, which is not supported.
|
|
||||||
|
|
||||||
### What About libjpeg v9?
|
|
||||||
|
|
||||||
libjpeg v9 introduced yet another field to the JPEG compression structure
|
|
||||||
(`color_transform`), thus making the ABI backward incompatible with that of
|
|
||||||
libjpeg v8. This new field was introduced solely for the purpose of supporting
|
|
||||||
lossless SmartScale encoding. Furthermore, there was actually no reason to
|
|
||||||
extend the API in this manner, as the color transform could have just as easily
|
|
||||||
been activated by way of a new JPEG colorspace constant, thus preserving
|
|
||||||
backward ABI compatibility.
|
|
||||||
|
|
||||||
Our research (see link above) has shown that lossless SmartScale does not
|
|
||||||
generally accomplish anything that can't already be accomplished better with
|
|
||||||
existing, standard lossless formats. Therefore, at this time it is our belief
|
|
||||||
that there is not sufficient technical justification for software projects to
|
|
||||||
upgrade from libjpeg v8 to libjpeg v9, and thus there is not sufficient
|
|
||||||
technical justification for us to emulate the libjpeg v9 ABI.
|
|
||||||
|
|
||||||
In-Memory Source/Destination Managers
|
|
||||||
-------------------------------------
|
|
||||||
|
|
||||||
By default, libjpeg-turbo 1.3 and later includes the `jpeg_mem_src()` and
|
|
||||||
`jpeg_mem_dest()` functions, even when not emulating the libjpeg v8 API/ABI.
|
|
||||||
Previously, it was necessary to build libjpeg-turbo from source with libjpeg v8
|
|
||||||
API/ABI emulation in order to use the in-memory source/destination managers,
|
|
||||||
but several projects requested that those functions be included when emulating
|
|
||||||
the libjpeg v6b API/ABI as well. This allows the use of those functions by
|
|
||||||
programs that need them, without breaking ABI compatibility for programs that
|
|
||||||
don't, and it allows those functions to be provided in the "official"
|
|
||||||
libjpeg-turbo binaries.
|
|
||||||
|
|
||||||
Those who are concerned about maintaining strict conformance with the libjpeg
|
|
||||||
v6b or v7 API can pass an argument of `-DWITH_MEM_SRCDST=0` to `cmake` prior to
|
|
||||||
building libjpeg-turbo. This will restore the pre-1.3 behavior, in which
|
|
||||||
`jpeg_mem_src()` and `jpeg_mem_dest()` are only included when emulating the
|
|
||||||
libjpeg v8 API/ABI.
|
|
||||||
|
|
||||||
On Un*x systems, including the in-memory source/destination managers changes
|
|
||||||
the dynamic library version from 62.2.0 to 62.3.0 if using libjpeg v6b API/ABI
|
|
||||||
emulation and from 7.2.0 to 7.3.0 if using libjpeg v7 API/ABI emulation.
|
|
||||||
|
|
||||||
Note that, on most Un*x systems, the dynamic linker will not look for a
|
|
||||||
function in a library until that function is actually used. Thus, if a program
|
|
||||||
is built against libjpeg-turbo 1.3+ and uses `jpeg_mem_src()` or
|
|
||||||
`jpeg_mem_dest()`, that program will not fail if run against an older version
|
|
||||||
of libjpeg-turbo or against libjpeg v7- until the program actually tries to
|
|
||||||
call `jpeg_mem_src()` or `jpeg_mem_dest()`. Such is not the case on Windows.
|
|
||||||
If a program is built against the libjpeg-turbo 1.3+ DLL and uses
|
|
||||||
`jpeg_mem_src()` or `jpeg_mem_dest()`, then it must use the libjpeg-turbo 1.3+
|
|
||||||
DLL at run time.
|
|
||||||
|
|
||||||
Both cjpeg and djpeg have been extended to allow testing the in-memory
|
|
||||||
source/destination manager functions. See their respective man pages for more
|
|
||||||
details.
|
|
||||||
|
|
||||||
|
|
||||||
Mathematical Compatibility
|
|
||||||
==========================
|
|
||||||
|
|
||||||
For the most part, libjpeg-turbo should produce identical output to libjpeg
|
|
||||||
v6b. The one exception to this is when using the floating point DCT/IDCT, in
|
|
||||||
which case the outputs of libjpeg v6b and libjpeg-turbo can differ for the
|
|
||||||
following reasons:
|
|
||||||
|
|
||||||
- The SSE/SSE2 floating point DCT implementation in libjpeg-turbo is ever so
|
|
||||||
slightly more accurate than the implementation in libjpeg v6b, but not by
|
|
||||||
any amount perceptible to human vision (generally in the range of 0.01 to
|
|
||||||
0.08 dB gain in PNSR.)
|
|
||||||
|
|
||||||
- When not using the SIMD extensions, libjpeg-turbo uses the more accurate
|
|
||||||
(and slightly faster) floating point IDCT algorithm introduced in libjpeg
|
|
||||||
v8a as opposed to the algorithm used in libjpeg v6b. It should be noted,
|
|
||||||
however, that this algorithm basically brings the accuracy of the floating
|
|
||||||
point IDCT in line with the accuracy of the accurate integer IDCT. The
|
|
||||||
floating point DCT/IDCT algorithms are mainly a legacy feature, and they do
|
|
||||||
not produce significantly more accuracy than the accurate integer algorithms
|
|
||||||
(to put numbers on this, the typical difference in PNSR between the two
|
|
||||||
algorithms is less than 0.10 dB, whereas changing the quality level by 1 in
|
|
||||||
the upper range of the quality scale is typically more like a 1.0 dB
|
|
||||||
difference.)
|
|
||||||
|
|
||||||
- If the floating point algorithms in libjpeg-turbo are not implemented using
|
|
||||||
SIMD instructions on a particular platform, then the accuracy of the
|
|
||||||
floating point DCT/IDCT can depend on the compiler settings.
|
|
||||||
|
|
||||||
While libjpeg-turbo does emulate the libjpeg v8 API/ABI, under the hood it is
|
|
||||||
still using the same algorithms as libjpeg v6b, so there are several specific
|
|
||||||
cases in which libjpeg-turbo cannot be expected to produce the same output as
|
|
||||||
libjpeg v8:
|
|
||||||
|
|
||||||
- When decompressing using scaling factors of 1/2 and 1/4, because libjpeg v8
|
|
||||||
implements those scaling algorithms differently than libjpeg v6b does, and
|
|
||||||
libjpeg-turbo's SIMD extensions are based on the libjpeg v6b behavior.
|
|
||||||
|
|
||||||
- When using chrominance subsampling, because libjpeg v8 implements this
|
|
||||||
with its DCT/IDCT scaling algorithms rather than with a separate
|
|
||||||
downsampling/upsampling algorithm. In our testing, the subsampled/upsampled
|
|
||||||
output of libjpeg v8 is less accurate than that of libjpeg v6b for this
|
|
||||||
reason.
|
|
||||||
|
|
||||||
- When decompressing using a scaling factor > 1 and merged (AKA "non-fancy" or
|
|
||||||
"non-smooth") chrominance upsampling, because libjpeg v8 does not support
|
|
||||||
merged upsampling with scaling factors > 1.
|
|
||||||
|
|
||||||
|
|
||||||
Performance Pitfalls
|
|
||||||
====================
|
|
||||||
|
|
||||||
Restart Markers
|
|
||||||
---------------
|
|
||||||
|
|
||||||
The optimized Huffman decoder in libjpeg-turbo does not handle restart markers
|
|
||||||
in a way that makes the rest of the libjpeg infrastructure happy, so it is
|
|
||||||
necessary to use the slow Huffman decoder when decompressing a JPEG image that
|
|
||||||
has restart markers. This can cause the decompression performance to drop by
|
|
||||||
as much as 20%, but the performance will still be much greater than that of
|
|
||||||
libjpeg. Many consumer packages, such as Photoshop, use restart markers when
|
|
||||||
generating JPEG images, so images generated by those programs will experience
|
|
||||||
this issue.
|
|
||||||
|
|
||||||
Fast Integer Forward DCT at High Quality Levels
|
|
||||||
-----------------------------------------------
|
|
||||||
|
|
||||||
The algorithm used by the SIMD-accelerated quantization function cannot produce
|
|
||||||
correct results whenever the fast integer forward DCT is used along with a JPEG
|
|
||||||
quality of 98-100. Thus, libjpeg-turbo must use the non-SIMD quantization
|
|
||||||
function in those cases. This causes performance to drop by as much as 40%.
|
|
||||||
It is therefore strongly advised that you use the accurate integer forward DCT
|
|
||||||
whenever encoding images with a JPEG quality of 98 or higher.
|
|
||||||
|
|
||||||
|
|
||||||
Memory Debugger Pitfalls
|
|
||||||
========================
|
|
||||||
|
|
||||||
Valgrind and Memory Sanitizer (MSan) can generate false positives
|
|
||||||
(specifically, incorrect reports of uninitialized memory accesses) when used
|
|
||||||
with libjpeg-turbo's SIMD extensions. It is generally recommended that the
|
|
||||||
SIMD extensions be disabled, either by passing an argument of `-DWITH_SIMD=0`
|
|
||||||
to `cmake` when configuring the build or by setting the environment variable
|
|
||||||
`JSIMD_FORCENONE` to `1` at run time, when testing libjpeg-turbo with Valgrind,
|
|
||||||
MSan, or other memory debuggers.
|
|
||||||
99
android/extern/libjpeg-turbo/appveyor.yml
vendored
@@ -1,99 +0,0 @@
|
|||||||
install:
|
|
||||||
- cmd: >-
|
|
||||||
if not exist c:\installers mkdir c:\installers
|
|
||||||
|
|
||||||
mkdir c:\temp
|
|
||||||
|
|
||||||
if not exist c:\installers\nasm-2.10.01-win32.zip curl -fSL -o c:\installers\nasm-2.10.01-win32.zip http://www.nasm.us/pub/nasm/releasebuilds/2.10.01/win32/nasm-2.10.01-win32.zip
|
|
||||||
|
|
||||||
7z x c:\installers\nasm-2.10.01-win32.zip -oc:\ > c:\installers\nasm.install.log
|
|
||||||
|
|
||||||
if not exist c:\installers\i686-6.4.0-release-posix-dwarf-rt_v5-rev0.7z curl -fSL -o c:\installers\i686-6.4.0-release-posix-dwarf-rt_v5-rev0.7z "https://sourceforge.net/projects/mingw-w64/files/Toolchains targetting Win32/Personal Builds/mingw-builds/6.4.0/threads-posix/dwarf/i686-6.4.0-release-posix-dwarf-rt_v5-rev0.7z"
|
|
||||||
|
|
||||||
md "c:\Program Files (x86)\mingw-w64\i686-6.4.0-posix-dwarf-rt_v5-rev0"
|
|
||||||
|
|
||||||
7z x c:\installers\i686-6.4.0-release-posix-dwarf-rt_v5-rev0.7z -o"c:\Program Files (x86)\mingw-w64\i686-6.4.0-posix-dwarf-rt_v5-rev0" > c:\installers\mingw32.install.log
|
|
||||||
|
|
||||||
if not exist c:\installers\x86_64-6.4.0-release-posix-seh-rt_v5-rev0.7z curl -fSL -o c:\installers\x86_64-6.4.0-release-posix-seh-rt_v5-rev0.7z "https://sourceforge.net/projects/mingw-w64/files/Toolchains targetting Win64/Personal Builds/mingw-builds/6.4.0/threads-posix/seh/x86_64-6.4.0-release-posix-seh-rt_v5-rev0.7z"
|
|
||||||
|
|
||||||
md "c:\Program Files\mingw-w64\x86_64-6.4.0-posix-seh-rt_v5-rev0"
|
|
||||||
|
|
||||||
7z x c:\installers\x86_64-6.4.0-release-posix-seh-rt_v5-rev0.7z -o"c:\Program Files\mingw-w64\x86_64-6.4.0-posix-seh-rt_v5-rev0" > c:\installers\mingw64.install.log
|
|
||||||
|
|
||||||
set PATH=c:\nasm-2.10.01;c:\Program Files (x86)\NSIS;c:\msys64\usr\bin;%PATH%
|
|
||||||
|
|
||||||
"c:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\bin\amd64\vcvars64.bat"
|
|
||||||
|
|
||||||
set INCLUDE
|
|
||||||
|
|
||||||
set LIB
|
|
||||||
|
|
||||||
set PATH
|
|
||||||
|
|
||||||
set MSYSTEM=MINGW32
|
|
||||||
|
|
||||||
mklink /d "%ProgramData%\Oracle\Java32" "c:\Program Files (x86)\Java\jdk1.6.0"
|
|
||||||
|
|
||||||
git clone --depth=1 https://github.com/libjpeg-turbo/buildscripts.git -b %APPVEYOR_REPO_BRANCH% c:/buildscripts
|
|
||||||
|
|
||||||
cache:
|
|
||||||
- c:\installers\nasm-2.10.01-win32.zip -> appveyor.yml
|
|
||||||
- c:\installers\i686-6.4.0-release-posix-dwarf-rt_v5-rev0.7z -> appveyor.yml
|
|
||||||
- c:\installers\x86_64-6.4.0-release-posix-seh-rt_v5-rev0.7z -> appveyor.yml
|
|
||||||
|
|
||||||
build_script:
|
|
||||||
- cmd: >-
|
|
||||||
for /f %%i in ('"cygpath %CD%"') do set MINGWPATH=%%i
|
|
||||||
|
|
||||||
bash c:/buildscripts/buildljt -d %MINGWPATH% -b /c/ljt.nightly -v
|
|
||||||
|
|
||||||
cmake --build . --target clean
|
|
||||||
|
|
||||||
md win64
|
|
||||||
|
|
||||||
cd win64
|
|
||||||
|
|
||||||
bash c:/buildscripts/setupscripts/win64 -DCMAKE_C_FLAGS='-DWIN32 -D_WINDOWS -W4 -wd4100 -wd4127 -wd4245 -wd4324 -wd4701 -wd4702 -wd4706 -WX'
|
|
||||||
|
|
||||||
cd ..
|
|
||||||
|
|
||||||
ninja
|
|
||||||
|
|
||||||
move c:\ljt.nightly\files\*.tar.gz .
|
|
||||||
|
|
||||||
move c:\ljt.nightly\files\*.exe .
|
|
||||||
|
|
||||||
move c:\ljt.nightly\files\*.html .
|
|
||||||
|
|
||||||
move c:\ljt.nightly\log-windows.txt .
|
|
||||||
|
|
||||||
artifacts:
|
|
||||||
- path: '*.tar.gz'
|
|
||||||
name: Source tarball
|
|
||||||
|
|
||||||
- path: '*-gcc*.exe'
|
|
||||||
name: SDK for MinGW
|
|
||||||
|
|
||||||
- path: '*-vc*.exe'
|
|
||||||
name: SDK for Visual C++
|
|
||||||
|
|
||||||
- path: 'log-windows.txt'
|
|
||||||
name: Build log
|
|
||||||
|
|
||||||
- path: 'index.html'
|
|
||||||
name: MD5 checksums
|
|
||||||
|
|
||||||
test: off
|
|
||||||
|
|
||||||
deploy:
|
|
||||||
provider: S3
|
|
||||||
access_key_id:
|
|
||||||
secure: Z74OYogQ6bNV/I+6b5ZEXig74+6MW2WLER0v/bPM/uk=
|
|
||||||
secret_access_key:
|
|
||||||
secure: cyGZhHVCFwZ9jgf5lXoW69mVtECmqwx3eLo61ha8ueWbMYlHho7lwDXwVvxOFiCa
|
|
||||||
bucket: libjpeg-turbo-pr
|
|
||||||
region:
|
|
||||||
secure: qSElYBgBRcEUf88M6Osthw==
|
|
||||||
folder: $(APPVEYOR_REPO_BRANCH)/windows
|
|
||||||
set_public: true
|
|
||||||
remove_files: true
|
|
||||||
123
android/extern/libjpeg-turbo/cderror.h
vendored
@@ -1,123 +0,0 @@
|
|||||||
/*
|
|
||||||
* cderror.h
|
|
||||||
*
|
|
||||||
* This file was part of the Independent JPEG Group's software:
|
|
||||||
* Copyright (C) 1994-1997, Thomas G. Lane.
|
|
||||||
* Modified 2009-2017 by Guido Vollbeding.
|
|
||||||
* libjpeg-turbo Modifications:
|
|
||||||
* Copyright (C) 2021, D. R. Commander.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file defines the error and message codes for the cjpeg/djpeg
|
|
||||||
* applications. These strings are not needed as part of the JPEG library
|
|
||||||
* proper.
|
|
||||||
* Edit this file to add new codes, or to translate the message strings to
|
|
||||||
* some other language.
|
|
||||||
*/
|
|
||||||
|
|
||||||
/*
|
|
||||||
* To define the enum list of message codes, include this file without
|
|
||||||
* defining macro JMESSAGE. To create a message string table, include it
|
|
||||||
* again with a suitable JMESSAGE definition (see jerror.c for an example).
|
|
||||||
*/
|
|
||||||
#ifndef JMESSAGE
|
|
||||||
#ifndef CDERROR_H
|
|
||||||
#define CDERROR_H
|
|
||||||
/* First time through, define the enum list */
|
|
||||||
#define JMAKE_ENUM_LIST
|
|
||||||
#else
|
|
||||||
/* Repeated inclusions of this file are no-ops unless JMESSAGE is defined */
|
|
||||||
#define JMESSAGE(code, string)
|
|
||||||
#endif /* CDERROR_H */
|
|
||||||
#endif /* JMESSAGE */
|
|
||||||
|
|
||||||
#ifdef JMAKE_ENUM_LIST
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
|
|
||||||
#define JMESSAGE(code, string) code,
|
|
||||||
|
|
||||||
#endif /* JMAKE_ENUM_LIST */
|
|
||||||
|
|
||||||
JMESSAGE(JMSG_FIRSTADDONCODE = 1000, NULL) /* Must be first entry! */
|
|
||||||
|
|
||||||
#ifdef BMP_SUPPORTED
|
|
||||||
JMESSAGE(JERR_BMP_BADCMAP, "Unsupported BMP colormap format")
|
|
||||||
JMESSAGE(JERR_BMP_BADDEPTH, "Only 8-, 24-, and 32-bit BMP files are supported")
|
|
||||||
JMESSAGE(JERR_BMP_BADHEADER, "Invalid BMP file: bad header length")
|
|
||||||
JMESSAGE(JERR_BMP_BADPLANES, "Invalid BMP file: biPlanes not equal to 1")
|
|
||||||
JMESSAGE(JERR_BMP_COLORSPACE, "BMP output must be grayscale or RGB")
|
|
||||||
JMESSAGE(JERR_BMP_COMPRESSED, "Sorry, compressed BMPs not yet supported")
|
|
||||||
JMESSAGE(JERR_BMP_EMPTY, "Empty BMP image")
|
|
||||||
JMESSAGE(JERR_BMP_NOT, "Not a BMP file - does not start with BM")
|
|
||||||
JMESSAGE(JERR_BMP_OUTOFRANGE, "Numeric value out of range in BMP file")
|
|
||||||
JMESSAGE(JTRC_BMP, "%ux%u %d-bit BMP image")
|
|
||||||
JMESSAGE(JTRC_BMP_MAPPED, "%ux%u 8-bit colormapped BMP image")
|
|
||||||
JMESSAGE(JTRC_BMP_OS2, "%ux%u %d-bit OS2 BMP image")
|
|
||||||
JMESSAGE(JTRC_BMP_OS2_MAPPED, "%ux%u 8-bit colormapped OS2 BMP image")
|
|
||||||
#endif /* BMP_SUPPORTED */
|
|
||||||
|
|
||||||
#ifdef GIF_SUPPORTED
|
|
||||||
JMESSAGE(JERR_GIF_BUG, "GIF output got confused")
|
|
||||||
JMESSAGE(JERR_GIF_CODESIZE, "Bogus GIF codesize %d")
|
|
||||||
JMESSAGE(JERR_GIF_COLORSPACE, "GIF output must be grayscale or RGB")
|
|
||||||
JMESSAGE(JERR_GIF_EMPTY, "Empty GIF image")
|
|
||||||
JMESSAGE(JERR_GIF_IMAGENOTFOUND, "Too few images in GIF file")
|
|
||||||
JMESSAGE(JERR_GIF_NOT, "Not a GIF file")
|
|
||||||
JMESSAGE(JTRC_GIF, "%ux%ux%d GIF image")
|
|
||||||
JMESSAGE(JTRC_GIF_BADVERSION,
|
|
||||||
"Warning: unexpected GIF version number '%c%c%c'")
|
|
||||||
JMESSAGE(JTRC_GIF_EXTENSION, "Ignoring GIF extension block of type 0x%02x")
|
|
||||||
JMESSAGE(JTRC_GIF_NONSQUARE, "Caution: nonsquare pixels in input")
|
|
||||||
JMESSAGE(JWRN_GIF_BADDATA, "Corrupt data in GIF file")
|
|
||||||
JMESSAGE(JWRN_GIF_CHAR, "Bogus char 0x%02x in GIF file, ignoring")
|
|
||||||
JMESSAGE(JWRN_GIF_ENDCODE, "Premature end of GIF image")
|
|
||||||
JMESSAGE(JWRN_GIF_NOMOREDATA, "Ran out of GIF bits")
|
|
||||||
#endif /* GIF_SUPPORTED */
|
|
||||||
|
|
||||||
#ifdef PPM_SUPPORTED
|
|
||||||
JMESSAGE(JERR_PPM_COLORSPACE, "PPM output must be grayscale or RGB")
|
|
||||||
JMESSAGE(JERR_PPM_NONNUMERIC, "Nonnumeric data in PPM file")
|
|
||||||
JMESSAGE(JERR_PPM_NOT, "Not a PPM/PGM file")
|
|
||||||
JMESSAGE(JERR_PPM_OUTOFRANGE, "Numeric value out of range in PPM file")
|
|
||||||
JMESSAGE(JTRC_PGM, "%ux%u PGM image")
|
|
||||||
JMESSAGE(JTRC_PGM_TEXT, "%ux%u text PGM image")
|
|
||||||
JMESSAGE(JTRC_PPM, "%ux%u PPM image")
|
|
||||||
JMESSAGE(JTRC_PPM_TEXT, "%ux%u text PPM image")
|
|
||||||
#endif /* PPM_SUPPORTED */
|
|
||||||
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
JMESSAGE(JERR_TGA_BADCMAP, "Unsupported Targa colormap format")
|
|
||||||
JMESSAGE(JERR_TGA_BADPARMS, "Invalid or unsupported Targa file")
|
|
||||||
JMESSAGE(JERR_TGA_COLORSPACE, "Targa output must be grayscale or RGB")
|
|
||||||
JMESSAGE(JTRC_TGA, "%ux%u RGB Targa image")
|
|
||||||
JMESSAGE(JTRC_TGA_GRAY, "%ux%u grayscale Targa image")
|
|
||||||
JMESSAGE(JTRC_TGA_MAPPED, "%ux%u colormapped Targa image")
|
|
||||||
#else
|
|
||||||
JMESSAGE(JERR_TGA_NOTCOMP, "Targa support was not compiled")
|
|
||||||
#endif /* TARGA_SUPPORTED */
|
|
||||||
|
|
||||||
JMESSAGE(JERR_BAD_CMAP_FILE,
|
|
||||||
"Color map file is invalid or of unsupported format")
|
|
||||||
JMESSAGE(JERR_TOO_MANY_COLORS,
|
|
||||||
"Output file format cannot handle %d colormap entries")
|
|
||||||
JMESSAGE(JERR_UNGETC_FAILED, "ungetc failed")
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
JMESSAGE(JERR_UNKNOWN_FORMAT,
|
|
||||||
"Unrecognized input file format --- perhaps you need -targa")
|
|
||||||
#else
|
|
||||||
JMESSAGE(JERR_UNKNOWN_FORMAT, "Unrecognized input file format")
|
|
||||||
#endif
|
|
||||||
JMESSAGE(JERR_UNSUPPORTED_FORMAT, "Unsupported output file format")
|
|
||||||
|
|
||||||
#ifdef JMAKE_ENUM_LIST
|
|
||||||
|
|
||||||
JMSG_LASTADDONCODE
|
|
||||||
} ADDON_MESSAGE_CODE;
|
|
||||||
|
|
||||||
#undef JMAKE_ENUM_LIST
|
|
||||||
#endif /* JMAKE_ENUM_LIST */
|
|
||||||
|
|
||||||
/* Zap JMESSAGE macro so that future re-inclusions do nothing by default */
|
|
||||||
#undef JMESSAGE
|
|
||||||
156
android/extern/libjpeg-turbo/cdjpeg.c
vendored
@@ -1,156 +0,0 @@
|
|||||||
/*
|
|
||||||
* cdjpeg.c
|
|
||||||
*
|
|
||||||
* This file was part of the Independent JPEG Group's software:
|
|
||||||
* Copyright (C) 1991-1997, Thomas G. Lane.
|
|
||||||
* libjpeg-turbo Modifications:
|
|
||||||
* Copyright (C) 2019, 2022, D. R. Commander.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file contains common support routines used by the IJG application
|
|
||||||
* programs (cjpeg, djpeg, jpegtran).
|
|
||||||
*/
|
|
||||||
|
|
||||||
#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */
|
|
||||||
#include <ctype.h> /* to declare isupper(), tolower() */
|
|
||||||
#ifdef USE_SETMODE
|
|
||||||
#include <fcntl.h> /* to declare setmode()'s parameter macros */
|
|
||||||
/* If you have setmode() but not <io.h>, just delete this line: */
|
|
||||||
#include <io.h> /* to declare setmode() */
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Optional progress monitor: display a percent-done figure on stderr.
|
|
||||||
*/
|
|
||||||
|
|
||||||
METHODDEF(void)
|
|
||||||
progress_monitor(j_common_ptr cinfo)
|
|
||||||
{
|
|
||||||
cd_progress_ptr prog = (cd_progress_ptr)cinfo->progress;
|
|
||||||
|
|
||||||
if (prog->max_scans != 0 && cinfo->is_decompressor) {
|
|
||||||
int scan_no = ((j_decompress_ptr)cinfo)->input_scan_number;
|
|
||||||
|
|
||||||
if (scan_no > (int)prog->max_scans) {
|
|
||||||
fprintf(stderr, "Scan number %d exceeds maximum scans (%u)\n", scan_no,
|
|
||||||
prog->max_scans);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (prog->report) {
|
|
||||||
int total_passes = prog->pub.total_passes + prog->total_extra_passes;
|
|
||||||
int percent_done =
|
|
||||||
(int)(prog->pub.pass_counter * 100L / prog->pub.pass_limit);
|
|
||||||
|
|
||||||
if (percent_done != prog->percent_done) {
|
|
||||||
prog->percent_done = percent_done;
|
|
||||||
if (total_passes > 1) {
|
|
||||||
fprintf(stderr, "\rPass %d/%d: %3d%% ",
|
|
||||||
prog->pub.completed_passes + prog->completed_extra_passes + 1,
|
|
||||||
total_passes, percent_done);
|
|
||||||
} else {
|
|
||||||
fprintf(stderr, "\r %3d%% ", percent_done);
|
|
||||||
}
|
|
||||||
fflush(stderr);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
GLOBAL(void)
|
|
||||||
start_progress_monitor(j_common_ptr cinfo, cd_progress_ptr progress)
|
|
||||||
{
|
|
||||||
/* Enable progress display, unless trace output is on */
|
|
||||||
if (cinfo->err->trace_level == 0) {
|
|
||||||
progress->pub.progress_monitor = progress_monitor;
|
|
||||||
progress->completed_extra_passes = 0;
|
|
||||||
progress->total_extra_passes = 0;
|
|
||||||
progress->max_scans = 0;
|
|
||||||
progress->report = FALSE;
|
|
||||||
progress->percent_done = -1;
|
|
||||||
cinfo->progress = &progress->pub;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
GLOBAL(void)
|
|
||||||
end_progress_monitor(j_common_ptr cinfo)
|
|
||||||
{
|
|
||||||
/* Clear away progress display */
|
|
||||||
if (cinfo->err->trace_level == 0) {
|
|
||||||
fprintf(stderr, "\r \r");
|
|
||||||
fflush(stderr);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Case-insensitive matching of possibly-abbreviated keyword switches.
|
|
||||||
* keyword is the constant keyword (must be lower case already),
|
|
||||||
* minchars is length of minimum legal abbreviation.
|
|
||||||
*/
|
|
||||||
|
|
||||||
GLOBAL(boolean)
|
|
||||||
keymatch(char *arg, const char *keyword, int minchars)
|
|
||||||
{
|
|
||||||
register int ca, ck;
|
|
||||||
register int nmatched = 0;
|
|
||||||
|
|
||||||
while ((ca = *arg++) != '\0') {
|
|
||||||
if ((ck = *keyword++) == '\0')
|
|
||||||
return FALSE; /* arg longer than keyword, no good */
|
|
||||||
if (isupper(ca)) /* force arg to lcase (assume ck is already) */
|
|
||||||
ca = tolower(ca);
|
|
||||||
if (ca != ck)
|
|
||||||
return FALSE; /* no good */
|
|
||||||
nmatched++; /* count matched characters */
|
|
||||||
}
|
|
||||||
/* reached end of argument; fail if it's too short for unique abbrev */
|
|
||||||
if (nmatched < minchars)
|
|
||||||
return FALSE;
|
|
||||||
return TRUE; /* A-OK */
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Routines to establish binary I/O mode for stdin and stdout.
|
|
||||||
* Non-Unix systems often require some hacking to get out of text mode.
|
|
||||||
*/
|
|
||||||
|
|
||||||
GLOBAL(FILE *)
|
|
||||||
read_stdin(void)
|
|
||||||
{
|
|
||||||
FILE *input_file = stdin;
|
|
||||||
|
|
||||||
#ifdef USE_SETMODE /* need to hack file mode? */
|
|
||||||
setmode(fileno(stdin), O_BINARY);
|
|
||||||
#endif
|
|
||||||
#ifdef USE_FDOPEN /* need to re-open in binary mode? */
|
|
||||||
if ((input_file = fdopen(fileno(stdin), READ_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "Cannot reopen stdin\n");
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
return input_file;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
GLOBAL(FILE *)
|
|
||||||
write_stdout(void)
|
|
||||||
{
|
|
||||||
FILE *output_file = stdout;
|
|
||||||
|
|
||||||
#ifdef USE_SETMODE /* need to hack file mode? */
|
|
||||||
setmode(fileno(stdout), O_BINARY);
|
|
||||||
#endif
|
|
||||||
#ifdef USE_FDOPEN /* need to re-open in binary mode? */
|
|
||||||
if ((output_file = fdopen(fileno(stdout), WRITE_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "Cannot reopen stdout\n");
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
#endif
|
|
||||||
return output_file;
|
|
||||||
}
|
|
||||||
161
android/extern/libjpeg-turbo/cdjpeg.h
vendored
@@ -1,161 +0,0 @@
|
|||||||
/*
|
|
||||||
* cdjpeg.h
|
|
||||||
*
|
|
||||||
* This file was part of the Independent JPEG Group's software:
|
|
||||||
* Copyright (C) 1994-1997, Thomas G. Lane.
|
|
||||||
* Modified 2019 by Guido Vollbeding.
|
|
||||||
* libjpeg-turbo Modifications:
|
|
||||||
* Copyright (C) 2017, 2019, 2021, D. R. Commander.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file contains common declarations for the sample applications
|
|
||||||
* cjpeg and djpeg. It is NOT used by the core JPEG library.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#define JPEG_CJPEG_DJPEG /* define proper options in jconfig.h */
|
|
||||||
#define JPEG_INTERNAL_OPTIONS /* cjpeg.c,djpeg.c need to see xxx_SUPPORTED */
|
|
||||||
#include "jinclude.h"
|
|
||||||
#include "jpeglib.h"
|
|
||||||
#include "jerror.h" /* get library error codes too */
|
|
||||||
#include "cderror.h" /* get application-specific error codes */
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Object interface for cjpeg's source file decoding modules
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef struct cjpeg_source_struct *cjpeg_source_ptr;
|
|
||||||
|
|
||||||
struct cjpeg_source_struct {
|
|
||||||
void (*start_input) (j_compress_ptr cinfo, cjpeg_source_ptr sinfo);
|
|
||||||
JDIMENSION (*get_pixel_rows) (j_compress_ptr cinfo, cjpeg_source_ptr sinfo);
|
|
||||||
void (*finish_input) (j_compress_ptr cinfo, cjpeg_source_ptr sinfo);
|
|
||||||
|
|
||||||
FILE *input_file;
|
|
||||||
|
|
||||||
JSAMPARRAY buffer;
|
|
||||||
JDIMENSION buffer_height;
|
|
||||||
#ifdef FUZZING_BUILD_MODE_UNSAFE_FOR_PRODUCTION
|
|
||||||
JDIMENSION max_pixels;
|
|
||||||
#endif
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Object interface for djpeg's output file encoding modules
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef struct djpeg_dest_struct *djpeg_dest_ptr;
|
|
||||||
|
|
||||||
struct djpeg_dest_struct {
|
|
||||||
/* start_output is called after jpeg_start_decompress finishes.
|
|
||||||
* The color map will be ready at this time, if one is needed.
|
|
||||||
*/
|
|
||||||
void (*start_output) (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo);
|
|
||||||
/* Emit the specified number of pixel rows from the buffer. */
|
|
||||||
void (*put_pixel_rows) (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo,
|
|
||||||
JDIMENSION rows_supplied);
|
|
||||||
/* Finish up at the end of the image. */
|
|
||||||
void (*finish_output) (j_decompress_ptr cinfo, djpeg_dest_ptr dinfo);
|
|
||||||
/* Re-calculate buffer dimensions based on output dimensions (for use with
|
|
||||||
partial image decompression.) If this is NULL, then the output format
|
|
||||||
does not support partial image decompression (BMP, in particular, cannot
|
|
||||||
support partial decompression because it uses an inversion buffer to write
|
|
||||||
the image in bottom-up order.) */
|
|
||||||
void (*calc_buffer_dimensions) (j_decompress_ptr cinfo,
|
|
||||||
djpeg_dest_ptr dinfo);
|
|
||||||
|
|
||||||
|
|
||||||
/* Target file spec; filled in by djpeg.c after object is created. */
|
|
||||||
FILE *output_file;
|
|
||||||
|
|
||||||
/* Output pixel-row buffer. Created by module init or start_output.
|
|
||||||
* Width is cinfo->output_width * cinfo->output_components;
|
|
||||||
* height is buffer_height.
|
|
||||||
*/
|
|
||||||
JSAMPARRAY buffer;
|
|
||||||
JDIMENSION buffer_height;
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* cjpeg/djpeg may need to perform extra passes to convert to or from
|
|
||||||
* the source/destination file format. The JPEG library does not know
|
|
||||||
* about these passes, but we'd like them to be counted by the progress
|
|
||||||
* monitor. We use an expanded progress monitor object to hold the
|
|
||||||
* additional pass count.
|
|
||||||
*/
|
|
||||||
|
|
||||||
struct cdjpeg_progress_mgr {
|
|
||||||
struct jpeg_progress_mgr pub; /* fields known to JPEG library */
|
|
||||||
int completed_extra_passes; /* extra passes completed */
|
|
||||||
int total_extra_passes; /* total extra */
|
|
||||||
JDIMENSION max_scans; /* abort if the number of scans exceeds this
|
|
||||||
value and the value is non-zero */
|
|
||||||
boolean report; /* whether or not to report progress */
|
|
||||||
/* last printed percentage stored here to avoid multiple printouts */
|
|
||||||
int percent_done;
|
|
||||||
};
|
|
||||||
|
|
||||||
typedef struct cdjpeg_progress_mgr *cd_progress_ptr;
|
|
||||||
|
|
||||||
|
|
||||||
/* Module selection routines for I/O modules. */
|
|
||||||
|
|
||||||
EXTERN(cjpeg_source_ptr) jinit_read_bmp(j_compress_ptr cinfo,
|
|
||||||
boolean use_inversion_array);
|
|
||||||
EXTERN(djpeg_dest_ptr) jinit_write_bmp(j_decompress_ptr cinfo, boolean is_os2,
|
|
||||||
boolean use_inversion_array);
|
|
||||||
EXTERN(cjpeg_source_ptr) jinit_read_gif(j_compress_ptr cinfo);
|
|
||||||
EXTERN(djpeg_dest_ptr) jinit_write_gif(j_decompress_ptr cinfo, boolean is_lzw);
|
|
||||||
EXTERN(cjpeg_source_ptr) jinit_read_ppm(j_compress_ptr cinfo);
|
|
||||||
EXTERN(djpeg_dest_ptr) jinit_write_ppm(j_decompress_ptr cinfo);
|
|
||||||
EXTERN(cjpeg_source_ptr) jinit_read_targa(j_compress_ptr cinfo);
|
|
||||||
EXTERN(djpeg_dest_ptr) jinit_write_targa(j_decompress_ptr cinfo);
|
|
||||||
|
|
||||||
/* cjpeg support routines (in rdswitch.c) */
|
|
||||||
|
|
||||||
EXTERN(boolean) read_quant_tables(j_compress_ptr cinfo, char *filename,
|
|
||||||
boolean force_baseline);
|
|
||||||
EXTERN(boolean) read_scan_script(j_compress_ptr cinfo, char *filename);
|
|
||||||
EXTERN(boolean) set_quality_ratings(j_compress_ptr cinfo, char *arg,
|
|
||||||
boolean force_baseline);
|
|
||||||
EXTERN(boolean) set_quant_slots(j_compress_ptr cinfo, char *arg);
|
|
||||||
EXTERN(boolean) set_sample_factors(j_compress_ptr cinfo, char *arg);
|
|
||||||
|
|
||||||
/* djpeg support routines (in rdcolmap.c) */
|
|
||||||
|
|
||||||
EXTERN(void) read_color_map(j_decompress_ptr cinfo, FILE *infile);
|
|
||||||
|
|
||||||
/* common support routines (in cdjpeg.c) */
|
|
||||||
|
|
||||||
EXTERN(void) start_progress_monitor(j_common_ptr cinfo,
|
|
||||||
cd_progress_ptr progress);
|
|
||||||
EXTERN(void) end_progress_monitor(j_common_ptr cinfo);
|
|
||||||
EXTERN(boolean) keymatch(char *arg, const char *keyword, int minchars);
|
|
||||||
EXTERN(FILE *) read_stdin(void);
|
|
||||||
EXTERN(FILE *) write_stdout(void);
|
|
||||||
|
|
||||||
/* miscellaneous useful macros */
|
|
||||||
|
|
||||||
#ifdef DONT_USE_B_MODE /* define mode parameters for fopen() */
|
|
||||||
#define READ_BINARY "r"
|
|
||||||
#define WRITE_BINARY "w"
|
|
||||||
#else
|
|
||||||
#define READ_BINARY "rb"
|
|
||||||
#define WRITE_BINARY "wb"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef EXIT_FAILURE /* define exit() codes if not provided */
|
|
||||||
#define EXIT_FAILURE 1
|
|
||||||
#endif
|
|
||||||
#ifndef EXIT_SUCCESS
|
|
||||||
#define EXIT_SUCCESS 0
|
|
||||||
#endif
|
|
||||||
#ifndef EXIT_WARNING
|
|
||||||
#define EXIT_WARNING 2
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#define IsExtRGB(cs) \
|
|
||||||
(cs == JCS_RGB || (cs >= JCS_EXT_RGB && cs <= JCS_EXT_ARGB))
|
|
||||||
361
android/extern/libjpeg-turbo/cjpeg.1
vendored
@@ -1,361 +0,0 @@
|
|||||||
.TH CJPEG 1 "30 November 2021"
|
|
||||||
.SH NAME
|
|
||||||
cjpeg \- compress an image file to a JPEG file
|
|
||||||
.SH SYNOPSIS
|
|
||||||
.B cjpeg
|
|
||||||
[
|
|
||||||
.I options
|
|
||||||
]
|
|
||||||
[
|
|
||||||
.I filename
|
|
||||||
]
|
|
||||||
.LP
|
|
||||||
.SH DESCRIPTION
|
|
||||||
.LP
|
|
||||||
.B cjpeg
|
|
||||||
compresses the named image file, or the standard input if no file is
|
|
||||||
named, and produces a JPEG/JFIF file on the standard output.
|
|
||||||
The currently supported input file formats are: PPM (PBMPLUS color
|
|
||||||
format), PGM (PBMPLUS grayscale format), BMP, GIF, and Targa.
|
|
||||||
.SH OPTIONS
|
|
||||||
All switch names may be abbreviated; for example,
|
|
||||||
.B \-grayscale
|
|
||||||
may be written
|
|
||||||
.B \-gray
|
|
||||||
or
|
|
||||||
.BR \-gr .
|
|
||||||
Most of the "basic" switches can be abbreviated to as little as one letter.
|
|
||||||
Upper and lower case are equivalent (thus
|
|
||||||
.B \-BMP
|
|
||||||
is the same as
|
|
||||||
.BR \-bmp ).
|
|
||||||
British spellings are also accepted (e.g.,
|
|
||||||
.BR \-greyscale ),
|
|
||||||
though for brevity these are not mentioned below.
|
|
||||||
.PP
|
|
||||||
The basic switches are:
|
|
||||||
.TP
|
|
||||||
.BI \-quality " N[,...]"
|
|
||||||
Scale quantization tables to adjust image quality. Quality is 0 (worst) to
|
|
||||||
100 (best); default is 75. (See below for more info.)
|
|
||||||
.TP
|
|
||||||
.B \-grayscale
|
|
||||||
Create monochrome JPEG file from color input. By saying
|
|
||||||
.BR \-grayscale,
|
|
||||||
you'll get a smaller JPEG file that takes less time to process.
|
|
||||||
.TP
|
|
||||||
.B \-rgb
|
|
||||||
Create RGB JPEG file.
|
|
||||||
Using this switch suppresses the conversion from RGB
|
|
||||||
colorspace input to the default YCbCr JPEG colorspace.
|
|
||||||
.TP
|
|
||||||
.B \-optimize
|
|
||||||
Perform optimization of entropy encoding parameters. Without this, default
|
|
||||||
encoding parameters are used.
|
|
||||||
.B \-optimize
|
|
||||||
usually makes the JPEG file a little smaller, but
|
|
||||||
.B cjpeg
|
|
||||||
runs somewhat slower and needs much more memory. Image quality and speed of
|
|
||||||
decompression are unaffected by
|
|
||||||
.BR \-optimize .
|
|
||||||
.TP
|
|
||||||
.B \-progressive
|
|
||||||
Create progressive JPEG file (see below).
|
|
||||||
.TP
|
|
||||||
.B \-targa
|
|
||||||
Input file is Targa format. Targa files that contain an "identification"
|
|
||||||
field will not be automatically recognized by
|
|
||||||
.BR cjpeg ;
|
|
||||||
for such files you must specify
|
|
||||||
.B \-targa
|
|
||||||
to make
|
|
||||||
.B cjpeg
|
|
||||||
treat the input as Targa format.
|
|
||||||
For most Targa files, you won't need this switch.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-quality
|
|
||||||
switch lets you trade off compressed file size against quality of the
|
|
||||||
reconstructed image: the higher the quality setting, the larger the JPEG file,
|
|
||||||
and the closer the output image will be to the original input. Normally you
|
|
||||||
want to use the lowest quality setting (smallest file) that decompresses into
|
|
||||||
something visually indistinguishable from the original image. For this
|
|
||||||
purpose the quality setting should generally be between 50 and 95 (the default
|
|
||||||
is 75) for photographic images. If you see defects at
|
|
||||||
.B \-quality
|
|
||||||
75, then go up 5 or 10 counts at a time until you are happy with the output
|
|
||||||
image. (The optimal setting will vary from one image to another.)
|
|
||||||
.PP
|
|
||||||
.B \-quality
|
|
||||||
100 will generate a quantization table of all 1's, minimizing loss in the
|
|
||||||
quantization step (but there is still information loss in subsampling, as well
|
|
||||||
as roundoff error.) For most images, specifying a quality value above
|
|
||||||
about 95 will increase the size of the compressed file dramatically, and while
|
|
||||||
the quality gain from these higher quality values is measurable (using metrics
|
|
||||||
such as PSNR or SSIM), it is rarely perceivable by human vision.
|
|
||||||
.PP
|
|
||||||
In the other direction, quality values below 50 will produce very small files
|
|
||||||
of low image quality. Settings around 5 to 10 might be useful in preparing an
|
|
||||||
index of a large image library, for example. Try
|
|
||||||
.B \-quality
|
|
||||||
2 (or so) for some amusing Cubist effects. (Note: quality
|
|
||||||
values below about 25 generate 2-byte quantization tables, which are
|
|
||||||
considered optional in the JPEG standard.
|
|
||||||
.B cjpeg
|
|
||||||
emits a warning message when you give such a quality value, because some
|
|
||||||
other JPEG programs may be unable to decode the resulting file. Use
|
|
||||||
.B \-baseline
|
|
||||||
if you need to ensure compatibility at low quality values.)
|
|
||||||
.PP
|
|
||||||
The \fB-quality\fR option has been extended in this version of \fBcjpeg\fR to
|
|
||||||
support separate quality settings for luminance and chrominance (or, in
|
|
||||||
general, separate settings for every quantization table slot.) The principle
|
|
||||||
is the same as chrominance subsampling: since the human eye is more sensitive
|
|
||||||
to spatial changes in brightness than spatial changes in color, the chrominance
|
|
||||||
components can be quantized more than the luminance components without
|
|
||||||
incurring any visible image quality loss. However, unlike subsampling, this
|
|
||||||
feature reduces data in the frequency domain instead of the spatial domain,
|
|
||||||
which allows for more fine-grained control. This option is useful in
|
|
||||||
quality-sensitive applications, for which the artifacts generated by
|
|
||||||
subsampling may be unacceptable.
|
|
||||||
.PP
|
|
||||||
The \fB-quality\fR option accepts a comma-separated list of parameters, which
|
|
||||||
respectively refer to the quality levels that should be assigned to the
|
|
||||||
quantization table slots. If there are more q-table slots than parameters,
|
|
||||||
then the last parameter is replicated. Thus, if only one quality parameter is
|
|
||||||
given, this is used for both luminance and chrominance (slots 0 and 1,
|
|
||||||
respectively), preserving the legacy behavior of cjpeg v6b and prior.
|
|
||||||
More (or customized) quantization tables can be set with the \fB-qtables\fR
|
|
||||||
option and assigned to components with the \fB-qslots\fR option (see the
|
|
||||||
"wizard" switches below.)
|
|
||||||
.PP
|
|
||||||
JPEG files generated with separate luminance and chrominance quality are fully
|
|
||||||
compliant with standard JPEG decoders.
|
|
||||||
.PP
|
|
||||||
.BR CAUTION:
|
|
||||||
For this setting to be useful, be sure to pass an argument of \fB-sample 1x1\fR
|
|
||||||
to \fBcjpeg\fR to disable chrominance subsampling. Otherwise, the default
|
|
||||||
subsampling level (2x2, AKA "4:2:0") will be used.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-progressive
|
|
||||||
switch creates a "progressive JPEG" file. In this type of JPEG file, the data
|
|
||||||
is stored in multiple scans of increasing quality. If the file is being
|
|
||||||
transmitted over a slow communications link, the decoder can use the first
|
|
||||||
scan to display a low-quality image very quickly, and can then improve the
|
|
||||||
display with each subsequent scan. The final image is exactly equivalent to a
|
|
||||||
standard JPEG file of the same quality setting, and the total file size is
|
|
||||||
about the same --- often a little smaller.
|
|
||||||
.PP
|
|
||||||
Switches for advanced users:
|
|
||||||
.TP
|
|
||||||
.B \-arithmetic
|
|
||||||
Use arithmetic coding.
|
|
||||||
.B Caution:
|
|
||||||
arithmetic coded JPEG is not yet widely implemented, so many decoders will be
|
|
||||||
unable to view an arithmetic coded JPEG file at all.
|
|
||||||
.TP
|
|
||||||
.B \-dct int
|
|
||||||
Use accurate integer DCT method (default).
|
|
||||||
.TP
|
|
||||||
.B \-dct fast
|
|
||||||
Use less accurate integer DCT method [legacy feature].
|
|
||||||
When the Independent JPEG Group's software was first released in 1991, the
|
|
||||||
compression time for a 1-megapixel JPEG image on a mainstream PC was measured
|
|
||||||
in minutes. Thus, the \fBfast\fR integer DCT algorithm provided noticeable
|
|
||||||
performance benefits. On modern CPUs running libjpeg-turbo, however, the
|
|
||||||
compression time for a 1-megapixel JPEG image is measured in milliseconds, and
|
|
||||||
thus the performance benefits of the \fBfast\fR algorithm are much less
|
|
||||||
noticeable. On modern x86/x86-64 CPUs that support AVX2 instructions, the
|
|
||||||
\fBfast\fR and \fBint\fR methods have similar performance. On other types of
|
|
||||||
CPUs, the \fBfast\fR method is generally about 5-15% faster than the \fBint\fR
|
|
||||||
method.
|
|
||||||
|
|
||||||
For quality levels of 90 and below, there should be little or no perceptible
|
|
||||||
quality difference between the two algorithms. For quality levels above 90,
|
|
||||||
however, the difference between the \fBfast\fR and \fBint\fR methods becomes
|
|
||||||
more pronounced. With quality=97, for instance, the \fBfast\fR method incurs
|
|
||||||
generally about a 1-3 dB loss in PSNR relative to the \fBint\fR method, but
|
|
||||||
this can be larger for some images. Do not use the \fBfast\fR method with
|
|
||||||
quality levels above 97. The algorithm often degenerates at quality=98 and
|
|
||||||
above and can actually produce a more lossy image than if lower quality levels
|
|
||||||
had been used. Also, in libjpeg-turbo, the \fBfast\fR method is not fully
|
|
||||||
accelerated for quality levels above 97, so it will be slower than the
|
|
||||||
\fBint\fR method.
|
|
||||||
.TP
|
|
||||||
.B \-dct float
|
|
||||||
Use floating-point DCT method [legacy feature].
|
|
||||||
The \fBfloat\fR method does not produce significantly more accurate results
|
|
||||||
than the \fBint\fR method, and it is much slower. The \fBfloat\fR method may
|
|
||||||
also give different results on different machines due to varying roundoff
|
|
||||||
behavior, whereas the integer methods should give the same results on all
|
|
||||||
machines.
|
|
||||||
.TP
|
|
||||||
.BI \-icc " file"
|
|
||||||
Embed ICC color management profile contained in the specified file.
|
|
||||||
.TP
|
|
||||||
.BI \-restart " N"
|
|
||||||
Emit a JPEG restart marker every N MCU rows, or every N MCU blocks if "B" is
|
|
||||||
attached to the number.
|
|
||||||
.B \-restart 0
|
|
||||||
(the default) means no restart markers.
|
|
||||||
.TP
|
|
||||||
.BI \-smooth " N"
|
|
||||||
Smooth the input image to eliminate dithering noise. N, ranging from 1 to
|
|
||||||
100, indicates the strength of smoothing. 0 (the default) means no smoothing.
|
|
||||||
.TP
|
|
||||||
.BI \-maxmemory " N"
|
|
||||||
Set limit for amount of memory to use in processing large images. Value is
|
|
||||||
in thousands of bytes, or millions of bytes if "M" is attached to the
|
|
||||||
number. For example,
|
|
||||||
.B \-max 4m
|
|
||||||
selects 4000000 bytes. If more space is needed, an error will occur.
|
|
||||||
.TP
|
|
||||||
.BI \-outfile " name"
|
|
||||||
Send output image to the named file, not to standard output.
|
|
||||||
.TP
|
|
||||||
.BI \-memdst
|
|
||||||
Compress to memory instead of a file. This feature was implemented mainly as a
|
|
||||||
way of testing the in-memory destination manager (jpeg_mem_dest()), but it is
|
|
||||||
also useful for benchmarking, since it reduces the I/O overhead.
|
|
||||||
.TP
|
|
||||||
.BI \-report
|
|
||||||
Report compression progress.
|
|
||||||
.TP
|
|
||||||
.BI \-strict
|
|
||||||
Treat all warnings as fatal. Enabling this option will cause the compressor to
|
|
||||||
abort if an LZW-compressed GIF input image contains incomplete or corrupt image
|
|
||||||
data.
|
|
||||||
.TP
|
|
||||||
.B \-verbose
|
|
||||||
Enable debug printout. More
|
|
||||||
.BR \-v 's
|
|
||||||
give more output. Also, version information is printed at startup.
|
|
||||||
.TP
|
|
||||||
.B \-debug
|
|
||||||
Same as
|
|
||||||
.BR \-verbose .
|
|
||||||
.TP
|
|
||||||
.B \-version
|
|
||||||
Print version information and exit.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-restart
|
|
||||||
option inserts extra markers that allow a JPEG decoder to resynchronize after
|
|
||||||
a transmission error. Without restart markers, any damage to a compressed
|
|
||||||
file will usually ruin the image from the point of the error to the end of the
|
|
||||||
image; with restart markers, the damage is usually confined to the portion of
|
|
||||||
the image up to the next restart marker. Of course, the restart markers
|
|
||||||
occupy extra space. We recommend
|
|
||||||
.B \-restart 1
|
|
||||||
for images that will be transmitted across unreliable networks such as Usenet.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-smooth
|
|
||||||
option filters the input to eliminate fine-scale noise. This is often useful
|
|
||||||
when converting dithered images to JPEG: a moderate smoothing factor of 10 to
|
|
||||||
50 gets rid of dithering patterns in the input file, resulting in a smaller
|
|
||||||
JPEG file and a better-looking image. Too large a smoothing factor will
|
|
||||||
visibly blur the image, however.
|
|
||||||
.PP
|
|
||||||
Switches for wizards:
|
|
||||||
.TP
|
|
||||||
.B \-baseline
|
|
||||||
Force baseline-compatible quantization tables to be generated. This clamps
|
|
||||||
quantization values to 8 bits even at low quality settings. (This switch is
|
|
||||||
poorly named, since it does not ensure that the output is actually baseline
|
|
||||||
JPEG. For example, you can use
|
|
||||||
.B \-baseline
|
|
||||||
and
|
|
||||||
.B \-progressive
|
|
||||||
together.)
|
|
||||||
.TP
|
|
||||||
.BI \-qtables " file"
|
|
||||||
Use the quantization tables given in the specified text file.
|
|
||||||
.TP
|
|
||||||
.BI \-qslots " N[,...]"
|
|
||||||
Select which quantization table to use for each color component.
|
|
||||||
.TP
|
|
||||||
.BI \-sample " HxV[,...]"
|
|
||||||
Set JPEG sampling factors for each color component.
|
|
||||||
.TP
|
|
||||||
.BI \-scans " file"
|
|
||||||
Use the scan script given in the specified text file.
|
|
||||||
.PP
|
|
||||||
The "wizard" switches are intended for experimentation with JPEG. If you
|
|
||||||
don't know what you are doing, \fBdon't use them\fR. These switches are
|
|
||||||
documented further in the file wizard.txt.
|
|
||||||
.SH EXAMPLES
|
|
||||||
.LP
|
|
||||||
This example compresses the PPM file foo.ppm with a quality factor of
|
|
||||||
60 and saves the output as foo.jpg:
|
|
||||||
.IP
|
|
||||||
.B cjpeg \-quality
|
|
||||||
.I 60 foo.ppm
|
|
||||||
.B >
|
|
||||||
.I foo.jpg
|
|
||||||
.SH HINTS
|
|
||||||
Color GIF files are not the ideal input for JPEG; JPEG is really intended for
|
|
||||||
compressing full-color (24-bit) images. In particular, don't try to convert
|
|
||||||
cartoons, line drawings, and other images that have only a few distinct
|
|
||||||
colors. GIF works great on these, JPEG does not. If you want to convert a
|
|
||||||
GIF to JPEG, you should experiment with
|
|
||||||
.BR cjpeg 's
|
|
||||||
.B \-quality
|
|
||||||
and
|
|
||||||
.B \-smooth
|
|
||||||
options to get a satisfactory conversion.
|
|
||||||
.B \-smooth 10
|
|
||||||
or so is often helpful.
|
|
||||||
.PP
|
|
||||||
Avoid running an image through a series of JPEG compression/decompression
|
|
||||||
cycles. Image quality loss will accumulate; after ten or so cycles the image
|
|
||||||
may be noticeably worse than it was after one cycle. It's best to use a
|
|
||||||
lossless format while manipulating an image, then convert to JPEG format when
|
|
||||||
you are ready to file the image away.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-optimize
|
|
||||||
option to
|
|
||||||
.B cjpeg
|
|
||||||
is worth using when you are making a "final" version for posting or archiving.
|
|
||||||
It's also a win when you are using low quality settings to make very small
|
|
||||||
JPEG files; the percentage improvement is often a lot more than it is on
|
|
||||||
larger files. (At present,
|
|
||||||
.B \-optimize
|
|
||||||
mode is always selected when generating progressive JPEG files.)
|
|
||||||
.SH ENVIRONMENT
|
|
||||||
.TP
|
|
||||||
.B JPEGMEM
|
|
||||||
If this environment variable is set, its value is the default memory limit.
|
|
||||||
The value is specified as described for the
|
|
||||||
.B \-maxmemory
|
|
||||||
switch.
|
|
||||||
.B JPEGMEM
|
|
||||||
overrides the default value specified when the program was compiled, and
|
|
||||||
itself is overridden by an explicit
|
|
||||||
.BR \-maxmemory .
|
|
||||||
.SH SEE ALSO
|
|
||||||
.BR djpeg (1),
|
|
||||||
.BR jpegtran (1),
|
|
||||||
.BR rdjpgcom (1),
|
|
||||||
.BR wrjpgcom (1)
|
|
||||||
.br
|
|
||||||
.BR ppm (5),
|
|
||||||
.BR pgm (5)
|
|
||||||
.br
|
|
||||||
Wallace, Gregory K. "The JPEG Still Picture Compression Standard",
|
|
||||||
Communications of the ACM, April 1991 (vol. 34, no. 4), pp. 30-44.
|
|
||||||
.SH AUTHOR
|
|
||||||
Independent JPEG Group
|
|
||||||
.PP
|
|
||||||
This file was modified by The libjpeg-turbo Project to include only information
|
|
||||||
relevant to libjpeg-turbo, to wordsmith certain sections, and to describe
|
|
||||||
features not present in libjpeg.
|
|
||||||
.SH ISSUES
|
|
||||||
Not all variants of BMP and Targa file formats are supported.
|
|
||||||
.PP
|
|
||||||
The
|
|
||||||
.B \-targa
|
|
||||||
switch is not a bug, it's a feature. (It would be a bug if the Targa format
|
|
||||||
designers had not been clueless.)
|
|
||||||
762
android/extern/libjpeg-turbo/cjpeg.c
vendored
@@ -1,762 +0,0 @@
|
|||||||
/*
|
|
||||||
* cjpeg.c
|
|
||||||
*
|
|
||||||
* This file was part of the Independent JPEG Group's software:
|
|
||||||
* Copyright (C) 1991-1998, Thomas G. Lane.
|
|
||||||
* Modified 2003-2011 by Guido Vollbeding.
|
|
||||||
* libjpeg-turbo Modifications:
|
|
||||||
* Copyright (C) 2010, 2013-2014, 2017, 2019-2022, D. R. Commander.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file contains a command-line user interface for the JPEG compressor.
|
|
||||||
* It should work on any system with Unix- or MS-DOS-style command lines.
|
|
||||||
*
|
|
||||||
* Two different command line styles are permitted, depending on the
|
|
||||||
* compile-time switch TWO_FILE_COMMANDLINE:
|
|
||||||
* cjpeg [options] inputfile outputfile
|
|
||||||
* cjpeg [options] [inputfile]
|
|
||||||
* In the second style, output is always to standard output, which you'd
|
|
||||||
* normally redirect to a file or pipe to some other program. Input is
|
|
||||||
* either from a named file or from standard input (typically redirected).
|
|
||||||
* The second style is convenient on Unix but is unhelpful on systems that
|
|
||||||
* don't support pipes. Also, you MUST use the first style if your system
|
|
||||||
* doesn't do binary I/O to stdin/stdout.
|
|
||||||
* To simplify script writing, the "-outfile" switch is provided. The syntax
|
|
||||||
* cjpeg [options] -outfile outputfile inputfile
|
|
||||||
* works regardless of which command line style is used.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifdef _MSC_VER
|
|
||||||
#define _CRT_SECURE_NO_DEPRECATE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
#define JPEG_INTERNALS
|
|
||||||
#endif
|
|
||||||
#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */
|
|
||||||
#include "jversion.h" /* for version message */
|
|
||||||
#include "jconfigint.h"
|
|
||||||
|
|
||||||
|
|
||||||
/* Create the add-on message string table. */
|
|
||||||
|
|
||||||
#define JMESSAGE(code, string) string,
|
|
||||||
|
|
||||||
static const char * const cdjpeg_message_table[] = {
|
|
||||||
#include "cderror.h"
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* This routine determines what format the input file is,
|
|
||||||
* and selects the appropriate input-reading module.
|
|
||||||
*
|
|
||||||
* To determine which family of input formats the file belongs to,
|
|
||||||
* we may look only at the first byte of the file, since C does not
|
|
||||||
* guarantee that more than one character can be pushed back with ungetc.
|
|
||||||
* Looking at additional bytes would require one of these approaches:
|
|
||||||
* 1) assume we can fseek() the input file (fails for piped input);
|
|
||||||
* 2) assume we can push back more than one character (works in
|
|
||||||
* some C implementations, but unportable);
|
|
||||||
* 3) provide our own buffering (breaks input readers that want to use
|
|
||||||
* stdio directly);
|
|
||||||
* or 4) don't put back the data, and modify the input_init methods to assume
|
|
||||||
* they start reading after the start of file.
|
|
||||||
* #1 is attractive for MS-DOS but is untenable on Unix.
|
|
||||||
*
|
|
||||||
* The most portable solution for file types that can't be identified by their
|
|
||||||
* first byte is to make the user tell us what they are. This is also the
|
|
||||||
* only approach for "raw" file types that contain only arbitrary values.
|
|
||||||
* We presently apply this method for Targa files. Most of the time Targa
|
|
||||||
* files start with 0x00, so we recognize that case. Potentially, however,
|
|
||||||
* a Targa file could start with any byte value (byte 0 is the length of the
|
|
||||||
* seldom-used ID field), so we provide a switch to force Targa input mode.
|
|
||||||
*/
|
|
||||||
|
|
||||||
static boolean is_targa; /* records user -targa switch */
|
|
||||||
|
|
||||||
|
|
||||||
LOCAL(cjpeg_source_ptr)
|
|
||||||
select_file_type(j_compress_ptr cinfo, FILE *infile)
|
|
||||||
{
|
|
||||||
int c;
|
|
||||||
|
|
||||||
if (is_targa) {
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
return jinit_read_targa(cinfo);
|
|
||||||
#else
|
|
||||||
ERREXIT(cinfo, JERR_TGA_NOTCOMP);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
if ((c = getc(infile)) == EOF)
|
|
||||||
ERREXIT(cinfo, JERR_INPUT_EMPTY);
|
|
||||||
if (ungetc(c, infile) == EOF)
|
|
||||||
ERREXIT(cinfo, JERR_UNGETC_FAILED);
|
|
||||||
|
|
||||||
switch (c) {
|
|
||||||
#ifdef BMP_SUPPORTED
|
|
||||||
case 'B':
|
|
||||||
return jinit_read_bmp(cinfo, TRUE);
|
|
||||||
#endif
|
|
||||||
#ifdef GIF_SUPPORTED
|
|
||||||
case 'G':
|
|
||||||
return jinit_read_gif(cinfo);
|
|
||||||
#endif
|
|
||||||
#ifdef PPM_SUPPORTED
|
|
||||||
case 'P':
|
|
||||||
return jinit_read_ppm(cinfo);
|
|
||||||
#endif
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
case 0x00:
|
|
||||||
return jinit_read_targa(cinfo);
|
|
||||||
#endif
|
|
||||||
default:
|
|
||||||
ERREXIT(cinfo, JERR_UNKNOWN_FORMAT);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
return NULL; /* suppress compiler warnings */
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Argument-parsing code.
|
|
||||||
* The switch parser is designed to be useful with DOS-style command line
|
|
||||||
* syntax, ie, intermixed switches and file names, where only the switches
|
|
||||||
* to the left of a given file name affect processing of that file.
|
|
||||||
* The main program in this file doesn't actually use this capability...
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
static const char *progname; /* program name for error messages */
|
|
||||||
static char *icc_filename; /* for -icc switch */
|
|
||||||
static char *outfilename; /* for -outfile switch */
|
|
||||||
boolean memdst; /* for -memdst switch */
|
|
||||||
boolean report; /* for -report switch */
|
|
||||||
boolean strict; /* for -strict switch */
|
|
||||||
|
|
||||||
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
|
|
||||||
#include <setjmp.h>
|
|
||||||
|
|
||||||
struct my_error_mgr {
|
|
||||||
struct jpeg_error_mgr pub;
|
|
||||||
jmp_buf setjmp_buffer;
|
|
||||||
};
|
|
||||||
|
|
||||||
void my_error_exit(j_common_ptr cinfo)
|
|
||||||
{
|
|
||||||
struct my_error_mgr *myerr = (struct my_error_mgr *)cinfo->err;
|
|
||||||
|
|
||||||
longjmp(myerr->setjmp_buffer, 1);
|
|
||||||
}
|
|
||||||
|
|
||||||
static void my_emit_message_fuzzer(j_common_ptr cinfo, int msg_level)
|
|
||||||
{
|
|
||||||
if (msg_level < 0)
|
|
||||||
cinfo->err->num_warnings++;
|
|
||||||
}
|
|
||||||
|
|
||||||
#define HANDLE_ERROR() { \
|
|
||||||
if (cinfo.global_state > CSTATE_START) { \
|
|
||||||
if (memdst && outbuffer) \
|
|
||||||
(*cinfo.dest->term_destination) (&cinfo); \
|
|
||||||
jpeg_abort_compress(&cinfo); \
|
|
||||||
} \
|
|
||||||
jpeg_destroy_compress(&cinfo); \
|
|
||||||
if (input_file != stdin && input_file != NULL) \
|
|
||||||
fclose(input_file); \
|
|
||||||
if (memdst) \
|
|
||||||
free(outbuffer); \
|
|
||||||
return EXIT_FAILURE; \
|
|
||||||
}
|
|
||||||
|
|
||||||
#endif
|
|
||||||
|
|
||||||
|
|
||||||
LOCAL(void)
|
|
||||||
usage(void)
|
|
||||||
/* complain about bad command line */
|
|
||||||
{
|
|
||||||
fprintf(stderr, "usage: %s [switches] ", progname);
|
|
||||||
#ifdef TWO_FILE_COMMANDLINE
|
|
||||||
fprintf(stderr, "inputfile outputfile\n");
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "[inputfile]\n");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
fprintf(stderr, "Switches (names may be abbreviated):\n");
|
|
||||||
fprintf(stderr, " -quality N[,...] Compression quality (0..100; 5-95 is most useful range,\n");
|
|
||||||
fprintf(stderr, " default is 75)\n");
|
|
||||||
fprintf(stderr, " -grayscale Create monochrome JPEG file\n");
|
|
||||||
fprintf(stderr, " -rgb Create RGB JPEG file\n");
|
|
||||||
#ifdef ENTROPY_OPT_SUPPORTED
|
|
||||||
fprintf(stderr, " -optimize Optimize Huffman table (smaller file, but slow compression)\n");
|
|
||||||
#endif
|
|
||||||
#ifdef C_PROGRESSIVE_SUPPORTED
|
|
||||||
fprintf(stderr, " -progressive Create progressive JPEG file\n");
|
|
||||||
#endif
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
fprintf(stderr, " -targa Input file is Targa format (usually not needed)\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, "Switches for advanced users:\n");
|
|
||||||
#ifdef C_ARITH_CODING_SUPPORTED
|
|
||||||
fprintf(stderr, " -arithmetic Use arithmetic coding\n");
|
|
||||||
#endif
|
|
||||||
#ifdef DCT_ISLOW_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct int Use accurate integer DCT method%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_ISLOW ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef DCT_IFAST_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct fast Use less accurate integer DCT method [legacy feature]%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_IFAST ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef DCT_FLOAT_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct float Use floating-point DCT method [legacy feature]%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_FLOAT ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -icc FILE Embed ICC profile contained in FILE\n");
|
|
||||||
fprintf(stderr, " -restart N Set restart interval in rows, or in blocks with B\n");
|
|
||||||
#ifdef INPUT_SMOOTHING_SUPPORTED
|
|
||||||
fprintf(stderr, " -smooth N Smooth dithered input (N=1..100 is strength)\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -maxmemory N Maximum memory to use (in kbytes)\n");
|
|
||||||
fprintf(stderr, " -outfile name Specify name for output file\n");
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
fprintf(stderr, " -memdst Compress to memory instead of file (useful for benchmarking)\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -report Report compression progress\n");
|
|
||||||
fprintf(stderr, " -strict Treat all warnings as fatal\n");
|
|
||||||
fprintf(stderr, " -verbose or -debug Emit debug output\n");
|
|
||||||
fprintf(stderr, " -version Print version information and exit\n");
|
|
||||||
fprintf(stderr, "Switches for wizards:\n");
|
|
||||||
fprintf(stderr, " -baseline Force baseline quantization tables\n");
|
|
||||||
fprintf(stderr, " -qtables FILE Use quantization tables given in FILE\n");
|
|
||||||
fprintf(stderr, " -qslots N[,...] Set component quantization tables\n");
|
|
||||||
fprintf(stderr, " -sample HxV[,...] Set component sampling factors\n");
|
|
||||||
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
|
||||||
fprintf(stderr, " -scans FILE Create multi-scan JPEG per script FILE\n");
|
|
||||||
#endif
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
LOCAL(int)
|
|
||||||
parse_switches(j_compress_ptr cinfo, int argc, char **argv,
|
|
||||||
int last_file_arg_seen, boolean for_real)
|
|
||||||
/* Parse optional switches.
|
|
||||||
* Returns argv[] index of first file-name argument (== argc if none).
|
|
||||||
* Any file names with indexes <= last_file_arg_seen are ignored;
|
|
||||||
* they have presumably been processed in a previous iteration.
|
|
||||||
* (Pass 0 for last_file_arg_seen on the first or only iteration.)
|
|
||||||
* for_real is FALSE on the first (dummy) pass; we may skip any expensive
|
|
||||||
* processing.
|
|
||||||
*/
|
|
||||||
{
|
|
||||||
int argn;
|
|
||||||
char *arg;
|
|
||||||
boolean force_baseline;
|
|
||||||
boolean simple_progressive;
|
|
||||||
char *qualityarg = NULL; /* saves -quality parm if any */
|
|
||||||
char *qtablefile = NULL; /* saves -qtables filename if any */
|
|
||||||
char *qslotsarg = NULL; /* saves -qslots parm if any */
|
|
||||||
char *samplearg = NULL; /* saves -sample parm if any */
|
|
||||||
char *scansarg = NULL; /* saves -scans parm if any */
|
|
||||||
|
|
||||||
/* Set up default JPEG parameters. */
|
|
||||||
|
|
||||||
force_baseline = FALSE; /* by default, allow 16-bit quantizers */
|
|
||||||
simple_progressive = FALSE;
|
|
||||||
is_targa = FALSE;
|
|
||||||
icc_filename = NULL;
|
|
||||||
outfilename = NULL;
|
|
||||||
memdst = FALSE;
|
|
||||||
report = FALSE;
|
|
||||||
strict = FALSE;
|
|
||||||
cinfo->err->trace_level = 0;
|
|
||||||
|
|
||||||
/* Scan command line options, adjust parameters */
|
|
||||||
|
|
||||||
for (argn = 1; argn < argc; argn++) {
|
|
||||||
arg = argv[argn];
|
|
||||||
if (*arg != '-') {
|
|
||||||
/* Not a switch, must be a file name argument */
|
|
||||||
if (argn <= last_file_arg_seen) {
|
|
||||||
outfilename = NULL; /* -outfile applies to just one input file */
|
|
||||||
continue; /* ignore this name if previously processed */
|
|
||||||
}
|
|
||||||
break; /* else done parsing switches */
|
|
||||||
}
|
|
||||||
arg++; /* advance past switch marker character */
|
|
||||||
|
|
||||||
if (keymatch(arg, "arithmetic", 1)) {
|
|
||||||
/* Use arithmetic coding. */
|
|
||||||
#ifdef C_ARITH_CODING_SUPPORTED
|
|
||||||
cinfo->arith_code = TRUE;
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, arithmetic coding not supported\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "baseline", 1)) {
|
|
||||||
/* Force baseline-compatible output (8-bit quantizer values). */
|
|
||||||
force_baseline = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "dct", 2)) {
|
|
||||||
/* Select DCT algorithm. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (keymatch(argv[argn], "int", 1)) {
|
|
||||||
cinfo->dct_method = JDCT_ISLOW;
|
|
||||||
} else if (keymatch(argv[argn], "fast", 2)) {
|
|
||||||
cinfo->dct_method = JDCT_IFAST;
|
|
||||||
} else if (keymatch(argv[argn], "float", 2)) {
|
|
||||||
cinfo->dct_method = JDCT_FLOAT;
|
|
||||||
} else
|
|
||||||
usage();
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) {
|
|
||||||
/* Enable debug printouts. */
|
|
||||||
/* On first -d, print version identification */
|
|
||||||
static boolean printed_version = FALSE;
|
|
||||||
|
|
||||||
if (!printed_version) {
|
|
||||||
fprintf(stderr, "%s version %s (build %s)\n",
|
|
||||||
PACKAGE_NAME, VERSION, BUILD);
|
|
||||||
fprintf(stderr, "%s\n\n", JCOPYRIGHT);
|
|
||||||
fprintf(stderr, "Emulating The Independent JPEG Group's software, version %s\n\n",
|
|
||||||
JVERSION);
|
|
||||||
printed_version = TRUE;
|
|
||||||
}
|
|
||||||
cinfo->err->trace_level++;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "version", 4)) {
|
|
||||||
fprintf(stderr, "%s version %s (build %s)\n",
|
|
||||||
PACKAGE_NAME, VERSION, BUILD);
|
|
||||||
exit(EXIT_SUCCESS);
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "grayscale", 2) ||
|
|
||||||
keymatch(arg, "greyscale", 2)) {
|
|
||||||
/* Force a monochrome JPEG file to be generated. */
|
|
||||||
jpeg_set_colorspace(cinfo, JCS_GRAYSCALE);
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "rgb", 3)) {
|
|
||||||
/* Force an RGB JPEG file to be generated. */
|
|
||||||
jpeg_set_colorspace(cinfo, JCS_RGB);
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "icc", 1)) {
|
|
||||||
/* Set ICC filename. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
icc_filename = argv[argn];
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "maxmemory", 3)) {
|
|
||||||
/* Maximum memory in Kb (or Mb with 'm'). */
|
|
||||||
long lval;
|
|
||||||
char ch = 'x';
|
|
||||||
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%ld%c", &lval, &ch) < 1)
|
|
||||||
usage();
|
|
||||||
if (ch == 'm' || ch == 'M')
|
|
||||||
lval *= 1000L;
|
|
||||||
cinfo->mem->max_memory_to_use = lval * 1000L;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "optimize", 1) || keymatch(arg, "optimise", 1)) {
|
|
||||||
/* Enable entropy parm optimization. */
|
|
||||||
#ifdef ENTROPY_OPT_SUPPORTED
|
|
||||||
cinfo->optimize_coding = TRUE;
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, entropy optimization was not compiled in\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "outfile", 4)) {
|
|
||||||
/* Set output file name. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
outfilename = argv[argn]; /* save it away for later use */
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "progressive", 1)) {
|
|
||||||
/* Select simple progressive mode. */
|
|
||||||
#ifdef C_PROGRESSIVE_SUPPORTED
|
|
||||||
simple_progressive = TRUE;
|
|
||||||
/* We must postpone execution until num_components is known. */
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, progressive output was not compiled in\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "memdst", 2)) {
|
|
||||||
/* Use in-memory destination manager */
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
memdst = TRUE;
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, in-memory destination manager was not compiled in\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "quality", 1)) {
|
|
||||||
/* Quality ratings (quantization table scaling factors). */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
qualityarg = argv[argn];
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "qslots", 2)) {
|
|
||||||
/* Quantization table slot numbers. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
qslotsarg = argv[argn];
|
|
||||||
/* Must delay setting qslots until after we have processed any
|
|
||||||
* colorspace-determining switches, since jpeg_set_colorspace sets
|
|
||||||
* default quant table numbers.
|
|
||||||
*/
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "qtables", 2)) {
|
|
||||||
/* Quantization tables fetched from file. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
qtablefile = argv[argn];
|
|
||||||
/* We postpone actually reading the file in case -quality comes later. */
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "report", 3)) {
|
|
||||||
report = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "restart", 1)) {
|
|
||||||
/* Restart interval in MCU rows (or in MCUs with 'b'). */
|
|
||||||
long lval;
|
|
||||||
char ch = 'x';
|
|
||||||
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%ld%c", &lval, &ch) < 1)
|
|
||||||
usage();
|
|
||||||
if (lval < 0 || lval > 65535L)
|
|
||||||
usage();
|
|
||||||
if (ch == 'b' || ch == 'B') {
|
|
||||||
cinfo->restart_interval = (unsigned int)lval;
|
|
||||||
cinfo->restart_in_rows = 0; /* else prior '-restart n' overrides me */
|
|
||||||
} else {
|
|
||||||
cinfo->restart_in_rows = (int)lval;
|
|
||||||
/* restart_interval will be computed during startup */
|
|
||||||
}
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "sample", 2)) {
|
|
||||||
/* Set sampling factors. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
samplearg = argv[argn];
|
|
||||||
/* Must delay setting sample factors until after we have processed any
|
|
||||||
* colorspace-determining switches, since jpeg_set_colorspace sets
|
|
||||||
* default sampling factors.
|
|
||||||
*/
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "scans", 4)) {
|
|
||||||
/* Set scan script. */
|
|
||||||
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
scansarg = argv[argn];
|
|
||||||
/* We must postpone reading the file in case -progressive appears. */
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, multi-scan output was not compiled in\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "smooth", 2)) {
|
|
||||||
/* Set input smoothing factor. */
|
|
||||||
int val;
|
|
||||||
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%d", &val) != 1)
|
|
||||||
usage();
|
|
||||||
if (val < 0 || val > 100)
|
|
||||||
usage();
|
|
||||||
cinfo->smoothing_factor = val;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "strict", 2)) {
|
|
||||||
strict = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "targa", 1)) {
|
|
||||||
/* Input file is Targa format. */
|
|
||||||
is_targa = TRUE;
|
|
||||||
|
|
||||||
} else {
|
|
||||||
usage(); /* bogus switch */
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Post-switch-scanning cleanup */
|
|
||||||
|
|
||||||
if (for_real) {
|
|
||||||
|
|
||||||
/* Set quantization tables for selected quality. */
|
|
||||||
/* Some or all may be overridden if -qtables is present. */
|
|
||||||
if (qualityarg != NULL) /* process -quality if it was present */
|
|
||||||
if (!set_quality_ratings(cinfo, qualityarg, force_baseline))
|
|
||||||
usage();
|
|
||||||
|
|
||||||
if (qtablefile != NULL) /* process -qtables if it was present */
|
|
||||||
if (!read_quant_tables(cinfo, qtablefile, force_baseline))
|
|
||||||
usage();
|
|
||||||
|
|
||||||
if (qslotsarg != NULL) /* process -qslots if it was present */
|
|
||||||
if (!set_quant_slots(cinfo, qslotsarg))
|
|
||||||
usage();
|
|
||||||
|
|
||||||
if (samplearg != NULL) /* process -sample if it was present */
|
|
||||||
if (!set_sample_factors(cinfo, samplearg))
|
|
||||||
usage();
|
|
||||||
|
|
||||||
#ifdef C_PROGRESSIVE_SUPPORTED
|
|
||||||
if (simple_progressive) /* process -progressive; -scans can override */
|
|
||||||
jpeg_simple_progression(cinfo);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifdef C_MULTISCAN_FILES_SUPPORTED
|
|
||||||
if (scansarg != NULL) /* process -scans if it was present */
|
|
||||||
if (!read_scan_script(cinfo, scansarg))
|
|
||||||
usage();
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
return argn; /* return index of next arg (file name) */
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
METHODDEF(void)
|
|
||||||
my_emit_message(j_common_ptr cinfo, int msg_level)
|
|
||||||
{
|
|
||||||
if (msg_level < 0) {
|
|
||||||
/* Treat warning as fatal */
|
|
||||||
cinfo->err->error_exit(cinfo);
|
|
||||||
} else {
|
|
||||||
if (cinfo->err->trace_level >= msg_level)
|
|
||||||
cinfo->err->output_message(cinfo);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The main program.
|
|
||||||
*/
|
|
||||||
|
|
||||||
int
|
|
||||||
main(int argc, char **argv)
|
|
||||||
{
|
|
||||||
struct jpeg_compress_struct cinfo;
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
struct my_error_mgr myerr;
|
|
||||||
struct jpeg_error_mgr &jerr = myerr.pub;
|
|
||||||
#else
|
|
||||||
struct jpeg_error_mgr jerr;
|
|
||||||
#endif
|
|
||||||
struct cdjpeg_progress_mgr progress;
|
|
||||||
int file_index;
|
|
||||||
cjpeg_source_ptr src_mgr;
|
|
||||||
FILE *input_file = NULL;
|
|
||||||
FILE *icc_file;
|
|
||||||
JOCTET *icc_profile = NULL;
|
|
||||||
long icc_len = 0;
|
|
||||||
FILE *output_file = NULL;
|
|
||||||
unsigned char *outbuffer = NULL;
|
|
||||||
unsigned long outsize = 0;
|
|
||||||
JDIMENSION num_scanlines;
|
|
||||||
|
|
||||||
progname = argv[0];
|
|
||||||
if (progname == NULL || progname[0] == 0)
|
|
||||||
progname = "cjpeg"; /* in case C library doesn't provide it */
|
|
||||||
|
|
||||||
/* Initialize the JPEG compression object with default error handling. */
|
|
||||||
cinfo.err = jpeg_std_error(&jerr);
|
|
||||||
jpeg_create_compress(&cinfo);
|
|
||||||
/* Add some application-specific error messages (from cderror.h) */
|
|
||||||
jerr.addon_message_table = cdjpeg_message_table;
|
|
||||||
jerr.first_addon_message = JMSG_FIRSTADDONCODE;
|
|
||||||
jerr.last_addon_message = JMSG_LASTADDONCODE;
|
|
||||||
|
|
||||||
/* Initialize JPEG parameters.
|
|
||||||
* Much of this may be overridden later.
|
|
||||||
* In particular, we don't yet know the input file's color space,
|
|
||||||
* but we need to provide some value for jpeg_set_defaults() to work.
|
|
||||||
*/
|
|
||||||
|
|
||||||
cinfo.in_color_space = JCS_RGB; /* arbitrary guess */
|
|
||||||
jpeg_set_defaults(&cinfo);
|
|
||||||
|
|
||||||
/* Scan command line to find file names.
|
|
||||||
* It is convenient to use just one switch-parsing routine, but the switch
|
|
||||||
* values read here are ignored; we will rescan the switches after opening
|
|
||||||
* the input file.
|
|
||||||
*/
|
|
||||||
|
|
||||||
file_index = parse_switches(&cinfo, argc, argv, 0, FALSE);
|
|
||||||
|
|
||||||
if (strict)
|
|
||||||
jerr.emit_message = my_emit_message;
|
|
||||||
|
|
||||||
#ifdef TWO_FILE_COMMANDLINE
|
|
||||||
if (!memdst) {
|
|
||||||
/* Must have either -outfile switch or explicit output file name */
|
|
||||||
if (outfilename == NULL) {
|
|
||||||
if (file_index != argc - 2) {
|
|
||||||
fprintf(stderr, "%s: must name one input and one output file\n",
|
|
||||||
progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
outfilename = argv[file_index + 1];
|
|
||||||
} else {
|
|
||||||
if (file_index != argc - 1) {
|
|
||||||
fprintf(stderr, "%s: must name one input and one output file\n",
|
|
||||||
progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
/* Unix style: expect zero or one file name */
|
|
||||||
if (file_index < argc - 1) {
|
|
||||||
fprintf(stderr, "%s: only one input file\n", progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
#endif /* TWO_FILE_COMMANDLINE */
|
|
||||||
|
|
||||||
/* Open the input file. */
|
|
||||||
if (file_index < argc) {
|
|
||||||
if ((input_file = fopen(argv[file_index], READ_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, argv[file_index]);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* default input file is stdin */
|
|
||||||
input_file = read_stdin();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Open the output file. */
|
|
||||||
if (outfilename != NULL) {
|
|
||||||
if ((output_file = fopen(outfilename, WRITE_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, outfilename);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
} else if (!memdst) {
|
|
||||||
/* default output file is stdout */
|
|
||||||
output_file = write_stdout();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (icc_filename != NULL) {
|
|
||||||
if ((icc_file = fopen(icc_filename, READ_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, icc_filename);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
if (fseek(icc_file, 0, SEEK_END) < 0 ||
|
|
||||||
(icc_len = ftell(icc_file)) < 1 ||
|
|
||||||
fseek(icc_file, 0, SEEK_SET) < 0) {
|
|
||||||
fprintf(stderr, "%s: can't determine size of %s\n", progname,
|
|
||||||
icc_filename);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
if ((icc_profile = (JOCTET *)malloc(icc_len)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't allocate memory for ICC profile\n", progname);
|
|
||||||
fclose(icc_file);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
if (fread(icc_profile, icc_len, 1, icc_file) < 1) {
|
|
||||||
fprintf(stderr, "%s: can't read ICC profile from %s\n", progname,
|
|
||||||
icc_filename);
|
|
||||||
free(icc_profile);
|
|
||||||
fclose(icc_file);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
fclose(icc_file);
|
|
||||||
}
|
|
||||||
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
jerr.error_exit = my_error_exit;
|
|
||||||
jerr.emit_message = my_emit_message_fuzzer;
|
|
||||||
if (setjmp(myerr.setjmp_buffer))
|
|
||||||
HANDLE_ERROR()
|
|
||||||
#endif
|
|
||||||
|
|
||||||
if (report) {
|
|
||||||
start_progress_monitor((j_common_ptr)&cinfo, &progress);
|
|
||||||
progress.report = report;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Figure out the input file format, and set up to read it. */
|
|
||||||
src_mgr = select_file_type(&cinfo, input_file);
|
|
||||||
src_mgr->input_file = input_file;
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
src_mgr->max_pixels = 1048576;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Read the input file header to obtain file size & colorspace. */
|
|
||||||
(*src_mgr->start_input) (&cinfo, src_mgr);
|
|
||||||
|
|
||||||
/* Now that we know input colorspace, fix colorspace-dependent defaults */
|
|
||||||
jpeg_default_colorspace(&cinfo);
|
|
||||||
|
|
||||||
/* Adjust default compression parameters by re-parsing the options */
|
|
||||||
file_index = parse_switches(&cinfo, argc, argv, 0, TRUE);
|
|
||||||
|
|
||||||
/* Specify data destination for compression */
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
if (memdst)
|
|
||||||
jpeg_mem_dest(&cinfo, &outbuffer, &outsize);
|
|
||||||
else
|
|
||||||
#endif
|
|
||||||
jpeg_stdio_dest(&cinfo, output_file);
|
|
||||||
|
|
||||||
#ifdef CJPEG_FUZZER
|
|
||||||
if (setjmp(myerr.setjmp_buffer))
|
|
||||||
HANDLE_ERROR()
|
|
||||||
#endif
|
|
||||||
|
|
||||||
/* Start compressor */
|
|
||||||
jpeg_start_compress(&cinfo, TRUE);
|
|
||||||
|
|
||||||
if (icc_profile != NULL)
|
|
||||||
jpeg_write_icc_profile(&cinfo, icc_profile, (unsigned int)icc_len);
|
|
||||||
|
|
||||||
/* Process data */
|
|
||||||
while (cinfo.next_scanline < cinfo.image_height) {
|
|
||||||
num_scanlines = (*src_mgr->get_pixel_rows) (&cinfo, src_mgr);
|
|
||||||
(void)jpeg_write_scanlines(&cinfo, src_mgr->buffer, num_scanlines);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Finish compression and release memory */
|
|
||||||
(*src_mgr->finish_input) (&cinfo, src_mgr);
|
|
||||||
jpeg_finish_compress(&cinfo);
|
|
||||||
jpeg_destroy_compress(&cinfo);
|
|
||||||
|
|
||||||
/* Close files, if we opened them */
|
|
||||||
if (input_file != stdin)
|
|
||||||
fclose(input_file);
|
|
||||||
if (output_file != stdout && output_file != NULL)
|
|
||||||
fclose(output_file);
|
|
||||||
|
|
||||||
if (report)
|
|
||||||
end_progress_monitor((j_common_ptr)&cinfo);
|
|
||||||
|
|
||||||
if (memdst) {
|
|
||||||
#ifndef CJPEG_FUZZER
|
|
||||||
fprintf(stderr, "Compressed size: %lu bytes\n", outsize);
|
|
||||||
#endif
|
|
||||||
free(outbuffer);
|
|
||||||
}
|
|
||||||
|
|
||||||
free(icc_profile);
|
|
||||||
|
|
||||||
/* All done. */
|
|
||||||
return (jerr.num_warnings ? EXIT_WARNING : EXIT_SUCCESS);
|
|
||||||
}
|
|
||||||
@@ -1,176 +0,0 @@
|
|||||||
# This file is included from the top-level CMakeLists.txt. We just store it
|
|
||||||
# here to avoid cluttering up that file.
|
|
||||||
|
|
||||||
###############################################################################
|
|
||||||
# Linux RPM and DEB
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
if(CMAKE_SYSTEM_NAME STREQUAL "Linux")
|
|
||||||
|
|
||||||
set(RPMARCH ${CMAKE_SYSTEM_PROCESSOR})
|
|
||||||
if(CPU_TYPE STREQUAL "x86_64")
|
|
||||||
set(DEBARCH amd64)
|
|
||||||
elseif(CPU_TYPE STREQUAL "arm64")
|
|
||||||
set(DEBARCH ${CPU_TYPE})
|
|
||||||
elseif(CPU_TYPE STREQUAL "arm")
|
|
||||||
check_c_source_compiles("
|
|
||||||
#if __ARM_PCS_VFP != 1
|
|
||||||
#error \"float ABI != hard\"
|
|
||||||
#endif
|
|
||||||
int main(void) { return 0; }" HAVE_HARD_FLOAT)
|
|
||||||
if(HAVE_HARD_FLOAT)
|
|
||||||
set(RPMARCH armv7hl)
|
|
||||||
set(DEBARCH armhf)
|
|
||||||
else()
|
|
||||||
set(RPMARCH armel)
|
|
||||||
set(DEBARCH armel)
|
|
||||||
endif()
|
|
||||||
elseif(CMAKE_SYSTEM_PROCESSOR_LC STREQUAL "ppc64le")
|
|
||||||
set(DEBARCH ppc64el)
|
|
||||||
elseif(CPU_TYPE STREQUAL "powerpc" AND BITS EQUAL 32)
|
|
||||||
set(RPMARCH ppc)
|
|
||||||
set(DEBARCH ppc)
|
|
||||||
else()
|
|
||||||
set(DEBARCH ${CMAKE_SYSTEM_PROCESSOR})
|
|
||||||
endif()
|
|
||||||
message(STATUS "RPM architecture = ${RPMARCH}, DEB architecture = ${DEBARCH}")
|
|
||||||
|
|
||||||
# Re-set CMAKE_POSITION_INDEPENDENT_CODE so that the RPM spec file works
|
|
||||||
# properly
|
|
||||||
boolean_number(CMAKE_POSITION_INDEPENDENT_CODE)
|
|
||||||
|
|
||||||
configure_file(release/makerpm.in pkgscripts/makerpm)
|
|
||||||
configure_file(release/rpm.spec.in pkgscripts/rpm.spec @ONLY)
|
|
||||||
|
|
||||||
add_custom_target(rpm pkgscripts/makerpm
|
|
||||||
SOURCES pkgscripts/makerpm)
|
|
||||||
|
|
||||||
configure_file(release/makesrpm.in pkgscripts/makesrpm)
|
|
||||||
|
|
||||||
add_custom_target(srpm pkgscripts/makesrpm
|
|
||||||
SOURCES pkgscripts/makesrpm
|
|
||||||
DEPENDS dist)
|
|
||||||
|
|
||||||
configure_file(release/makedpkg.in pkgscripts/makedpkg)
|
|
||||||
configure_file(release/deb-control.in pkgscripts/deb-control)
|
|
||||||
|
|
||||||
add_custom_target(deb pkgscripts/makedpkg
|
|
||||||
SOURCES pkgscripts/makedpkg)
|
|
||||||
|
|
||||||
endif() # Linux
|
|
||||||
|
|
||||||
|
|
||||||
###############################################################################
|
|
||||||
# Windows installer (NullSoft Installer)
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
if(WIN32)
|
|
||||||
|
|
||||||
if(MSVC)
|
|
||||||
set(INST_PLATFORM "Visual C++")
|
|
||||||
set(INST_ID vc)
|
|
||||||
set(INST_NAME ${CMAKE_PROJECT_NAME}-${VERSION}-${INST_ID})
|
|
||||||
set(INST_REG_NAME ${CMAKE_PROJECT_NAME})
|
|
||||||
elseif(MINGW)
|
|
||||||
set(INST_PLATFORM GCC)
|
|
||||||
set(INST_ID gcc)
|
|
||||||
set(INST_NAME ${CMAKE_PROJECT_NAME}-${VERSION}-${INST_ID})
|
|
||||||
set(INST_REG_NAME ${CMAKE_PROJECT_NAME}-${INST_ID})
|
|
||||||
set(INST_DEFS -DGCC)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if(BITS EQUAL 64)
|
|
||||||
set(INST_PLATFORM "${INST_PLATFORM} 64-bit")
|
|
||||||
set(INST_NAME ${INST_NAME}64)
|
|
||||||
set(INST_REG_NAME ${INST_REG_NAME}64)
|
|
||||||
set(INST_DEFS ${INST_DEFS} -DWIN64)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if(WITH_JAVA)
|
|
||||||
set(INST_DEFS ${INST_DEFS} -DJAVA)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
if(GENERATOR_IS_MULTI_CONFIG)
|
|
||||||
set(INST_DEFS ${INST_DEFS} "-DBUILDDIR=${CMAKE_CFG_INTDIR}\\")
|
|
||||||
else()
|
|
||||||
set(INST_DEFS ${INST_DEFS} "-DBUILDDIR=")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
string(REGEX REPLACE "/" "\\\\" INST_DIR ${CMAKE_INSTALL_PREFIX})
|
|
||||||
|
|
||||||
configure_file(release/installer.nsi.in installer.nsi @ONLY)
|
|
||||||
# TODO: It would be nice to eventually switch to CPack and eliminate this mess,
|
|
||||||
# but not today.
|
|
||||||
configure_file(win/projectTargets.cmake.in
|
|
||||||
win/${CMAKE_PROJECT_NAME}Targets.cmake @ONLY)
|
|
||||||
configure_file(win/${INST_ID}/projectTargets-release.cmake.in
|
|
||||||
win/${CMAKE_PROJECT_NAME}Targets-release.cmake @ONLY)
|
|
||||||
|
|
||||||
if(WITH_JAVA)
|
|
||||||
set(JAVA_DEPEND turbojpeg-java)
|
|
||||||
endif()
|
|
||||||
if(WITH_TURBOJPEG)
|
|
||||||
set(TURBOJPEG_DEPEND turbojpeg turbojpeg-static tjbench)
|
|
||||||
endif()
|
|
||||||
add_custom_target(installer
|
|
||||||
makensis -nocd ${INST_DEFS} installer.nsi
|
|
||||||
DEPENDS jpeg jpeg-static rdjpgcom wrjpgcom cjpeg djpeg jpegtran
|
|
||||||
${JAVA_DEPEND} ${TURBOJPEG_DEPEND}
|
|
||||||
SOURCES installer.nsi)
|
|
||||||
|
|
||||||
endif() # WIN32
|
|
||||||
|
|
||||||
|
|
||||||
###############################################################################
|
|
||||||
# Mac DMG
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
if(APPLE)
|
|
||||||
|
|
||||||
set(ARMV8_BUILD "" CACHE PATH
|
|
||||||
"Directory containing Armv8 iOS or macOS build to include in universal binaries")
|
|
||||||
|
|
||||||
set(MACOS_APP_CERT_NAME "" CACHE STRING
|
|
||||||
"Name of the Developer ID Application certificate (in the macOS keychain) that should be used to sign the libjpeg-turbo DMG. Leave this blank to generate an unsigned DMG.")
|
|
||||||
set(MACOS_INST_CERT_NAME "" CACHE STRING
|
|
||||||
"Name of the Developer ID Installer certificate (in the macOS keychain) that should be used to sign the libjpeg-turbo installer package. Leave this blank to generate an unsigned package.")
|
|
||||||
|
|
||||||
configure_file(release/makemacpkg.in pkgscripts/makemacpkg)
|
|
||||||
configure_file(release/Distribution.xml.in pkgscripts/Distribution.xml)
|
|
||||||
configure_file(release/Welcome.rtf.in pkgscripts/Welcome.rtf)
|
|
||||||
configure_file(release/uninstall.in pkgscripts/uninstall)
|
|
||||||
|
|
||||||
add_custom_target(dmg pkgscripts/makemacpkg
|
|
||||||
SOURCES pkgscripts/makemacpkg)
|
|
||||||
|
|
||||||
endif() # APPLE
|
|
||||||
|
|
||||||
|
|
||||||
###############################################################################
|
|
||||||
# Generic
|
|
||||||
###############################################################################
|
|
||||||
|
|
||||||
add_custom_target(dist
|
|
||||||
COMMAND git archive --prefix=${CMAKE_PROJECT_NAME}-${VERSION}/ HEAD |
|
|
||||||
gzip > ${CMAKE_CURRENT_BINARY_DIR}/${CMAKE_PROJECT_NAME}-${VERSION}.tar.gz
|
|
||||||
WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR})
|
|
||||||
|
|
||||||
configure_file(release/maketarball.in pkgscripts/maketarball)
|
|
||||||
|
|
||||||
add_custom_target(tarball pkgscripts/maketarball
|
|
||||||
SOURCES pkgscripts/maketarball)
|
|
||||||
|
|
||||||
configure_file(release/libjpeg.pc.in pkgscripts/libjpeg.pc @ONLY)
|
|
||||||
|
|
||||||
if(WITH_TURBOJPEG)
|
|
||||||
configure_file(release/libturbojpeg.pc.in pkgscripts/libturbojpeg.pc @ONLY)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
include(CMakePackageConfigHelpers)
|
|
||||||
write_basic_package_version_file(
|
|
||||||
pkgscripts/${CMAKE_PROJECT_NAME}ConfigVersion.cmake
|
|
||||||
VERSION ${VERSION} COMPATIBILITY AnyNewerVersion)
|
|
||||||
|
|
||||||
configure_package_config_file(release/Config.cmake.in
|
|
||||||
pkgscripts/${CMAKE_PROJECT_NAME}Config.cmake
|
|
||||||
INSTALL_DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake/${CMAKE_PROJECT_NAME})
|
|
||||||
@@ -1,419 +0,0 @@
|
|||||||
#.rst:
|
|
||||||
# GNUInstallDirs
|
|
||||||
# --------------
|
|
||||||
#
|
|
||||||
# Define GNU standard installation directories
|
|
||||||
#
|
|
||||||
# Provides install directory variables as defined by the
|
|
||||||
# `GNU Coding Standards`_.
|
|
||||||
#
|
|
||||||
# .. _`GNU Coding Standards`: https://www.gnu.org/prep/standards/html_node/Directory-Variables.html
|
|
||||||
#
|
|
||||||
# Result Variables
|
|
||||||
# ^^^^^^^^^^^^^^^^
|
|
||||||
#
|
|
||||||
# Inclusion of this module defines the following variables:
|
|
||||||
#
|
|
||||||
# ``CMAKE_INSTALL_<dir>``
|
|
||||||
#
|
|
||||||
# Destination for files of a given type. This value may be passed to
|
|
||||||
# the ``DESTINATION`` options of :command:`install` commands for the
|
|
||||||
# corresponding file type.
|
|
||||||
#
|
|
||||||
# ``CMAKE_INSTALL_FULL_<dir>``
|
|
||||||
#
|
|
||||||
# The absolute path generated from the corresponding ``CMAKE_INSTALL_<dir>``
|
|
||||||
# value. If the value is not already an absolute path, an absolute path
|
|
||||||
# is constructed typically by prepending the value of the
|
|
||||||
# :variable:`CMAKE_INSTALL_PREFIX` variable. However, there are some
|
|
||||||
# `special cases`_ as documented below.
|
|
||||||
#
|
|
||||||
# where ``<dir>`` is one of:
|
|
||||||
#
|
|
||||||
# ``BINDIR``
|
|
||||||
# user executables (``bin``)
|
|
||||||
# ``SBINDIR``
|
|
||||||
# system admin executables (``sbin``)
|
|
||||||
# ``LIBEXECDIR``
|
|
||||||
# program executables (``libexec``)
|
|
||||||
# ``SYSCONFDIR``
|
|
||||||
# read-only single-machine data (``etc``)
|
|
||||||
# ``SHAREDSTATEDIR``
|
|
||||||
# modifiable architecture-independent data (``com``)
|
|
||||||
# ``LOCALSTATEDIR``
|
|
||||||
# modifiable single-machine data (``var``)
|
|
||||||
# ``LIBDIR``
|
|
||||||
# object code libraries (``lib`` or ``lib64``
|
|
||||||
# or ``lib/<multiarch-tuple>`` on Debian)
|
|
||||||
# ``INCLUDEDIR``
|
|
||||||
# C header files (``include``)
|
|
||||||
# ``OLDINCLUDEDIR``
|
|
||||||
# C header files for non-gcc (``/usr/include``)
|
|
||||||
# ``DATAROOTDIR``
|
|
||||||
# read-only architecture-independent data root (``share``)
|
|
||||||
# ``DATADIR``
|
|
||||||
# read-only architecture-independent data (``DATAROOTDIR``)
|
|
||||||
# ``INFODIR``
|
|
||||||
# info documentation (``DATAROOTDIR/info``)
|
|
||||||
# ``LOCALEDIR``
|
|
||||||
# locale-dependent data (``DATAROOTDIR/locale``)
|
|
||||||
# ``MANDIR``
|
|
||||||
# man documentation (``DATAROOTDIR/man``)
|
|
||||||
# ``DOCDIR``
|
|
||||||
# documentation root (``DATAROOTDIR/doc/PROJECT_NAME``)
|
|
||||||
#
|
|
||||||
# If the includer does not define a value the above-shown default will be
|
|
||||||
# used and the value will appear in the cache for editing by the user.
|
|
||||||
#
|
|
||||||
# Special Cases
|
|
||||||
# ^^^^^^^^^^^^^
|
|
||||||
#
|
|
||||||
# The following values of :variable:`CMAKE_INSTALL_PREFIX` are special:
|
|
||||||
#
|
|
||||||
# ``/``
|
|
||||||
#
|
|
||||||
# For ``<dir>`` other than the ``SYSCONFDIR`` and ``LOCALSTATEDIR``,
|
|
||||||
# the value of ``CMAKE_INSTALL_<dir>`` is prefixed with ``usr/`` if
|
|
||||||
# it is not user-specified as an absolute path. For example, the
|
|
||||||
# ``INCLUDEDIR`` value ``include`` becomes ``usr/include``.
|
|
||||||
# This is required by the `GNU Coding Standards`_, which state:
|
|
||||||
#
|
|
||||||
# When building the complete GNU system, the prefix will be empty
|
|
||||||
# and ``/usr`` will be a symbolic link to ``/``.
|
|
||||||
#
|
|
||||||
# ``/usr``
|
|
||||||
#
|
|
||||||
# For ``<dir>`` equal to ``SYSCONFDIR`` or ``LOCALSTATEDIR``, the
|
|
||||||
# ``CMAKE_INSTALL_FULL_<dir>`` is computed by prepending just ``/``
|
|
||||||
# to the value of ``CMAKE_INSTALL_<dir>`` if it is not user-specified
|
|
||||||
# as an absolute path. For example, the ``SYSCONFDIR`` value ``etc``
|
|
||||||
# becomes ``/etc``. This is required by the `GNU Coding Standards`_.
|
|
||||||
#
|
|
||||||
# ``/opt/...``
|
|
||||||
#
|
|
||||||
# For ``<dir>`` equal to ``SYSCONFDIR`` or ``LOCALSTATEDIR``, the
|
|
||||||
# ``CMAKE_INSTALL_FULL_<dir>`` is computed by *appending* the prefix
|
|
||||||
# to the value of ``CMAKE_INSTALL_<dir>`` if it is not user-specified
|
|
||||||
# as an absolute path. For example, the ``SYSCONFDIR`` value ``etc``
|
|
||||||
# becomes ``/etc/opt/...``. This is defined by the
|
|
||||||
# `Filesystem Hierarchy Standard`_.
|
|
||||||
#
|
|
||||||
# .. _`Filesystem Hierarchy Standard`: https://refspecs.linuxfoundation.org/FHS_3.0/fhs/index.html
|
|
||||||
#
|
|
||||||
# Macros
|
|
||||||
# ^^^^^^
|
|
||||||
#
|
|
||||||
# .. command:: GNUInstallDirs_get_absolute_install_dir
|
|
||||||
#
|
|
||||||
# ::
|
|
||||||
#
|
|
||||||
# GNUInstallDirs_get_absolute_install_dir(absvar var)
|
|
||||||
#
|
|
||||||
# Set the given variable ``absvar`` to the absolute path contained
|
|
||||||
# within the variable ``var``. This is to allow the computation of an
|
|
||||||
# absolute path, accounting for all the special cases documented
|
|
||||||
# above. While this macro is used to compute the various
|
|
||||||
# ``CMAKE_INSTALL_FULL_<dir>`` variables, it is exposed publicly to
|
|
||||||
# allow users who create additional path variables to also compute
|
|
||||||
# absolute paths where necessary, using the same logic.
|
|
||||||
|
|
||||||
#=============================================================================
|
|
||||||
# Copyright 2018 Matthias Räncker
|
|
||||||
# Copyright 2016, 2019 D. R. Commander
|
|
||||||
# Copyright 2016 Dmitry Marakasov
|
|
||||||
# Copyright 2016 Roger Leigh
|
|
||||||
# Copyright 2015 Alex Turbov
|
|
||||||
# Copyright 2014 Rolf Eike Beer
|
|
||||||
# Copyright 2014 Daniele E. Domenichelli
|
|
||||||
# Copyright 2013 Dimitri John Ledkov
|
|
||||||
# Copyright 2011 Alex Neundorf
|
|
||||||
# Copyright 2011 Eric NOULARD
|
|
||||||
# Copyright 2011, 2013-2015 Kitware, Inc.
|
|
||||||
# Copyright 2011 Nikita Krupen'ko
|
|
||||||
#
|
|
||||||
# Redistribution and use in source and binary forms, with or without
|
|
||||||
# modification, are permitted provided that the following conditions
|
|
||||||
# are met:
|
|
||||||
#
|
|
||||||
# * Redistributions of source code must retain the above copyright
|
|
||||||
# notice, this list of conditions and the following disclaimer.
|
|
||||||
#
|
|
||||||
# * Redistributions in binary form must reproduce the above copyright
|
|
||||||
# notice, this list of conditions and the following disclaimer in the
|
|
||||||
# documentation and/or other materials provided with the distribution.
|
|
||||||
#
|
|
||||||
# * Neither the names of Kitware, Inc., the Insight Software Consortium,
|
|
||||||
# nor the names of their contributors may be used to endorse or promote
|
|
||||||
# products derived from this software without specific prior written
|
|
||||||
# permission.
|
|
||||||
#
|
|
||||||
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
|
||||||
# "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
|
||||||
# LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
|
||||||
# A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
|
||||||
# HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
|
||||||
# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
|
||||||
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
|
||||||
# DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
|
||||||
# THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
|
||||||
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
||||||
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
#=============================================================================
|
|
||||||
|
|
||||||
# Installation directories
|
|
||||||
#
|
|
||||||
|
|
||||||
macro(GNUInstallDirs_set_install_dir var docstring)
|
|
||||||
# If CMAKE_INSTALL_PREFIX changes and CMAKE_INSTALL_*DIR is still set to the
|
|
||||||
# default value, then modify it accordingly. This presumes that the default
|
|
||||||
# value may change based on the prefix.
|
|
||||||
|
|
||||||
set(_GNUInstallDirs_CMAKE_INSTALL_FORCE_${var} "")
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_${var})
|
|
||||||
set(_GNUInstallDirs_CMAKE_INSTALL_DEFAULT_${var} 1 CACHE INTERNAL
|
|
||||||
"CMAKE_INSTALL_${var} has default value")
|
|
||||||
elseif(DEFINED _GNUInstallDirs_CMAKE_INSTALL_LAST_DEFAULT_${var} AND
|
|
||||||
NOT "${_GNUInstallDirs_CMAKE_INSTALL_LAST_DEFAULT_${var}}" STREQUAL
|
|
||||||
"${CMAKE_INSTALL_DEFAULT_${var}}" AND
|
|
||||||
_GNUInstallDirs_CMAKE_INSTALL_DEFAULT_${var} AND
|
|
||||||
"${_GNUInstallDirs_CMAKE_INSTALL_LAST_${var}}" STREQUAL
|
|
||||||
"${CMAKE_INSTALL_${var}}")
|
|
||||||
set(_GNUInstallDirs_CMAKE_INSTALL_FORCE_${var} "FORCE")
|
|
||||||
endif()
|
|
||||||
|
|
||||||
set(CMAKE_INSTALL_${var} "${CMAKE_INSTALL_DEFAULT_${var}}" CACHE PATH
|
|
||||||
"${docstring} (Default: ${CMAKE_INSTALL_DEFAULT_${var}})"
|
|
||||||
${_GNUInstallDirs_CMAKE_INSTALL_FORCE_${var}})
|
|
||||||
|
|
||||||
if(NOT CMAKE_INSTALL_${var} STREQUAL CMAKE_INSTALL_DEFAULT_${var})
|
|
||||||
unset(_GNUInstallDirs_CMAKE_INSTALL_DEFAULT_${var} CACHE)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
# Save for next run
|
|
||||||
set(_GNUInstallDirs_CMAKE_INSTALL_LAST_${var} "${CMAKE_INSTALL_${var}}"
|
|
||||||
CACHE INTERNAL "CMAKE_INSTALL_${var} during last run")
|
|
||||||
set(_GNUInstallDirs_CMAKE_INSTALL_LAST_DEFAULT_${var}
|
|
||||||
"${CMAKE_INSTALL_DEFAULT_${var}}" CACHE INTERNAL
|
|
||||||
"CMAKE_INSTALL_DEFAULT_${var} during last run")
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_BINDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_BINDIR "bin")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(BINDIR
|
|
||||||
"Directory into which user executables should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_SBINDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_SBINDIR "sbin")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(SBINDIR
|
|
||||||
"Directory into which system admin executables should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_LIBEXECDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LIBEXECDIR "libexec")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(LIBEXECDIR
|
|
||||||
"Directory under which executables run by other programs should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_SYSCONFDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_SYSCONFDIR "etc")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(SYSCONFDIR
|
|
||||||
"Directory into which machine-specific read-only ASCII data and configuration files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_SHAREDSTATEDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_SHAREDSTATEDIR "com")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(SHAREDSTATEDIR
|
|
||||||
"Directory into which architecture-independent run-time-modifiable data files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_LOCALSTATEDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LOCALSTATEDIR "var")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(LOCALSTATEDIR
|
|
||||||
"Directory into which machine-specific run-time-modifiable data files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_LIBDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LIBDIR "lib")
|
|
||||||
# Override this default 'lib' with 'lib64' iff:
|
|
||||||
# - we are on Linux system but NOT cross-compiling
|
|
||||||
# - we are NOT on debian
|
|
||||||
# - we are on a 64 bits system
|
|
||||||
# reason is: amd64 ABI: http://www.x86-64.org/documentation/abi.pdf
|
|
||||||
# For Debian with multiarch, use 'lib/${CMAKE_LIBRARY_ARCHITECTURE}' if
|
|
||||||
# CMAKE_LIBRARY_ARCHITECTURE is set (which contains e.g. "i386-linux-gnu"
|
|
||||||
# and CMAKE_INSTALL_PREFIX is "/usr"
|
|
||||||
# See http://wiki.debian.org/Multiarch
|
|
||||||
if(CMAKE_SYSTEM_NAME MATCHES "^(Linux|kFreeBSD|GNU)$"
|
|
||||||
AND NOT CMAKE_CROSSCOMPILING)
|
|
||||||
if (EXISTS "/etc/debian_version") # is this a debian system ?
|
|
||||||
if(CMAKE_LIBRARY_ARCHITECTURE)
|
|
||||||
if("${CMAKE_INSTALL_PREFIX}" MATCHES "^/usr/?$")
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LIBDIR "lib/${CMAKE_LIBRARY_ARCHITECTURE}")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
else() # not debian, rely on CMAKE_SIZEOF_VOID_P:
|
|
||||||
if(NOT DEFINED CMAKE_SIZEOF_VOID_P)
|
|
||||||
message(AUTHOR_WARNING
|
|
||||||
"Unable to determine default CMAKE_INSTALL_LIBDIR directory because no target architecture is known. "
|
|
||||||
"Please enable at least one language before including GNUInstallDirs.")
|
|
||||||
else()
|
|
||||||
if("${CMAKE_SIZEOF_VOID_P}" EQUAL "8")
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LIBDIR "lib64")
|
|
||||||
elseif(CMAKE_C_COMPILER_ABI MATCHES "ELF X32")
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LIBDIR "libx32")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(LIBDIR
|
|
||||||
"Directory into which object files and object code libraries should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_INCLUDEDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_INCLUDEDIR "include")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(INCLUDEDIR
|
|
||||||
"Directory into which C header files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_OLDINCLUDEDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_OLDINCLUDEDIR "/usr/include")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(OLDINCLUDEDIR
|
|
||||||
PATH "Directory into which C header files for non-GCC compilers should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_DATAROOTDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_DATAROOTDIR "share")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(DATAROOTDIR
|
|
||||||
"The root of the directory tree for read-only architecture-independent data files")
|
|
||||||
|
|
||||||
#-----------------------------------------------------------------------------
|
|
||||||
# Values whose defaults are relative to DATAROOTDIR. Store empty values in
|
|
||||||
# the cache and store the defaults in local variables if the cache values are
|
|
||||||
# not set explicitly. This auto-updates the defaults as DATAROOTDIR changes.
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_DATADIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_DATADIR "<CMAKE_INSTALL_DATAROOTDIR>")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(DATADIR
|
|
||||||
"The directory under which read-only architecture-independent data files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_INFODIR)
|
|
||||||
if(CMAKE_SYSTEM_NAME MATCHES "^(.*BSD|DragonFly)$")
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_INFODIR "info")
|
|
||||||
else()
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_INFODIR "<CMAKE_INSTALL_DATAROOTDIR>/info")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(INFODIR
|
|
||||||
"The directory into which info documentation files should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_MANDIR)
|
|
||||||
if(CMAKE_SYSTEM_NAME MATCHES "^(.*BSD|DragonFly)$")
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_MANDIR "man")
|
|
||||||
else()
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_MANDIR "<CMAKE_INSTALL_DATAROOTDIR>/man")
|
|
||||||
endif()
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(MANDIR
|
|
||||||
"The directory under which man pages should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_LOCALEDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_LOCALEDIR "<CMAKE_INSTALL_DATAROOTDIR>/locale")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(LOCALEDIR
|
|
||||||
"The directory under which locale-specific message catalogs should be installed")
|
|
||||||
|
|
||||||
if(NOT DEFINED CMAKE_INSTALL_DEFAULT_DOCDIR)
|
|
||||||
set(CMAKE_INSTALL_DEFAULT_DOCDIR "<CMAKE_INSTALL_DATAROOTDIR>/doc/${PROJECT_NAME}")
|
|
||||||
endif()
|
|
||||||
GNUInstallDirs_set_install_dir(DOCDIR
|
|
||||||
"The directory into which documentation files (other than info files) should be installed")
|
|
||||||
|
|
||||||
#-----------------------------------------------------------------------------
|
|
||||||
|
|
||||||
mark_as_advanced(
|
|
||||||
CMAKE_INSTALL_BINDIR
|
|
||||||
CMAKE_INSTALL_SBINDIR
|
|
||||||
CMAKE_INSTALL_LIBEXECDIR
|
|
||||||
CMAKE_INSTALL_SYSCONFDIR
|
|
||||||
CMAKE_INSTALL_SHAREDSTATEDIR
|
|
||||||
CMAKE_INSTALL_LOCALSTATEDIR
|
|
||||||
CMAKE_INSTALL_LIBDIR
|
|
||||||
CMAKE_INSTALL_INCLUDEDIR
|
|
||||||
CMAKE_INSTALL_OLDINCLUDEDIR
|
|
||||||
CMAKE_INSTALL_DATAROOTDIR
|
|
||||||
CMAKE_INSTALL_DATADIR
|
|
||||||
CMAKE_INSTALL_INFODIR
|
|
||||||
CMAKE_INSTALL_LOCALEDIR
|
|
||||||
CMAKE_INSTALL_MANDIR
|
|
||||||
CMAKE_INSTALL_DOCDIR
|
|
||||||
)
|
|
||||||
|
|
||||||
macro(GNUInstallDirs_get_absolute_install_dir absvar var)
|
|
||||||
string(REGEX REPLACE "[<>]" "@" ${var} "${${var}}")
|
|
||||||
# Handle the specific case of an empty CMAKE_INSTALL_DATAROOTDIR
|
|
||||||
if(NOT CMAKE_INSTALL_DATAROOTDIR AND
|
|
||||||
${var} MATCHES "\@CMAKE_INSTALL_DATAROOTDIR\@/")
|
|
||||||
string(CONFIGURE "${${var}}" ${var} @ONLY)
|
|
||||||
string(REGEX REPLACE "^/" "" ${var} "${${var}}")
|
|
||||||
else()
|
|
||||||
string(CONFIGURE "${${var}}" ${var} @ONLY)
|
|
||||||
endif()
|
|
||||||
if(NOT IS_ABSOLUTE "${${var}}")
|
|
||||||
# Handle special cases:
|
|
||||||
# - CMAKE_INSTALL_PREFIX == /
|
|
||||||
# - CMAKE_INSTALL_PREFIX == /usr
|
|
||||||
# - CMAKE_INSTALL_PREFIX == /opt/...
|
|
||||||
if("${CMAKE_INSTALL_PREFIX}" STREQUAL "/")
|
|
||||||
if("${dir}" STREQUAL "SYSCONFDIR" OR "${dir}" STREQUAL "LOCALSTATEDIR")
|
|
||||||
set(${absvar} "/${${var}}")
|
|
||||||
else()
|
|
||||||
if (NOT "${${var}}" MATCHES "^usr/")
|
|
||||||
set(${var} "usr/${${var}}")
|
|
||||||
endif()
|
|
||||||
set(${absvar} "/${${var}}")
|
|
||||||
endif()
|
|
||||||
elseif("${CMAKE_INSTALL_PREFIX}" MATCHES "^/usr/?$")
|
|
||||||
if("${dir}" STREQUAL "SYSCONFDIR" OR "${dir}" STREQUAL "LOCALSTATEDIR")
|
|
||||||
set(${absvar} "/${${var}}")
|
|
||||||
else()
|
|
||||||
set(${absvar} "${CMAKE_INSTALL_PREFIX}/${${var}}")
|
|
||||||
endif()
|
|
||||||
elseif("${CMAKE_INSTALL_PREFIX}" MATCHES "^/opt/.*")
|
|
||||||
if("${dir}" STREQUAL "SYSCONFDIR" OR "${dir}" STREQUAL "LOCALSTATEDIR")
|
|
||||||
set(${absvar} "/${${var}}${CMAKE_INSTALL_PREFIX}")
|
|
||||||
else()
|
|
||||||
set(${absvar} "${CMAKE_INSTALL_PREFIX}/${${var}}")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
set(${absvar} "${CMAKE_INSTALL_PREFIX}/${${var}}")
|
|
||||||
endif()
|
|
||||||
else()
|
|
||||||
set(${absvar} "${${var}}")
|
|
||||||
endif()
|
|
||||||
string(REGEX REPLACE "/$" "" ${absvar} "${${absvar}}")
|
|
||||||
endmacro()
|
|
||||||
|
|
||||||
# Result directories
|
|
||||||
#
|
|
||||||
foreach(dir
|
|
||||||
BINDIR
|
|
||||||
SBINDIR
|
|
||||||
LIBEXECDIR
|
|
||||||
SYSCONFDIR
|
|
||||||
SHAREDSTATEDIR
|
|
||||||
LOCALSTATEDIR
|
|
||||||
LIBDIR
|
|
||||||
INCLUDEDIR
|
|
||||||
OLDINCLUDEDIR
|
|
||||||
DATAROOTDIR
|
|
||||||
DATADIR
|
|
||||||
INFODIR
|
|
||||||
LOCALEDIR
|
|
||||||
MANDIR
|
|
||||||
DOCDIR
|
|
||||||
)
|
|
||||||
GNUInstallDirs_get_absolute_install_dir(CMAKE_INSTALL_FULL_${dir} CMAKE_INSTALL_${dir})
|
|
||||||
endforeach()
|
|
||||||
@@ -1,13 +0,0 @@
|
|||||||
# This file is included from the top-level CMakeLists.txt. We just store it
|
|
||||||
# here to avoid cluttering up that file.
|
|
||||||
|
|
||||||
set(PKGNAME ${CMAKE_PROJECT_NAME} CACHE STRING
|
|
||||||
"Distribution package name (default: ${CMAKE_PROJECT_NAME})")
|
|
||||||
set(PKGVENDOR "The ${CMAKE_PROJECT_NAME} Project" CACHE STRING
|
|
||||||
"Vendor name to be included in distribution package descriptions (default: The ${CMAKE_PROJECT_NAME} Project)")
|
|
||||||
set(PKGURL "http://www.${CMAKE_PROJECT_NAME}.org" CACHE STRING
|
|
||||||
"URL of project web site to be included in distribution package descriptions (default: http://www.${CMAKE_PROJECT_NAME}.org)")
|
|
||||||
set(PKGEMAIL "information@${CMAKE_PROJECT_NAME}.org" CACHE STRING
|
|
||||||
"E-mail of project maintainer to be included in distribution package descriptions (default: information@${CMAKE_PROJECT_NAME}.org")
|
|
||||||
set(PKGID "com.${CMAKE_PROJECT_NAME}.${PKGNAME}" CACHE STRING
|
|
||||||
"Globally unique package identifier (reverse DNS notation) (default: com.${CMAKE_PROJECT_NAME}.${PKGNAME})")
|
|
||||||
@@ -1,24 +0,0 @@
|
|||||||
# This code is from the CMake FAQ
|
|
||||||
|
|
||||||
if (NOT EXISTS "@CMAKE_BINARY_DIR@/install_manifest.txt")
|
|
||||||
message(FATAL_ERROR "Cannot find install manifest: \"@CMAKE_BINARY_DIR@/install_manifest.txt\"")
|
|
||||||
endif(NOT EXISTS "@CMAKE_BINARY_DIR@/install_manifest.txt")
|
|
||||||
|
|
||||||
file(READ "@CMAKE_BINARY_DIR@/install_manifest.txt" files)
|
|
||||||
string(REGEX REPLACE "\n" ";" files "${files}")
|
|
||||||
list(REVERSE files)
|
|
||||||
foreach (file ${files})
|
|
||||||
message(STATUS "Uninstalling \"$ENV{DESTDIR}${file}\"")
|
|
||||||
if (EXISTS "$ENV{DESTDIR}${file}")
|
|
||||||
execute_process(
|
|
||||||
COMMAND "@CMAKE_COMMAND@" -E remove "$ENV{DESTDIR}${file}"
|
|
||||||
OUTPUT_VARIABLE rm_out
|
|
||||||
RESULT_VARIABLE rm_retval
|
|
||||||
)
|
|
||||||
if(NOT ${rm_retval} EQUAL 0)
|
|
||||||
message(FATAL_ERROR "Problem when removing \"$ENV{DESTDIR}${file}\"")
|
|
||||||
endif (NOT ${rm_retval} EQUAL 0)
|
|
||||||
else (EXISTS "$ENV{DESTDIR}${file}")
|
|
||||||
message(STATUS "File \"$ENV{DESTDIR}${file}\" does not exist.")
|
|
||||||
endif (EXISTS "$ENV{DESTDIR}${file}")
|
|
||||||
endforeach(file)
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
file(GLOB FILES
|
|
||||||
testout*
|
|
||||||
*_GRAY_*.bmp
|
|
||||||
*_GRAY_*.png
|
|
||||||
*_GRAY_*.ppm
|
|
||||||
*_GRAY_*.jpg
|
|
||||||
*_GRAY.yuv
|
|
||||||
*_420_*.bmp
|
|
||||||
*_420_*.png
|
|
||||||
*_420_*.ppm
|
|
||||||
*_420_*.jpg
|
|
||||||
*_420.yuv
|
|
||||||
*_422_*.bmp
|
|
||||||
*_422_*.png
|
|
||||||
*_422_*.ppm
|
|
||||||
*_422_*.jpg
|
|
||||||
*_422.yuv
|
|
||||||
*_444_*.bmp
|
|
||||||
*_444_*.png
|
|
||||||
*_444_*.ppm
|
|
||||||
*_444_*.jpg
|
|
||||||
*_444.yuv
|
|
||||||
*_440_*.bmp
|
|
||||||
*_440_*.png
|
|
||||||
*_440_*.ppm
|
|
||||||
*_440_*.jpg
|
|
||||||
*_440.yuv
|
|
||||||
*_411_*.bmp
|
|
||||||
*_411_*.png
|
|
||||||
*_411_*.ppm
|
|
||||||
*_411_*.jpg
|
|
||||||
*_411.yuv
|
|
||||||
tjbenchtest*.log
|
|
||||||
tjexampletest*.log)
|
|
||||||
|
|
||||||
if(NOT FILES STREQUAL "")
|
|
||||||
message(STATUS "Removing test files")
|
|
||||||
file(REMOVE ${FILES})
|
|
||||||
else()
|
|
||||||
message(STATUS "No files to remove")
|
|
||||||
endif()
|
|
||||||
60
android/extern/libjpeg-turbo/cmyk.h
vendored
@@ -1,60 +0,0 @@
|
|||||||
/*
|
|
||||||
* cmyk.h
|
|
||||||
*
|
|
||||||
* Copyright (C) 2017-2018, D. R. Commander.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file contains convenience functions for performing quick & dirty
|
|
||||||
* CMYK<->RGB conversion. This algorithm is suitable for testing purposes
|
|
||||||
* only. Properly converting between CMYK and RGB requires a color management
|
|
||||||
* system.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifndef CMYK_H
|
|
||||||
#define CMYK_H
|
|
||||||
|
|
||||||
#include <jinclude.h>
|
|
||||||
#define JPEG_INTERNALS
|
|
||||||
#include <jpeglib.h>
|
|
||||||
|
|
||||||
|
|
||||||
/* Fully reversible */
|
|
||||||
|
|
||||||
INLINE
|
|
||||||
LOCAL(void)
|
|
||||||
rgb_to_cmyk(JSAMPLE r, JSAMPLE g, JSAMPLE b, JSAMPLE *c, JSAMPLE *m,
|
|
||||||
JSAMPLE *y, JSAMPLE *k)
|
|
||||||
{
|
|
||||||
double ctmp = 1.0 - ((double)r / 255.0);
|
|
||||||
double mtmp = 1.0 - ((double)g / 255.0);
|
|
||||||
double ytmp = 1.0 - ((double)b / 255.0);
|
|
||||||
double ktmp = MIN(MIN(ctmp, mtmp), ytmp);
|
|
||||||
|
|
||||||
if (ktmp == 1.0) ctmp = mtmp = ytmp = 0.0;
|
|
||||||
else {
|
|
||||||
ctmp = (ctmp - ktmp) / (1.0 - ktmp);
|
|
||||||
mtmp = (mtmp - ktmp) / (1.0 - ktmp);
|
|
||||||
ytmp = (ytmp - ktmp) / (1.0 - ktmp);
|
|
||||||
}
|
|
||||||
*c = (JSAMPLE)(255.0 - ctmp * 255.0 + 0.5);
|
|
||||||
*m = (JSAMPLE)(255.0 - mtmp * 255.0 + 0.5);
|
|
||||||
*y = (JSAMPLE)(255.0 - ytmp * 255.0 + 0.5);
|
|
||||||
*k = (JSAMPLE)(255.0 - ktmp * 255.0 + 0.5);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/* Fully reversible only for C/M/Y/K values generated with rgb_to_cmyk() */
|
|
||||||
|
|
||||||
INLINE
|
|
||||||
LOCAL(void)
|
|
||||||
cmyk_to_rgb(JSAMPLE c, JSAMPLE m, JSAMPLE y, JSAMPLE k, JSAMPLE *r, JSAMPLE *g,
|
|
||||||
JSAMPLE *b)
|
|
||||||
{
|
|
||||||
*r = (JSAMPLE)((double)c * (double)k / 255.0 + 0.5);
|
|
||||||
*g = (JSAMPLE)((double)m * (double)k / 255.0 + 0.5);
|
|
||||||
*b = (JSAMPLE)((double)y * (double)k / 255.0 + 0.5);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#endif /* CMYK_H */
|
|
||||||
78
android/extern/libjpeg-turbo/coderules.txt
vendored
@@ -1,78 +0,0 @@
|
|||||||
IJG JPEG LIBRARY: CODING RULES
|
|
||||||
|
|
||||||
This file was part of the Independent JPEG Group's software:
|
|
||||||
Copyright (C) 1991-1996, Thomas G. Lane.
|
|
||||||
It was modified by The libjpeg-turbo Project to include only information
|
|
||||||
relevant to libjpeg-turbo.
|
|
||||||
For conditions of distribution and use, see the accompanying README.ijg file.
|
|
||||||
|
|
||||||
|
|
||||||
Since numerous people will be contributing code and bug fixes, it's important
|
|
||||||
to establish a common coding style. The goal of using similar coding styles
|
|
||||||
is much more important than the details of just what that style is.
|
|
||||||
|
|
||||||
In general we follow the recommendations of "Recommended C Style and Coding
|
|
||||||
Standards" revision 6.1 (Cannon et al. as modified by Spencer, Keppel and
|
|
||||||
Brader). This document is available in the IJG FTP archive (see
|
|
||||||
jpeg/doc/cstyle.ms.tbl.Z, or cstyle.txt.Z for those without nroff/tbl).
|
|
||||||
|
|
||||||
Block comments should be laid out thusly:
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Block comments in this style.
|
|
||||||
*/
|
|
||||||
|
|
||||||
We indent statements in K&R style, e.g.,
|
|
||||||
if (test) {
|
|
||||||
then-part;
|
|
||||||
} else {
|
|
||||||
else-part;
|
|
||||||
}
|
|
||||||
with two spaces per indentation level. (This indentation convention is
|
|
||||||
handled automatically by GNU Emacs and many other text editors.)
|
|
||||||
|
|
||||||
Multi-word names should be written in lower case with underscores, e.g.,
|
|
||||||
multi_word_name (not multiWordName). Preprocessor symbols and enum constants
|
|
||||||
are similar but upper case (MULTI_WORD_NAME). Names should be unique within
|
|
||||||
the first fifteen characters.
|
|
||||||
|
|
||||||
Note that each function definition must begin with GLOBAL(type), LOCAL(type),
|
|
||||||
or METHODDEF(type). These macros expand to "static type" or just "type" as
|
|
||||||
appropriate. They provide a readable indication of the routine's usage and
|
|
||||||
can readily be changed for special needs. (For instance, special linkage
|
|
||||||
keywords can be inserted for use in Windows DLLs.)
|
|
||||||
|
|
||||||
A similar solution is used for external function declarations (see the EXTERN
|
|
||||||
macro.)
|
|
||||||
|
|
||||||
|
|
||||||
The JPEG library is intended to be used within larger programs. Furthermore,
|
|
||||||
we want it to be reentrant so that it can be used by applications that process
|
|
||||||
multiple images concurrently. The following rules support these requirements:
|
|
||||||
|
|
||||||
1. Avoid direct use of file I/O, "malloc", error report printouts, etc;
|
|
||||||
pass these through the common routines provided.
|
|
||||||
|
|
||||||
2. Minimize global namespace pollution. Functions should be declared static
|
|
||||||
wherever possible. (Note that our method-based calling conventions help this
|
|
||||||
a lot: in many modules only the initialization function will ever need to be
|
|
||||||
called directly, so only that function need be externally visible.) All
|
|
||||||
global function names should begin with "jpeg_".
|
|
||||||
|
|
||||||
3. Don't use global variables; anything that must be used in another module
|
|
||||||
should be in the common data structures.
|
|
||||||
|
|
||||||
4. Don't use static variables except for read-only constant tables. Variables
|
|
||||||
that should be private to a module can be placed into private structures (see
|
|
||||||
the system architecture document, structure.txt).
|
|
||||||
|
|
||||||
5. Source file names should begin with "j" for files that are part of the
|
|
||||||
library proper; source files that are not part of the library, such as cjpeg.c
|
|
||||||
and djpeg.c, do not begin with "j". Keep compression and decompression code in
|
|
||||||
separate source files --- some applications may want only one half of the
|
|
||||||
library.
|
|
||||||
|
|
||||||
Note: these rules (particularly #4) are not followed religiously in the
|
|
||||||
modules that are used in cjpeg/djpeg but are not part of the JPEG library
|
|
||||||
proper. Those modules are not really intended to be used in other
|
|
||||||
applications.
|
|
||||||
95
android/extern/libjpeg-turbo/croptest.in
vendored
@@ -1,95 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
set -u
|
|
||||||
set -e
|
|
||||||
trap onexit INT
|
|
||||||
trap onexit TERM
|
|
||||||
trap onexit EXIT
|
|
||||||
|
|
||||||
onexit()
|
|
||||||
{
|
|
||||||
if [ -d $OUTDIR ]; then
|
|
||||||
rm -rf $OUTDIR
|
|
||||||
fi
|
|
||||||
}
|
|
||||||
|
|
||||||
runme()
|
|
||||||
{
|
|
||||||
echo \*\*\* $*
|
|
||||||
$*
|
|
||||||
}
|
|
||||||
|
|
||||||
IMAGE=vgl_6548_0026a.bmp
|
|
||||||
WIDTH=128
|
|
||||||
HEIGHT=95
|
|
||||||
IMGDIR=@CMAKE_CURRENT_SOURCE_DIR@/testimages
|
|
||||||
OUTDIR=`mktemp -d /tmp/__croptest_output.XXXXXX`
|
|
||||||
EXEDIR=@CMAKE_CURRENT_BINARY_DIR@
|
|
||||||
|
|
||||||
if [ -d $OUTDIR ]; then
|
|
||||||
rm -rf $OUTDIR
|
|
||||||
fi
|
|
||||||
mkdir -p $OUTDIR
|
|
||||||
|
|
||||||
exec >$EXEDIR/croptest.log
|
|
||||||
|
|
||||||
echo "============================================================"
|
|
||||||
echo "$IMAGE ($WIDTH x $HEIGHT)"
|
|
||||||
echo "============================================================"
|
|
||||||
echo
|
|
||||||
|
|
||||||
for PROGARG in "" -progressive; do
|
|
||||||
|
|
||||||
cp $IMGDIR/$IMAGE $OUTDIR
|
|
||||||
basename=`basename $IMAGE .bmp`
|
|
||||||
echo "------------------------------------------------------------"
|
|
||||||
echo "Generating test images"
|
|
||||||
echo "------------------------------------------------------------"
|
|
||||||
echo
|
|
||||||
runme $EXEDIR/cjpeg $PROGARG -grayscale -outfile $OUTDIR/${basename}_GRAY.jpg $IMGDIR/${basename}.bmp
|
|
||||||
runme $EXEDIR/cjpeg $PROGARG -sample 2x2 -outfile $OUTDIR/${basename}_420.jpg $IMGDIR/${basename}.bmp
|
|
||||||
runme $EXEDIR/cjpeg $PROGARG -sample 2x1 -outfile $OUTDIR/${basename}_422.jpg $IMGDIR/${basename}.bmp
|
|
||||||
runme $EXEDIR/cjpeg $PROGARG -sample 1x2 -outfile $OUTDIR/${basename}_440.jpg $IMGDIR/${basename}.bmp
|
|
||||||
runme $EXEDIR/cjpeg $PROGARG -sample 1x1 -outfile $OUTDIR/${basename}_444.jpg $IMGDIR/${basename}.bmp
|
|
||||||
echo
|
|
||||||
|
|
||||||
for NSARG in "" -nosmooth; do
|
|
||||||
|
|
||||||
for COLORSARG in "" "-colors 256 -dither none -onepass"; do
|
|
||||||
|
|
||||||
for Y in {0..16}; do
|
|
||||||
|
|
||||||
for H in {1..16}; do
|
|
||||||
|
|
||||||
X=$(( (Y*16)%128 ))
|
|
||||||
W=$(( WIDTH-X-7 ))
|
|
||||||
if [ $Y -le 15 ]; then
|
|
||||||
CROPSPEC="${W}x${H}+${X}+${Y}"
|
|
||||||
else
|
|
||||||
Y2=$(( HEIGHT-H ));
|
|
||||||
CROPSPEC="${W}x${H}+${X}+${Y2}"
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "------------------------------------------------------------"
|
|
||||||
echo $PROGARG $NSARG $COLORSARG -crop $CROPSPEC
|
|
||||||
echo "------------------------------------------------------------"
|
|
||||||
echo
|
|
||||||
for samp in GRAY 420 422 440 444; do
|
|
||||||
$EXEDIR/djpeg $NSARG $COLORSARG -rgb -outfile $OUTDIR/${basename}_${samp}_full.ppm $OUTDIR/${basename}_${samp}.jpg
|
|
||||||
convert -crop $CROPSPEC $OUTDIR/${basename}_${samp}_full.ppm $OUTDIR/${basename}_${samp}_ref.ppm
|
|
||||||
runme $EXEDIR/djpeg $NSARG $COLORSARG -crop $CROPSPEC -rgb -outfile $OUTDIR/${basename}_${samp}.ppm $OUTDIR/${basename}_${samp}.jpg
|
|
||||||
runme cmp $OUTDIR/${basename}_${samp}.ppm $OUTDIR/${basename}_${samp}_ref.ppm
|
|
||||||
done
|
|
||||||
echo
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
done
|
|
||||||
|
|
||||||
echo SUCCESS!
|
|
||||||
320
android/extern/libjpeg-turbo/djpeg.1
vendored
@@ -1,320 +0,0 @@
|
|||||||
.TH DJPEG 1 "4 November 2020"
|
|
||||||
.SH NAME
|
|
||||||
djpeg \- decompress a JPEG file to an image file
|
|
||||||
.SH SYNOPSIS
|
|
||||||
.B djpeg
|
|
||||||
[
|
|
||||||
.I options
|
|
||||||
]
|
|
||||||
[
|
|
||||||
.I filename
|
|
||||||
]
|
|
||||||
.LP
|
|
||||||
.SH DESCRIPTION
|
|
||||||
.LP
|
|
||||||
.B djpeg
|
|
||||||
decompresses the named JPEG file, or the standard input if no file is named,
|
|
||||||
and produces an image file on the standard output. PBMPLUS (PPM/PGM), BMP,
|
|
||||||
GIF, or Targa output format can be selected.
|
|
||||||
.SH OPTIONS
|
|
||||||
All switch names may be abbreviated; for example,
|
|
||||||
.B \-grayscale
|
|
||||||
may be written
|
|
||||||
.B \-gray
|
|
||||||
or
|
|
||||||
.BR \-gr .
|
|
||||||
Most of the "basic" switches can be abbreviated to as little as one letter.
|
|
||||||
Upper and lower case are equivalent (thus
|
|
||||||
.B \-BMP
|
|
||||||
is the same as
|
|
||||||
.BR \-bmp ).
|
|
||||||
British spellings are also accepted (e.g.,
|
|
||||||
.BR \-greyscale ),
|
|
||||||
though for brevity these are not mentioned below.
|
|
||||||
.PP
|
|
||||||
The basic switches are:
|
|
||||||
.TP
|
|
||||||
.BI \-colors " N"
|
|
||||||
Reduce image to at most N colors. This reduces the number of colors used in
|
|
||||||
the output image, so that it can be displayed on a colormapped display or
|
|
||||||
stored in a colormapped file format. For example, if you have an 8-bit
|
|
||||||
display, you'd need to reduce to 256 or fewer colors.
|
|
||||||
.TP
|
|
||||||
.BI \-quantize " N"
|
|
||||||
Same as
|
|
||||||
.BR \-colors .
|
|
||||||
.B \-colors
|
|
||||||
is the recommended name,
|
|
||||||
.B \-quantize
|
|
||||||
is provided only for backwards compatibility.
|
|
||||||
.TP
|
|
||||||
.B \-fast
|
|
||||||
Select recommended processing options for fast, low quality output. (The
|
|
||||||
default options are chosen for highest quality output.) Currently, this is
|
|
||||||
equivalent to \fB\-dct fast \-nosmooth \-onepass \-dither ordered\fR.
|
|
||||||
.TP
|
|
||||||
.B \-grayscale
|
|
||||||
Force grayscale output even if JPEG file is color. Useful for viewing on
|
|
||||||
monochrome displays; also,
|
|
||||||
.B djpeg
|
|
||||||
runs noticeably faster in this mode.
|
|
||||||
.TP
|
|
||||||
.B \-rgb
|
|
||||||
Force RGB output even if JPEG file is grayscale.
|
|
||||||
.TP
|
|
||||||
.BI \-scale " M/N"
|
|
||||||
Scale the output image by a factor M/N. Currently the scale factor must be
|
|
||||||
M/8, where M is an integer between 1 and 16 inclusive, or any reduced fraction
|
|
||||||
thereof (such as 1/2, 3/4, etc.) Scaling is handy if the image is larger than
|
|
||||||
your screen; also,
|
|
||||||
.B djpeg
|
|
||||||
runs much faster when scaling down the output.
|
|
||||||
.TP
|
|
||||||
.B \-bmp
|
|
||||||
Select BMP output format (Windows flavor). 8-bit colormapped format is
|
|
||||||
emitted if
|
|
||||||
.B \-colors
|
|
||||||
or
|
|
||||||
.B \-grayscale
|
|
||||||
is specified, or if the JPEG file is grayscale; otherwise, 24-bit full-color
|
|
||||||
format is emitted.
|
|
||||||
.TP
|
|
||||||
.B \-gif
|
|
||||||
Select GIF output format (LZW-compressed). Since GIF does not support more
|
|
||||||
than 256 colors,
|
|
||||||
.B \-colors 256
|
|
||||||
is assumed (unless you specify a smaller number of colors). If you specify
|
|
||||||
.BR \-fast,
|
|
||||||
the default number of colors is 216.
|
|
||||||
.TP
|
|
||||||
.B \-gif0
|
|
||||||
Select GIF output format (uncompressed). Since GIF does not support more than
|
|
||||||
256 colors,
|
|
||||||
.B \-colors 256
|
|
||||||
is assumed (unless you specify a smaller number of colors). If you specify
|
|
||||||
.BR \-fast,
|
|
||||||
the default number of colors is 216.
|
|
||||||
.TP
|
|
||||||
.B \-os2
|
|
||||||
Select BMP output format (OS/2 1.x flavor). 8-bit colormapped format is
|
|
||||||
emitted if
|
|
||||||
.B \-colors
|
|
||||||
or
|
|
||||||
.B \-grayscale
|
|
||||||
is specified, or if the JPEG file is grayscale; otherwise, 24-bit full-color
|
|
||||||
format is emitted.
|
|
||||||
.TP
|
|
||||||
.B \-pnm
|
|
||||||
Select PBMPLUS (PPM/PGM) output format (this is the default format).
|
|
||||||
PGM is emitted if the JPEG file is grayscale or if
|
|
||||||
.B \-grayscale
|
|
||||||
is specified; otherwise PPM is emitted.
|
|
||||||
.TP
|
|
||||||
.B \-targa
|
|
||||||
Select Targa output format. Grayscale format is emitted if the JPEG file is
|
|
||||||
grayscale or if
|
|
||||||
.B \-grayscale
|
|
||||||
is specified; otherwise, colormapped format is emitted if
|
|
||||||
.B \-colors
|
|
||||||
is specified; otherwise, 24-bit full-color format is emitted.
|
|
||||||
.PP
|
|
||||||
Switches for advanced users:
|
|
||||||
.TP
|
|
||||||
.B \-dct int
|
|
||||||
Use accurate integer DCT method (default).
|
|
||||||
.TP
|
|
||||||
.B \-dct fast
|
|
||||||
Use less accurate integer DCT method [legacy feature].
|
|
||||||
When the Independent JPEG Group's software was first released in 1991, the
|
|
||||||
decompression time for a 1-megapixel JPEG image on a mainstream PC was measured
|
|
||||||
in minutes. Thus, the \fBfast\fR integer DCT algorithm provided noticeable
|
|
||||||
performance benefits. On modern CPUs running libjpeg-turbo, however, the
|
|
||||||
decompression time for a 1-megapixel JPEG image is measured in milliseconds,
|
|
||||||
and thus the performance benefits of the \fBfast\fR algorithm are much less
|
|
||||||
noticeable. On modern x86/x86-64 CPUs that support AVX2 instructions, the
|
|
||||||
\fBfast\fR and \fBint\fR methods have similar performance. On other types of
|
|
||||||
CPUs, the \fBfast\fR method is generally about 5-15% faster than the \fBint\fR
|
|
||||||
method.
|
|
||||||
|
|
||||||
If the JPEG image was compressed using a quality level of 85 or below, then
|
|
||||||
there should be little or no perceptible quality difference between the two
|
|
||||||
algorithms. When decompressing images that were compressed using quality
|
|
||||||
levels above 85, however, the difference between the \fBfast\fR and \fBint\fR
|
|
||||||
methods becomes more pronounced. With images compressed using quality=97, for
|
|
||||||
instance, the \fBfast\fR method incurs generally about a 4-6 dB loss in PSNR
|
|
||||||
relative to the \fBint\fR method, but this can be larger for some images. If
|
|
||||||
you can avoid it, do not use the \fBfast\fR method when decompressing images
|
|
||||||
that were compressed using quality levels above 97. The algorithm often
|
|
||||||
degenerates for such images and can actually produce a more lossy output image
|
|
||||||
than if the JPEG image had been compressed using lower quality levels.
|
|
||||||
.TP
|
|
||||||
.B \-dct float
|
|
||||||
Use floating-point DCT method [legacy feature].
|
|
||||||
The \fBfloat\fR method does not produce significantly more accurate results
|
|
||||||
than the \fBint\fR method, and it is much slower. The \fBfloat\fR method may
|
|
||||||
also give different results on different machines due to varying roundoff
|
|
||||||
behavior, whereas the integer methods should give the same results on all
|
|
||||||
machines.
|
|
||||||
.TP
|
|
||||||
.B \-dither fs
|
|
||||||
Use Floyd-Steinberg dithering in color quantization.
|
|
||||||
.TP
|
|
||||||
.B \-dither ordered
|
|
||||||
Use ordered dithering in color quantization.
|
|
||||||
.TP
|
|
||||||
.B \-dither none
|
|
||||||
Do not use dithering in color quantization.
|
|
||||||
By default, Floyd-Steinberg dithering is applied when quantizing colors; this
|
|
||||||
is slow but usually produces the best results. Ordered dither is a compromise
|
|
||||||
between speed and quality; no dithering is fast but usually looks awful. Note
|
|
||||||
that these switches have no effect unless color quantization is being done.
|
|
||||||
Ordered dither is only available in
|
|
||||||
.B \-onepass
|
|
||||||
mode.
|
|
||||||
.TP
|
|
||||||
.BI \-icc " file"
|
|
||||||
Extract ICC color management profile to the specified file.
|
|
||||||
.TP
|
|
||||||
.BI \-map " file"
|
|
||||||
Quantize to the colors used in the specified image file. This is useful for
|
|
||||||
producing multiple files with identical color maps, or for forcing a
|
|
||||||
predefined set of colors to be used. The
|
|
||||||
.I file
|
|
||||||
must be a GIF or PPM file. This option overrides
|
|
||||||
.B \-colors
|
|
||||||
and
|
|
||||||
.BR \-onepass .
|
|
||||||
.TP
|
|
||||||
.B \-nosmooth
|
|
||||||
Use a faster, lower-quality upsampling routine.
|
|
||||||
.TP
|
|
||||||
.B \-onepass
|
|
||||||
Use one-pass instead of two-pass color quantization. The one-pass method is
|
|
||||||
faster and needs less memory, but it produces a lower-quality image.
|
|
||||||
.B \-onepass
|
|
||||||
is ignored unless you also say
|
|
||||||
.B \-colors
|
|
||||||
.IR N .
|
|
||||||
Also, the one-pass method is always used for grayscale output (the two-pass
|
|
||||||
method is no improvement then).
|
|
||||||
.TP
|
|
||||||
.BI \-maxmemory " N"
|
|
||||||
Set limit for amount of memory to use in processing large images. Value is
|
|
||||||
in thousands of bytes, or millions of bytes if "M" is attached to the
|
|
||||||
number. For example,
|
|
||||||
.B \-max 4m
|
|
||||||
selects 4000000 bytes. If more space is needed, an error will occur.
|
|
||||||
.TP
|
|
||||||
.BI \-maxscans " N"
|
|
||||||
Abort if the JPEG image contains more than
|
|
||||||
.I N
|
|
||||||
scans. This feature demonstrates a method by which applications can guard
|
|
||||||
against denial-of-service attacks instigated by specially-crafted malformed
|
|
||||||
JPEG images containing numerous scans with missing image data or image data
|
|
||||||
consisting only of "EOB runs" (a feature of progressive JPEG images that allows
|
|
||||||
potentially hundreds of thousands of adjoining zero-value pixels to be
|
|
||||||
represented using only a few bytes.) Attempting to decompress such malformed
|
|
||||||
JPEG images can cause excessive CPU activity, since the decompressor must fully
|
|
||||||
process each scan (even if the scan is corrupt) before it can proceed to the
|
|
||||||
next scan.
|
|
||||||
.TP
|
|
||||||
.BI \-outfile " name"
|
|
||||||
Send output image to the named file, not to standard output.
|
|
||||||
.TP
|
|
||||||
.BI \-memsrc
|
|
||||||
Load input file into memory before decompressing. This feature was implemented
|
|
||||||
mainly as a way of testing the in-memory source manager (jpeg_mem_src().)
|
|
||||||
.TP
|
|
||||||
.BI \-report
|
|
||||||
Report decompression progress.
|
|
||||||
.TP
|
|
||||||
.BI \-skip " Y0,Y1"
|
|
||||||
Decompress all rows of the JPEG image except those between Y0 and Y1
|
|
||||||
(inclusive.) Note that if decompression scaling is being used, then Y0 and Y1
|
|
||||||
are relative to the scaled image dimensions.
|
|
||||||
.TP
|
|
||||||
.BI \-crop " WxH+X+Y"
|
|
||||||
Decompress only a rectangular subregion of the image, starting at point X,Y
|
|
||||||
with width W and height H. If necessary, X will be shifted left to the nearest
|
|
||||||
iMCU boundary, and the width will be increased accordingly. Note that if
|
|
||||||
decompression scaling is being used, then X, Y, W, and H are relative to the
|
|
||||||
scaled image dimensions. Currently this option only works with the
|
|
||||||
PBMPLUS (PPM/PGM), GIF, and Targa output formats.
|
|
||||||
.TP
|
|
||||||
.BI \-strict
|
|
||||||
Treat all warnings as fatal. This feature also demonstrates a method by which
|
|
||||||
applications can guard against attacks instigated by specially-crafted
|
|
||||||
malformed JPEG images. Enabling this option will cause the decompressor to
|
|
||||||
abort if the JPEG image contains incomplete or corrupt image data.
|
|
||||||
.TP
|
|
||||||
.B \-verbose
|
|
||||||
Enable debug printout. More
|
|
||||||
.BR \-v 's
|
|
||||||
give more output. Also, version information is printed at startup.
|
|
||||||
.TP
|
|
||||||
.B \-debug
|
|
||||||
Same as
|
|
||||||
.BR \-verbose .
|
|
||||||
.TP
|
|
||||||
.B \-version
|
|
||||||
Print version information and exit.
|
|
||||||
.SH EXAMPLES
|
|
||||||
.LP
|
|
||||||
This example decompresses the JPEG file foo.jpg, quantizes it to
|
|
||||||
256 colors, and saves the output in 8-bit BMP format in foo.bmp:
|
|
||||||
.IP
|
|
||||||
.B djpeg \-colors 256 \-bmp
|
|
||||||
.I foo.jpg
|
|
||||||
.B >
|
|
||||||
.I foo.bmp
|
|
||||||
.SH HINTS
|
|
||||||
To get a quick preview of an image, use the
|
|
||||||
.B \-grayscale
|
|
||||||
and/or
|
|
||||||
.B \-scale
|
|
||||||
switches.
|
|
||||||
.B \-grayscale \-scale 1/8
|
|
||||||
is the fastest case.
|
|
||||||
.PP
|
|
||||||
Several options are available that trade off image quality to gain speed.
|
|
||||||
.B \-fast
|
|
||||||
turns on the recommended settings.
|
|
||||||
.PP
|
|
||||||
.B \-dct fast
|
|
||||||
and/or
|
|
||||||
.B \-nosmooth
|
|
||||||
gain speed at a small sacrifice in quality.
|
|
||||||
When producing a color-quantized image,
|
|
||||||
.B \-onepass \-dither ordered
|
|
||||||
is fast but much lower quality than the default behavior.
|
|
||||||
.B \-dither none
|
|
||||||
may give acceptable results in two-pass mode, but is seldom tolerable in
|
|
||||||
one-pass mode.
|
|
||||||
.SH ENVIRONMENT
|
|
||||||
.TP
|
|
||||||
.B JPEGMEM
|
|
||||||
If this environment variable is set, its value is the default memory limit.
|
|
||||||
The value is specified as described for the
|
|
||||||
.B \-maxmemory
|
|
||||||
switch.
|
|
||||||
.B JPEGMEM
|
|
||||||
overrides the default value specified when the program was compiled, and
|
|
||||||
itself is overridden by an explicit
|
|
||||||
.BR \-maxmemory .
|
|
||||||
.SH SEE ALSO
|
|
||||||
.BR cjpeg (1),
|
|
||||||
.BR jpegtran (1),
|
|
||||||
.BR rdjpgcom (1),
|
|
||||||
.BR wrjpgcom (1)
|
|
||||||
.br
|
|
||||||
.BR ppm (5),
|
|
||||||
.BR pgm (5)
|
|
||||||
.br
|
|
||||||
Wallace, Gregory K. "The JPEG Still Picture Compression Standard",
|
|
||||||
Communications of the ACM, April 1991 (vol. 34, no. 4), pp. 30-44.
|
|
||||||
.SH AUTHOR
|
|
||||||
Independent JPEG Group
|
|
||||||
.PP
|
|
||||||
This file was modified by The libjpeg-turbo Project to include only information
|
|
||||||
relevant to libjpeg-turbo, to wordsmith certain sections, and to describe
|
|
||||||
features not present in libjpeg.
|
|
||||||
855
android/extern/libjpeg-turbo/djpeg.c
vendored
@@ -1,855 +0,0 @@
|
|||||||
/*
|
|
||||||
* djpeg.c
|
|
||||||
*
|
|
||||||
* This file was part of the Independent JPEG Group's software:
|
|
||||||
* Copyright (C) 1991-1997, Thomas G. Lane.
|
|
||||||
* Modified 2013-2019 by Guido Vollbeding.
|
|
||||||
* libjpeg-turbo Modifications:
|
|
||||||
* Copyright (C) 2010-2011, 2013-2017, 2019-2020, 2022, D. R. Commander.
|
|
||||||
* Copyright (C) 2015, Google, Inc.
|
|
||||||
* For conditions of distribution and use, see the accompanying README.ijg
|
|
||||||
* file.
|
|
||||||
*
|
|
||||||
* This file contains a command-line user interface for the JPEG decompressor.
|
|
||||||
* It should work on any system with Unix- or MS-DOS-style command lines.
|
|
||||||
*
|
|
||||||
* Two different command line styles are permitted, depending on the
|
|
||||||
* compile-time switch TWO_FILE_COMMANDLINE:
|
|
||||||
* djpeg [options] inputfile outputfile
|
|
||||||
* djpeg [options] [inputfile]
|
|
||||||
* In the second style, output is always to standard output, which you'd
|
|
||||||
* normally redirect to a file or pipe to some other program. Input is
|
|
||||||
* either from a named file or from standard input (typically redirected).
|
|
||||||
* The second style is convenient on Unix but is unhelpful on systems that
|
|
||||||
* don't support pipes. Also, you MUST use the first style if your system
|
|
||||||
* doesn't do binary I/O to stdin/stdout.
|
|
||||||
* To simplify script writing, the "-outfile" switch is provided. The syntax
|
|
||||||
* djpeg [options] -outfile outputfile inputfile
|
|
||||||
* works regardless of which command line style is used.
|
|
||||||
*/
|
|
||||||
|
|
||||||
#ifdef _MSC_VER
|
|
||||||
#define _CRT_SECURE_NO_DEPRECATE
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#include "cdjpeg.h" /* Common decls for cjpeg/djpeg applications */
|
|
||||||
#include "jversion.h" /* for version message */
|
|
||||||
#include "jconfigint.h"
|
|
||||||
|
|
||||||
#include <ctype.h> /* to declare isprint() */
|
|
||||||
|
|
||||||
|
|
||||||
/* Create the add-on message string table. */
|
|
||||||
|
|
||||||
#define JMESSAGE(code, string) string,
|
|
||||||
|
|
||||||
static const char * const cdjpeg_message_table[] = {
|
|
||||||
#include "cderror.h"
|
|
||||||
NULL
|
|
||||||
};
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* This list defines the known output image formats
|
|
||||||
* (not all of which need be supported by a given version).
|
|
||||||
* You can change the default output format by defining DEFAULT_FMT;
|
|
||||||
* indeed, you had better do so if you undefine PPM_SUPPORTED.
|
|
||||||
*/
|
|
||||||
|
|
||||||
typedef enum {
|
|
||||||
FMT_BMP, /* BMP format (Windows flavor) */
|
|
||||||
FMT_GIF, /* GIF format (LZW-compressed) */
|
|
||||||
FMT_GIF0, /* GIF format (uncompressed) */
|
|
||||||
FMT_OS2, /* BMP format (OS/2 flavor) */
|
|
||||||
FMT_PPM, /* PPM/PGM (PBMPLUS formats) */
|
|
||||||
FMT_TARGA, /* Targa format */
|
|
||||||
FMT_TIFF /* TIFF format */
|
|
||||||
} IMAGE_FORMATS;
|
|
||||||
|
|
||||||
#ifndef DEFAULT_FMT /* so can override from CFLAGS in Makefile */
|
|
||||||
#define DEFAULT_FMT FMT_PPM
|
|
||||||
#endif
|
|
||||||
|
|
||||||
static IMAGE_FORMATS requested_fmt;
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Argument-parsing code.
|
|
||||||
* The switch parser is designed to be useful with DOS-style command line
|
|
||||||
* syntax, ie, intermixed switches and file names, where only the switches
|
|
||||||
* to the left of a given file name affect processing of that file.
|
|
||||||
* The main program in this file doesn't actually use this capability...
|
|
||||||
*/
|
|
||||||
|
|
||||||
|
|
||||||
static const char *progname; /* program name for error messages */
|
|
||||||
static char *icc_filename; /* for -icc switch */
|
|
||||||
JDIMENSION max_scans; /* for -maxscans switch */
|
|
||||||
static char *outfilename; /* for -outfile switch */
|
|
||||||
boolean memsrc; /* for -memsrc switch */
|
|
||||||
boolean report; /* for -report switch */
|
|
||||||
boolean skip, crop;
|
|
||||||
JDIMENSION skip_start, skip_end;
|
|
||||||
JDIMENSION crop_x, crop_y, crop_width, crop_height;
|
|
||||||
boolean strict; /* for -strict switch */
|
|
||||||
#define INPUT_BUF_SIZE 4096
|
|
||||||
|
|
||||||
|
|
||||||
LOCAL(void)
|
|
||||||
usage(void)
|
|
||||||
/* complain about bad command line */
|
|
||||||
{
|
|
||||||
fprintf(stderr, "usage: %s [switches] ", progname);
|
|
||||||
#ifdef TWO_FILE_COMMANDLINE
|
|
||||||
fprintf(stderr, "inputfile outputfile\n");
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "[inputfile]\n");
|
|
||||||
#endif
|
|
||||||
|
|
||||||
fprintf(stderr, "Switches (names may be abbreviated):\n");
|
|
||||||
fprintf(stderr, " -colors N Reduce image to no more than N colors\n");
|
|
||||||
fprintf(stderr, " -fast Fast, low-quality processing\n");
|
|
||||||
fprintf(stderr, " -grayscale Force grayscale output\n");
|
|
||||||
fprintf(stderr, " -rgb Force RGB output\n");
|
|
||||||
fprintf(stderr, " -rgb565 Force RGB565 output\n");
|
|
||||||
#ifdef IDCT_SCALING_SUPPORTED
|
|
||||||
fprintf(stderr, " -scale M/N Scale output image by fraction M/N, eg, 1/8\n");
|
|
||||||
#endif
|
|
||||||
#ifdef BMP_SUPPORTED
|
|
||||||
fprintf(stderr, " -bmp Select BMP output format (Windows style)%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_BMP ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef GIF_SUPPORTED
|
|
||||||
fprintf(stderr, " -gif Select GIF output format (LZW-compressed)%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_GIF ? " (default)" : ""));
|
|
||||||
fprintf(stderr, " -gif0 Select GIF output format (uncompressed)%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_GIF0 ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef BMP_SUPPORTED
|
|
||||||
fprintf(stderr, " -os2 Select BMP output format (OS/2 style)%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_OS2 ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef PPM_SUPPORTED
|
|
||||||
fprintf(stderr, " -pnm Select PBMPLUS (PPM/PGM) output format%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_PPM ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
fprintf(stderr, " -targa Select Targa output format%s\n",
|
|
||||||
(DEFAULT_FMT == FMT_TARGA ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, "Switches for advanced users:\n");
|
|
||||||
#ifdef DCT_ISLOW_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct int Use accurate integer DCT method%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_ISLOW ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef DCT_IFAST_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct fast Use less accurate integer DCT method [legacy feature]%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_IFAST ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
#ifdef DCT_FLOAT_SUPPORTED
|
|
||||||
fprintf(stderr, " -dct float Use floating-point DCT method [legacy feature]%s\n",
|
|
||||||
(JDCT_DEFAULT == JDCT_FLOAT ? " (default)" : ""));
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -dither fs Use F-S dithering (default)\n");
|
|
||||||
fprintf(stderr, " -dither none Don't use dithering in quantization\n");
|
|
||||||
fprintf(stderr, " -dither ordered Use ordered dither (medium speed, quality)\n");
|
|
||||||
fprintf(stderr, " -icc FILE Extract ICC profile to FILE\n");
|
|
||||||
#ifdef QUANT_2PASS_SUPPORTED
|
|
||||||
fprintf(stderr, " -map FILE Map to colors used in named image file\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -nosmooth Don't use high-quality upsampling\n");
|
|
||||||
#ifdef QUANT_1PASS_SUPPORTED
|
|
||||||
fprintf(stderr, " -onepass Use 1-pass quantization (fast, low quality)\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -maxmemory N Maximum memory to use (in kbytes)\n");
|
|
||||||
fprintf(stderr, " -maxscans N Maximum number of scans to allow in input file\n");
|
|
||||||
fprintf(stderr, " -outfile name Specify name for output file\n");
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
fprintf(stderr, " -memsrc Load input file into memory before decompressing\n");
|
|
||||||
#endif
|
|
||||||
fprintf(stderr, " -report Report decompression progress\n");
|
|
||||||
fprintf(stderr, " -skip Y0,Y1 Decompress all rows except those between Y0 and Y1 (inclusive)\n");
|
|
||||||
fprintf(stderr, " -crop WxH+X+Y Decompress only a rectangular subregion of the image\n");
|
|
||||||
fprintf(stderr, " [requires PBMPLUS (PPM/PGM), GIF, or Targa output format]\n");
|
|
||||||
fprintf(stderr, " -strict Treat all warnings as fatal\n");
|
|
||||||
fprintf(stderr, " -verbose or -debug Emit debug output\n");
|
|
||||||
fprintf(stderr, " -version Print version information and exit\n");
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
LOCAL(int)
|
|
||||||
parse_switches(j_decompress_ptr cinfo, int argc, char **argv,
|
|
||||||
int last_file_arg_seen, boolean for_real)
|
|
||||||
/* Parse optional switches.
|
|
||||||
* Returns argv[] index of first file-name argument (== argc if none).
|
|
||||||
* Any file names with indexes <= last_file_arg_seen are ignored;
|
|
||||||
* they have presumably been processed in a previous iteration.
|
|
||||||
* (Pass 0 for last_file_arg_seen on the first or only iteration.)
|
|
||||||
* for_real is FALSE on the first (dummy) pass; we may skip any expensive
|
|
||||||
* processing.
|
|
||||||
*/
|
|
||||||
{
|
|
||||||
int argn;
|
|
||||||
char *arg;
|
|
||||||
|
|
||||||
/* Set up default JPEG parameters. */
|
|
||||||
requested_fmt = DEFAULT_FMT; /* set default output file format */
|
|
||||||
icc_filename = NULL;
|
|
||||||
max_scans = 0;
|
|
||||||
outfilename = NULL;
|
|
||||||
memsrc = FALSE;
|
|
||||||
report = FALSE;
|
|
||||||
skip = FALSE;
|
|
||||||
crop = FALSE;
|
|
||||||
strict = FALSE;
|
|
||||||
cinfo->err->trace_level = 0;
|
|
||||||
|
|
||||||
/* Scan command line options, adjust parameters */
|
|
||||||
|
|
||||||
for (argn = 1; argn < argc; argn++) {
|
|
||||||
arg = argv[argn];
|
|
||||||
if (*arg != '-') {
|
|
||||||
/* Not a switch, must be a file name argument */
|
|
||||||
if (argn <= last_file_arg_seen) {
|
|
||||||
outfilename = NULL; /* -outfile applies to just one input file */
|
|
||||||
continue; /* ignore this name if previously processed */
|
|
||||||
}
|
|
||||||
break; /* else done parsing switches */
|
|
||||||
}
|
|
||||||
arg++; /* advance past switch marker character */
|
|
||||||
|
|
||||||
if (keymatch(arg, "bmp", 1)) {
|
|
||||||
/* BMP output format (Windows flavor). */
|
|
||||||
requested_fmt = FMT_BMP;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "colors", 1) || keymatch(arg, "colours", 1) ||
|
|
||||||
keymatch(arg, "quantize", 1) || keymatch(arg, "quantise", 1)) {
|
|
||||||
/* Do color quantization. */
|
|
||||||
int val;
|
|
||||||
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%d", &val) != 1)
|
|
||||||
usage();
|
|
||||||
cinfo->desired_number_of_colors = val;
|
|
||||||
cinfo->quantize_colors = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "dct", 2)) {
|
|
||||||
/* Select IDCT algorithm. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (keymatch(argv[argn], "int", 1)) {
|
|
||||||
cinfo->dct_method = JDCT_ISLOW;
|
|
||||||
} else if (keymatch(argv[argn], "fast", 2)) {
|
|
||||||
cinfo->dct_method = JDCT_IFAST;
|
|
||||||
} else if (keymatch(argv[argn], "float", 2)) {
|
|
||||||
cinfo->dct_method = JDCT_FLOAT;
|
|
||||||
} else
|
|
||||||
usage();
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "dither", 2)) {
|
|
||||||
/* Select dithering algorithm. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (keymatch(argv[argn], "fs", 2)) {
|
|
||||||
cinfo->dither_mode = JDITHER_FS;
|
|
||||||
} else if (keymatch(argv[argn], "none", 2)) {
|
|
||||||
cinfo->dither_mode = JDITHER_NONE;
|
|
||||||
} else if (keymatch(argv[argn], "ordered", 2)) {
|
|
||||||
cinfo->dither_mode = JDITHER_ORDERED;
|
|
||||||
} else
|
|
||||||
usage();
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "debug", 1) || keymatch(arg, "verbose", 1)) {
|
|
||||||
/* Enable debug printouts. */
|
|
||||||
/* On first -d, print version identification */
|
|
||||||
static boolean printed_version = FALSE;
|
|
||||||
|
|
||||||
if (!printed_version) {
|
|
||||||
fprintf(stderr, "%s version %s (build %s)\n",
|
|
||||||
PACKAGE_NAME, VERSION, BUILD);
|
|
||||||
fprintf(stderr, "%s\n\n", JCOPYRIGHT);
|
|
||||||
fprintf(stderr, "Emulating The Independent JPEG Group's software, version %s\n\n",
|
|
||||||
JVERSION);
|
|
||||||
printed_version = TRUE;
|
|
||||||
}
|
|
||||||
cinfo->err->trace_level++;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "version", 4)) {
|
|
||||||
fprintf(stderr, "%s version %s (build %s)\n",
|
|
||||||
PACKAGE_NAME, VERSION, BUILD);
|
|
||||||
exit(EXIT_SUCCESS);
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "fast", 1)) {
|
|
||||||
/* Select recommended processing options for quick-and-dirty output. */
|
|
||||||
cinfo->two_pass_quantize = FALSE;
|
|
||||||
cinfo->dither_mode = JDITHER_ORDERED;
|
|
||||||
if (!cinfo->quantize_colors) /* don't override an earlier -colors */
|
|
||||||
cinfo->desired_number_of_colors = 216;
|
|
||||||
cinfo->dct_method = JDCT_FASTEST;
|
|
||||||
cinfo->do_fancy_upsampling = FALSE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "gif", 1)) {
|
|
||||||
/* GIF output format (LZW-compressed). */
|
|
||||||
requested_fmt = FMT_GIF;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "gif0", 4)) {
|
|
||||||
/* GIF output format (uncompressed). */
|
|
||||||
requested_fmt = FMT_GIF0;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "grayscale", 2) ||
|
|
||||||
keymatch(arg, "greyscale", 2)) {
|
|
||||||
/* Force monochrome output. */
|
|
||||||
cinfo->out_color_space = JCS_GRAYSCALE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "rgb", 2)) {
|
|
||||||
/* Force RGB output. */
|
|
||||||
cinfo->out_color_space = JCS_RGB;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "rgb565", 2)) {
|
|
||||||
/* Force RGB565 output. */
|
|
||||||
cinfo->out_color_space = JCS_RGB565;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "icc", 1)) {
|
|
||||||
/* Set ICC filename. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
icc_filename = argv[argn];
|
|
||||||
#ifdef SAVE_MARKERS_SUPPORTED
|
|
||||||
jpeg_save_markers(cinfo, JPEG_APP0 + 2, 0xFFFF);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "map", 3)) {
|
|
||||||
/* Quantize to a color map taken from an input file. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (for_real) { /* too expensive to do twice! */
|
|
||||||
#ifdef QUANT_2PASS_SUPPORTED /* otherwise can't quantize to supplied map */
|
|
||||||
FILE *mapfile;
|
|
||||||
|
|
||||||
if ((mapfile = fopen(argv[argn], READ_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, argv[argn]);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
read_color_map(cinfo, mapfile);
|
|
||||||
fclose(mapfile);
|
|
||||||
cinfo->quantize_colors = TRUE;
|
|
||||||
#else
|
|
||||||
ERREXIT(cinfo, JERR_NOT_COMPILED);
|
|
||||||
#endif
|
|
||||||
}
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "maxmemory", 3)) {
|
|
||||||
/* Maximum memory in Kb (or Mb with 'm'). */
|
|
||||||
long lval;
|
|
||||||
char ch = 'x';
|
|
||||||
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%ld%c", &lval, &ch) < 1)
|
|
||||||
usage();
|
|
||||||
if (ch == 'm' || ch == 'M')
|
|
||||||
lval *= 1000L;
|
|
||||||
cinfo->mem->max_memory_to_use = lval * 1000L;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "maxscans", 4)) {
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%u", &max_scans) != 1)
|
|
||||||
usage();
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "nosmooth", 3)) {
|
|
||||||
/* Suppress fancy upsampling */
|
|
||||||
cinfo->do_fancy_upsampling = FALSE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "onepass", 3)) {
|
|
||||||
/* Use fast one-pass quantization. */
|
|
||||||
cinfo->two_pass_quantize = FALSE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "os2", 3)) {
|
|
||||||
/* BMP output format (OS/2 flavor). */
|
|
||||||
requested_fmt = FMT_OS2;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "outfile", 4)) {
|
|
||||||
/* Set output file name. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
outfilename = argv[argn]; /* save it away for later use */
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "memsrc", 2)) {
|
|
||||||
/* Use in-memory source manager */
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
memsrc = TRUE;
|
|
||||||
#else
|
|
||||||
fprintf(stderr, "%s: sorry, in-memory source manager was not compiled in\n",
|
|
||||||
progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
#endif
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "pnm", 1) || keymatch(arg, "ppm", 1)) {
|
|
||||||
/* PPM/PGM output format. */
|
|
||||||
requested_fmt = FMT_PPM;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "report", 2)) {
|
|
||||||
report = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "scale", 2)) {
|
|
||||||
/* Scale the output image by a fraction M/N. */
|
|
||||||
if (++argn >= argc) /* advance to next argument */
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%u/%u",
|
|
||||||
&cinfo->scale_num, &cinfo->scale_denom) != 2)
|
|
||||||
usage();
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "skip", 2)) {
|
|
||||||
if (++argn >= argc)
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%u,%u", &skip_start, &skip_end) != 2 ||
|
|
||||||
skip_start > skip_end)
|
|
||||||
usage();
|
|
||||||
skip = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "crop", 2)) {
|
|
||||||
char c;
|
|
||||||
if (++argn >= argc)
|
|
||||||
usage();
|
|
||||||
if (sscanf(argv[argn], "%u%c%u+%u+%u", &crop_width, &c, &crop_height,
|
|
||||||
&crop_x, &crop_y) != 5 ||
|
|
||||||
(c != 'X' && c != 'x') || crop_width < 1 || crop_height < 1)
|
|
||||||
usage();
|
|
||||||
crop = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "strict", 2)) {
|
|
||||||
strict = TRUE;
|
|
||||||
|
|
||||||
} else if (keymatch(arg, "targa", 1)) {
|
|
||||||
/* Targa output format. */
|
|
||||||
requested_fmt = FMT_TARGA;
|
|
||||||
|
|
||||||
} else {
|
|
||||||
usage(); /* bogus switch */
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
return argn; /* return index of next arg (file name) */
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* Marker processor for COM and interesting APPn markers.
|
|
||||||
* This replaces the library's built-in processor, which just skips the marker.
|
|
||||||
* We want to print out the marker as text, to the extent possible.
|
|
||||||
* Note this code relies on a non-suspending data source.
|
|
||||||
*/
|
|
||||||
|
|
||||||
LOCAL(unsigned int)
|
|
||||||
jpeg_getc(j_decompress_ptr cinfo)
|
|
||||||
/* Read next byte */
|
|
||||||
{
|
|
||||||
struct jpeg_source_mgr *datasrc = cinfo->src;
|
|
||||||
|
|
||||||
if (datasrc->bytes_in_buffer == 0) {
|
|
||||||
if (!(*datasrc->fill_input_buffer) (cinfo))
|
|
||||||
ERREXIT(cinfo, JERR_CANT_SUSPEND);
|
|
||||||
}
|
|
||||||
datasrc->bytes_in_buffer--;
|
|
||||||
return *datasrc->next_input_byte++;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
METHODDEF(boolean)
|
|
||||||
print_text_marker(j_decompress_ptr cinfo)
|
|
||||||
{
|
|
||||||
boolean traceit = (cinfo->err->trace_level >= 1);
|
|
||||||
long length;
|
|
||||||
unsigned int ch;
|
|
||||||
unsigned int lastch = 0;
|
|
||||||
|
|
||||||
length = jpeg_getc(cinfo) << 8;
|
|
||||||
length += jpeg_getc(cinfo);
|
|
||||||
length -= 2; /* discount the length word itself */
|
|
||||||
|
|
||||||
if (traceit) {
|
|
||||||
if (cinfo->unread_marker == JPEG_COM)
|
|
||||||
fprintf(stderr, "Comment, length %ld:\n", (long)length);
|
|
||||||
else /* assume it is an APPn otherwise */
|
|
||||||
fprintf(stderr, "APP%d, length %ld:\n",
|
|
||||||
cinfo->unread_marker - JPEG_APP0, (long)length);
|
|
||||||
}
|
|
||||||
|
|
||||||
while (--length >= 0) {
|
|
||||||
ch = jpeg_getc(cinfo);
|
|
||||||
if (traceit) {
|
|
||||||
/* Emit the character in a readable form.
|
|
||||||
* Nonprintables are converted to \nnn form,
|
|
||||||
* while \ is converted to \\.
|
|
||||||
* Newlines in CR, CR/LF, or LF form will be printed as one newline.
|
|
||||||
*/
|
|
||||||
if (ch == '\r') {
|
|
||||||
fprintf(stderr, "\n");
|
|
||||||
} else if (ch == '\n') {
|
|
||||||
if (lastch != '\r')
|
|
||||||
fprintf(stderr, "\n");
|
|
||||||
} else if (ch == '\\') {
|
|
||||||
fprintf(stderr, "\\\\");
|
|
||||||
} else if (isprint(ch)) {
|
|
||||||
putc(ch, stderr);
|
|
||||||
} else {
|
|
||||||
fprintf(stderr, "\\%03o", ch);
|
|
||||||
}
|
|
||||||
lastch = ch;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (traceit)
|
|
||||||
fprintf(stderr, "\n");
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
METHODDEF(void)
|
|
||||||
my_emit_message(j_common_ptr cinfo, int msg_level)
|
|
||||||
{
|
|
||||||
if (msg_level < 0) {
|
|
||||||
/* Treat warning as fatal */
|
|
||||||
cinfo->err->error_exit(cinfo);
|
|
||||||
} else {
|
|
||||||
if (cinfo->err->trace_level >= msg_level)
|
|
||||||
cinfo->err->output_message(cinfo);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* The main program.
|
|
||||||
*/
|
|
||||||
|
|
||||||
int
|
|
||||||
main(int argc, char **argv)
|
|
||||||
{
|
|
||||||
struct jpeg_decompress_struct cinfo;
|
|
||||||
struct jpeg_error_mgr jerr;
|
|
||||||
struct cdjpeg_progress_mgr progress;
|
|
||||||
int file_index;
|
|
||||||
djpeg_dest_ptr dest_mgr = NULL;
|
|
||||||
FILE *input_file;
|
|
||||||
FILE *output_file;
|
|
||||||
unsigned char *inbuffer = NULL;
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
unsigned long insize = 0;
|
|
||||||
#endif
|
|
||||||
JDIMENSION num_scanlines;
|
|
||||||
|
|
||||||
progname = argv[0];
|
|
||||||
if (progname == NULL || progname[0] == 0)
|
|
||||||
progname = "djpeg"; /* in case C library doesn't provide it */
|
|
||||||
|
|
||||||
/* Initialize the JPEG decompression object with default error handling. */
|
|
||||||
cinfo.err = jpeg_std_error(&jerr);
|
|
||||||
jpeg_create_decompress(&cinfo);
|
|
||||||
/* Add some application-specific error messages (from cderror.h) */
|
|
||||||
jerr.addon_message_table = cdjpeg_message_table;
|
|
||||||
jerr.first_addon_message = JMSG_FIRSTADDONCODE;
|
|
||||||
jerr.last_addon_message = JMSG_LASTADDONCODE;
|
|
||||||
|
|
||||||
/* Insert custom marker processor for COM and APP12.
|
|
||||||
* APP12 is used by some digital camera makers for textual info,
|
|
||||||
* so we provide the ability to display it as text.
|
|
||||||
* If you like, additional APPn marker types can be selected for display,
|
|
||||||
* but don't try to override APP0 or APP14 this way (see libjpeg.txt).
|
|
||||||
*/
|
|
||||||
jpeg_set_marker_processor(&cinfo, JPEG_COM, print_text_marker);
|
|
||||||
jpeg_set_marker_processor(&cinfo, JPEG_APP0 + 12, print_text_marker);
|
|
||||||
|
|
||||||
/* Scan command line to find file names. */
|
|
||||||
/* It is convenient to use just one switch-parsing routine, but the switch
|
|
||||||
* values read here are ignored; we will rescan the switches after opening
|
|
||||||
* the input file.
|
|
||||||
* (Exception: tracing level set here controls verbosity for COM markers
|
|
||||||
* found during jpeg_read_header...)
|
|
||||||
*/
|
|
||||||
|
|
||||||
file_index = parse_switches(&cinfo, argc, argv, 0, FALSE);
|
|
||||||
|
|
||||||
if (strict)
|
|
||||||
jerr.emit_message = my_emit_message;
|
|
||||||
|
|
||||||
#ifdef TWO_FILE_COMMANDLINE
|
|
||||||
/* Must have either -outfile switch or explicit output file name */
|
|
||||||
if (outfilename == NULL) {
|
|
||||||
if (file_index != argc - 2) {
|
|
||||||
fprintf(stderr, "%s: must name one input and one output file\n",
|
|
||||||
progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
outfilename = argv[file_index + 1];
|
|
||||||
} else {
|
|
||||||
if (file_index != argc - 1) {
|
|
||||||
fprintf(stderr, "%s: must name one input and one output file\n",
|
|
||||||
progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
#else
|
|
||||||
/* Unix style: expect zero or one file name */
|
|
||||||
if (file_index < argc - 1) {
|
|
||||||
fprintf(stderr, "%s: only one input file\n", progname);
|
|
||||||
usage();
|
|
||||||
}
|
|
||||||
#endif /* TWO_FILE_COMMANDLINE */
|
|
||||||
|
|
||||||
/* Open the input file. */
|
|
||||||
if (file_index < argc) {
|
|
||||||
if ((input_file = fopen(argv[file_index], READ_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, argv[file_index]);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* default input file is stdin */
|
|
||||||
input_file = read_stdin();
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Open the output file. */
|
|
||||||
if (outfilename != NULL) {
|
|
||||||
if ((output_file = fopen(outfilename, WRITE_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, outfilename);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
} else {
|
|
||||||
/* default output file is stdout */
|
|
||||||
output_file = write_stdout();
|
|
||||||
}
|
|
||||||
|
|
||||||
if (report || max_scans != 0) {
|
|
||||||
start_progress_monitor((j_common_ptr)&cinfo, &progress);
|
|
||||||
progress.report = report;
|
|
||||||
progress.max_scans = max_scans;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Specify data source for decompression */
|
|
||||||
#if JPEG_LIB_VERSION >= 80 || defined(MEM_SRCDST_SUPPORTED)
|
|
||||||
if (memsrc) {
|
|
||||||
size_t nbytes;
|
|
||||||
do {
|
|
||||||
inbuffer = (unsigned char *)realloc(inbuffer, insize + INPUT_BUF_SIZE);
|
|
||||||
if (inbuffer == NULL) {
|
|
||||||
fprintf(stderr, "%s: memory allocation failure\n", progname);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
nbytes = fread(&inbuffer[insize], 1, INPUT_BUF_SIZE, input_file);
|
|
||||||
if (nbytes < INPUT_BUF_SIZE && ferror(input_file)) {
|
|
||||||
if (file_index < argc)
|
|
||||||
fprintf(stderr, "%s: can't read from %s\n", progname,
|
|
||||||
argv[file_index]);
|
|
||||||
else
|
|
||||||
fprintf(stderr, "%s: can't read from stdin\n", progname);
|
|
||||||
}
|
|
||||||
insize += (unsigned long)nbytes;
|
|
||||||
} while (nbytes == INPUT_BUF_SIZE);
|
|
||||||
fprintf(stderr, "Compressed size: %lu bytes\n", insize);
|
|
||||||
jpeg_mem_src(&cinfo, inbuffer, insize);
|
|
||||||
} else
|
|
||||||
#endif
|
|
||||||
jpeg_stdio_src(&cinfo, input_file);
|
|
||||||
|
|
||||||
/* Read file header, set default decompression parameters */
|
|
||||||
(void)jpeg_read_header(&cinfo, TRUE);
|
|
||||||
|
|
||||||
/* Adjust default decompression parameters by re-parsing the options */
|
|
||||||
file_index = parse_switches(&cinfo, argc, argv, 0, TRUE);
|
|
||||||
|
|
||||||
/* Initialize the output module now to let it override any crucial
|
|
||||||
* option settings (for instance, GIF wants to force color quantization).
|
|
||||||
*/
|
|
||||||
switch (requested_fmt) {
|
|
||||||
#ifdef BMP_SUPPORTED
|
|
||||||
case FMT_BMP:
|
|
||||||
dest_mgr = jinit_write_bmp(&cinfo, FALSE, TRUE);
|
|
||||||
break;
|
|
||||||
case FMT_OS2:
|
|
||||||
dest_mgr = jinit_write_bmp(&cinfo, TRUE, TRUE);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
#ifdef GIF_SUPPORTED
|
|
||||||
case FMT_GIF:
|
|
||||||
dest_mgr = jinit_write_gif(&cinfo, TRUE);
|
|
||||||
break;
|
|
||||||
case FMT_GIF0:
|
|
||||||
dest_mgr = jinit_write_gif(&cinfo, FALSE);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
#ifdef PPM_SUPPORTED
|
|
||||||
case FMT_PPM:
|
|
||||||
dest_mgr = jinit_write_ppm(&cinfo);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
#ifdef TARGA_SUPPORTED
|
|
||||||
case FMT_TARGA:
|
|
||||||
dest_mgr = jinit_write_targa(&cinfo);
|
|
||||||
break;
|
|
||||||
#endif
|
|
||||||
default:
|
|
||||||
ERREXIT(&cinfo, JERR_UNSUPPORTED_FORMAT);
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
dest_mgr->output_file = output_file;
|
|
||||||
|
|
||||||
/* Start decompressor */
|
|
||||||
(void)jpeg_start_decompress(&cinfo);
|
|
||||||
|
|
||||||
/* Skip rows */
|
|
||||||
if (skip) {
|
|
||||||
JDIMENSION tmp;
|
|
||||||
|
|
||||||
/* Check for valid skip_end. We cannot check this value until after
|
|
||||||
* jpeg_start_decompress() is called. Note that we have already verified
|
|
||||||
* that skip_start <= skip_end.
|
|
||||||
*/
|
|
||||||
if (skip_end > cinfo.output_height - 1) {
|
|
||||||
fprintf(stderr, "%s: skip region exceeds image height %u\n", progname,
|
|
||||||
cinfo.output_height);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Write output file header. This is a hack to ensure that the destination
|
|
||||||
* manager creates an output image of the proper size.
|
|
||||||
*/
|
|
||||||
tmp = cinfo.output_height;
|
|
||||||
cinfo.output_height -= (skip_end - skip_start + 1);
|
|
||||||
(*dest_mgr->start_output) (&cinfo, dest_mgr);
|
|
||||||
cinfo.output_height = tmp;
|
|
||||||
|
|
||||||
/* Process data */
|
|
||||||
while (cinfo.output_scanline < skip_start) {
|
|
||||||
num_scanlines = jpeg_read_scanlines(&cinfo, dest_mgr->buffer,
|
|
||||||
dest_mgr->buffer_height);
|
|
||||||
(*dest_mgr->put_pixel_rows) (&cinfo, dest_mgr, num_scanlines);
|
|
||||||
}
|
|
||||||
if ((tmp = jpeg_skip_scanlines(&cinfo, skip_end - skip_start + 1)) !=
|
|
||||||
skip_end - skip_start + 1) {
|
|
||||||
fprintf(stderr, "%s: jpeg_skip_scanlines() returned %u rather than %u\n",
|
|
||||||
progname, tmp, skip_end - skip_start + 1);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
while (cinfo.output_scanline < cinfo.output_height) {
|
|
||||||
num_scanlines = jpeg_read_scanlines(&cinfo, dest_mgr->buffer,
|
|
||||||
dest_mgr->buffer_height);
|
|
||||||
(*dest_mgr->put_pixel_rows) (&cinfo, dest_mgr, num_scanlines);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Decompress a subregion */
|
|
||||||
} else if (crop) {
|
|
||||||
JDIMENSION tmp;
|
|
||||||
|
|
||||||
/* Check for valid crop dimensions. We cannot check these values until
|
|
||||||
* after jpeg_start_decompress() is called.
|
|
||||||
*/
|
|
||||||
if (crop_x + crop_width > cinfo.output_width ||
|
|
||||||
crop_y + crop_height > cinfo.output_height) {
|
|
||||||
fprintf(stderr, "%s: crop dimensions exceed image dimensions %u x %u\n",
|
|
||||||
progname, cinfo.output_width, cinfo.output_height);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
jpeg_crop_scanline(&cinfo, &crop_x, &crop_width);
|
|
||||||
if (dest_mgr->calc_buffer_dimensions)
|
|
||||||
(*dest_mgr->calc_buffer_dimensions) (&cinfo, dest_mgr);
|
|
||||||
else
|
|
||||||
ERREXIT(&cinfo, JERR_UNSUPPORTED_FORMAT);
|
|
||||||
|
|
||||||
/* Write output file header. This is a hack to ensure that the destination
|
|
||||||
* manager creates an output image of the proper size.
|
|
||||||
*/
|
|
||||||
tmp = cinfo.output_height;
|
|
||||||
cinfo.output_height = crop_height;
|
|
||||||
(*dest_mgr->start_output) (&cinfo, dest_mgr);
|
|
||||||
cinfo.output_height = tmp;
|
|
||||||
|
|
||||||
/* Process data */
|
|
||||||
if ((tmp = jpeg_skip_scanlines(&cinfo, crop_y)) != crop_y) {
|
|
||||||
fprintf(stderr, "%s: jpeg_skip_scanlines() returned %u rather than %u\n",
|
|
||||||
progname, tmp, crop_y);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
while (cinfo.output_scanline < crop_y + crop_height) {
|
|
||||||
num_scanlines = jpeg_read_scanlines(&cinfo, dest_mgr->buffer,
|
|
||||||
dest_mgr->buffer_height);
|
|
||||||
(*dest_mgr->put_pixel_rows) (&cinfo, dest_mgr, num_scanlines);
|
|
||||||
}
|
|
||||||
if ((tmp =
|
|
||||||
jpeg_skip_scanlines(&cinfo,
|
|
||||||
cinfo.output_height - crop_y - crop_height)) !=
|
|
||||||
cinfo.output_height - crop_y - crop_height) {
|
|
||||||
fprintf(stderr, "%s: jpeg_skip_scanlines() returned %u rather than %u\n",
|
|
||||||
progname, tmp, cinfo.output_height - crop_y - crop_height);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Normal full-image decompress */
|
|
||||||
} else {
|
|
||||||
/* Write output file header */
|
|
||||||
(*dest_mgr->start_output) (&cinfo, dest_mgr);
|
|
||||||
|
|
||||||
/* Process data */
|
|
||||||
while (cinfo.output_scanline < cinfo.output_height) {
|
|
||||||
num_scanlines = jpeg_read_scanlines(&cinfo, dest_mgr->buffer,
|
|
||||||
dest_mgr->buffer_height);
|
|
||||||
(*dest_mgr->put_pixel_rows) (&cinfo, dest_mgr, num_scanlines);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Hack: count final pass as done in case finish_output does an extra pass.
|
|
||||||
* The library won't have updated completed_passes.
|
|
||||||
*/
|
|
||||||
if (report || max_scans != 0)
|
|
||||||
progress.pub.completed_passes = progress.pub.total_passes;
|
|
||||||
|
|
||||||
if (icc_filename != NULL) {
|
|
||||||
FILE *icc_file;
|
|
||||||
JOCTET *icc_profile;
|
|
||||||
unsigned int icc_len;
|
|
||||||
|
|
||||||
if ((icc_file = fopen(icc_filename, WRITE_BINARY)) == NULL) {
|
|
||||||
fprintf(stderr, "%s: can't open %s\n", progname, icc_filename);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
if (jpeg_read_icc_profile(&cinfo, &icc_profile, &icc_len)) {
|
|
||||||
if (fwrite(icc_profile, icc_len, 1, icc_file) < 1) {
|
|
||||||
fprintf(stderr, "%s: can't read ICC profile from %s\n", progname,
|
|
||||||
icc_filename);
|
|
||||||
free(icc_profile);
|
|
||||||
fclose(icc_file);
|
|
||||||
exit(EXIT_FAILURE);
|
|
||||||
}
|
|
||||||
free(icc_profile);
|
|
||||||
fclose(icc_file);
|
|
||||||
} else if (cinfo.err->msg_code != JWRN_BOGUS_ICC)
|
|
||||||
fprintf(stderr, "%s: no ICC profile data in JPEG file\n", progname);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Finish decompression and release memory.
|
|
||||||
* I must do it in this order because output module has allocated memory
|
|
||||||
* of lifespan JPOOL_IMAGE; it needs to finish before releasing memory.
|
|
||||||
*/
|
|
||||||
(*dest_mgr->finish_output) (&cinfo, dest_mgr);
|
|
||||||
(void)jpeg_finish_decompress(&cinfo);
|
|
||||||
jpeg_destroy_decompress(&cinfo);
|
|
||||||
|
|
||||||
/* Close files, if we opened them */
|
|
||||||
if (input_file != stdin)
|
|
||||||
fclose(input_file);
|
|
||||||
if (output_file != stdout)
|
|
||||||
fclose(output_file);
|
|
||||||
|
|
||||||
if (report || max_scans != 0)
|
|
||||||
end_progress_monitor((j_common_ptr)&cinfo);
|
|
||||||
|
|
||||||
if (memsrc)
|
|
||||||
free(inbuffer);
|
|
||||||
|
|
||||||
/* All done. */
|
|
||||||
exit(jerr.num_warnings ? EXIT_WARNING : EXIT_SUCCESS);
|
|
||||||
return 0; /* suppress no-return-value warnings */
|
|
||||||
}
|
|
||||||
@@ -1,83 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Data Structures</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="header">
|
|
||||||
<div class="headertitle">
|
|
||||||
<div class="title">Data Structures</div> </div>
|
|
||||||
</div><!--header-->
|
|
||||||
<div class="contents">
|
|
||||||
<div class="textblock">Here are the data structures with brief descriptions:</div><div class="directory">
|
|
||||||
<table class="directory">
|
|
||||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="structtjregion.html" target="_self">tjregion</a></td><td class="desc">Cropping region </td></tr>
|
|
||||||
<tr id="row_1_"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="structtjscalingfactor.html" target="_self">tjscalingfactor</a></td><td class="desc">Scaling factor </td></tr>
|
|
||||||
<tr id="row_2_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><span class="icona"><span class="icon">C</span></span><a class="el" href="structtjtransform.html" target="_self">tjtransform</a></td><td class="desc">Lossless transform </td></tr>
|
|
||||||
</table>
|
|
||||||
</div><!-- directory -->
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
BIN
android/extern/libjpeg-turbo/doc/html/bc_s.png
vendored
|
Before Width: | Height: | Size: 676 B |
BIN
android/extern/libjpeg-turbo/doc/html/bdwn.png
vendored
|
Before Width: | Height: | Size: 147 B |
@@ -1,89 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Data Structure Index</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="header">
|
|
||||||
<div class="headertitle">
|
|
||||||
<div class="title">Data Structure Index</div> </div>
|
|
||||||
</div><!--header-->
|
|
||||||
<div class="contents">
|
|
||||||
<div class="qindex"><a class="qindex" href="#letter_t">t</a></div>
|
|
||||||
<table class="classindex">
|
|
||||||
<tr><td rowspan="2" valign="bottom"><a name="letter_t"></a><table border="0" cellspacing="0" cellpadding="0"><tr><td><div class="ah">  t  </div></td></tr></table>
|
|
||||||
</td>
|
|
||||||
<td valign="top"><a class="el" href="structtjscalingfactor.html">tjscalingfactor</a>   </td>
|
|
||||||
<td valign="top"><a class="el" href="structtjtransform.html">tjtransform</a>   </td>
|
|
||||||
<td></td></tr>
|
|
||||||
<tr><td></td><td></td><td></td></tr>
|
|
||||||
<tr><td valign="top"><a class="el" href="structtjregion.html">tjregion</a>   </td>
|
|
||||||
<td></td><td></td><td></td></tr>
|
|
||||||
<tr><td></td><td></td><td></td><td></td></tr>
|
|
||||||
</table>
|
|
||||||
<div class="qindex"><a class="qindex" href="#letter_t">t</a></div>
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
BIN
android/extern/libjpeg-turbo/doc/html/closed.png
vendored
|
Before Width: | Height: | Size: 132 B |
BIN
android/extern/libjpeg-turbo/doc/html/doc.png
vendored
|
Before Width: | Height: | Size: 746 B |
@@ -1,3 +0,0 @@
|
|||||||
code {
|
|
||||||
color: #4665A2;
|
|
||||||
}
|
|
||||||
1732
android/extern/libjpeg-turbo/doc/html/doxygen.css
vendored
|
Before Width: | Height: | Size: 15 KiB |
121
android/extern/libjpeg-turbo/doc/html/dynsections.js
vendored
@@ -1,121 +0,0 @@
|
|||||||
/*
|
|
||||||
@licstart The following is the entire license notice for the JavaScript code in this file.
|
|
||||||
|
|
||||||
The MIT License (MIT)
|
|
||||||
|
|
||||||
Copyright (C) 1997-2020 by Dimitri van Heesch
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
||||||
and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
||||||
including without limitation the rights to use, copy, modify, merge, publish, distribute,
|
|
||||||
sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or
|
|
||||||
substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
|
|
||||||
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
||||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
||||||
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
|
|
||||||
@licend The above is the entire license notice for the JavaScript code in this file
|
|
||||||
*/
|
|
||||||
function toggleVisibility(linkObj)
|
|
||||||
{
|
|
||||||
var base = $(linkObj).attr('id');
|
|
||||||
var summary = $('#'+base+'-summary');
|
|
||||||
var content = $('#'+base+'-content');
|
|
||||||
var trigger = $('#'+base+'-trigger');
|
|
||||||
var src=$(trigger).attr('src');
|
|
||||||
if (content.is(':visible')===true) {
|
|
||||||
content.hide();
|
|
||||||
summary.show();
|
|
||||||
$(linkObj).addClass('closed').removeClass('opened');
|
|
||||||
$(trigger).attr('src',src.substring(0,src.length-8)+'closed.png');
|
|
||||||
} else {
|
|
||||||
content.show();
|
|
||||||
summary.hide();
|
|
||||||
$(linkObj).removeClass('closed').addClass('opened');
|
|
||||||
$(trigger).attr('src',src.substring(0,src.length-10)+'open.png');
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
function updateStripes()
|
|
||||||
{
|
|
||||||
$('table.directory tr').
|
|
||||||
removeClass('even').filter(':visible:even').addClass('even');
|
|
||||||
}
|
|
||||||
|
|
||||||
function toggleLevel(level)
|
|
||||||
{
|
|
||||||
$('table.directory tr').each(function() {
|
|
||||||
var l = this.id.split('_').length-1;
|
|
||||||
var i = $('#img'+this.id.substring(3));
|
|
||||||
var a = $('#arr'+this.id.substring(3));
|
|
||||||
if (l<level+1) {
|
|
||||||
i.removeClass('iconfopen iconfclosed').addClass('iconfopen');
|
|
||||||
a.html('▼');
|
|
||||||
$(this).show();
|
|
||||||
} else if (l==level+1) {
|
|
||||||
i.removeClass('iconfclosed iconfopen').addClass('iconfclosed');
|
|
||||||
a.html('►');
|
|
||||||
$(this).show();
|
|
||||||
} else {
|
|
||||||
$(this).hide();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
updateStripes();
|
|
||||||
}
|
|
||||||
|
|
||||||
function toggleFolder(id)
|
|
||||||
{
|
|
||||||
// the clicked row
|
|
||||||
var currentRow = $('#row_'+id);
|
|
||||||
|
|
||||||
// all rows after the clicked row
|
|
||||||
var rows = currentRow.nextAll("tr");
|
|
||||||
|
|
||||||
var re = new RegExp('^row_'+id+'\\d+_$', "i"); //only one sub
|
|
||||||
|
|
||||||
// only match elements AFTER this one (can't hide elements before)
|
|
||||||
var childRows = rows.filter(function() { return this.id.match(re); });
|
|
||||||
|
|
||||||
// first row is visible we are HIDING
|
|
||||||
if (childRows.filter(':first').is(':visible')===true) {
|
|
||||||
// replace down arrow by right arrow for current row
|
|
||||||
var currentRowSpans = currentRow.find("span");
|
|
||||||
currentRowSpans.filter(".iconfopen").removeClass("iconfopen").addClass("iconfclosed");
|
|
||||||
currentRowSpans.filter(".arrow").html('►');
|
|
||||||
rows.filter("[id^=row_"+id+"]").hide(); // hide all children
|
|
||||||
} else { // we are SHOWING
|
|
||||||
// replace right arrow by down arrow for current row
|
|
||||||
var currentRowSpans = currentRow.find("span");
|
|
||||||
currentRowSpans.filter(".iconfclosed").removeClass("iconfclosed").addClass("iconfopen");
|
|
||||||
currentRowSpans.filter(".arrow").html('▼');
|
|
||||||
// replace down arrows by right arrows for child rows
|
|
||||||
var childRowsSpans = childRows.find("span");
|
|
||||||
childRowsSpans.filter(".iconfopen").removeClass("iconfopen").addClass("iconfclosed");
|
|
||||||
childRowsSpans.filter(".arrow").html('►');
|
|
||||||
childRows.show(); //show all children
|
|
||||||
}
|
|
||||||
updateStripes();
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
function toggleInherit(id)
|
|
||||||
{
|
|
||||||
var rows = $('tr.inherit.'+id);
|
|
||||||
var img = $('tr.inherit_header.'+id+' img');
|
|
||||||
var src = $(img).attr('src');
|
|
||||||
if (rows.filter(':first').is(':visible')===true) {
|
|
||||||
rows.css('display','none');
|
|
||||||
$(img).attr('src',src.substring(0,src.length-8)+'closed.png');
|
|
||||||
} else {
|
|
||||||
rows.css('display','table-row'); // using show() causes jump in firefox
|
|
||||||
$(img).attr('src',src.substring(0,src.length-10)+'open.png');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
/* @license-end */
|
|
||||||
|
Before Width: | Height: | Size: 616 B |
BIN
android/extern/libjpeg-turbo/doc/html/folderopen.png
vendored
|
Before Width: | Height: | Size: 597 B |
107
android/extern/libjpeg-turbo/doc/html/functions.html
vendored
@@ -1,107 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Data Fields</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="contents">
|
|
||||||
<div class="textblock">Here is a list of all documented struct and union fields with links to the struct/union documentation for each field:</div><ul>
|
|
||||||
<li>customFilter
|
|
||||||
: <a class="el" href="structtjtransform.html#afd7fc262df33f741e120ef4183202ef5">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>data
|
|
||||||
: <a class="el" href="structtjtransform.html#a688fe8f1a8ecc12a538d9e561cf338e3">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>denom
|
|
||||||
: <a class="el" href="structtjscalingfactor.html#aefbcdf3e9e62274b2d312c695f133ce3">tjscalingfactor</a>
|
|
||||||
</li>
|
|
||||||
<li>h
|
|
||||||
: <a class="el" href="structtjregion.html#aecefc45a26f4d8b60dd4d825c1710115">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>num
|
|
||||||
: <a class="el" href="structtjscalingfactor.html#a9b011e57f981ee23083e2c1aa5e640ec">tjscalingfactor</a>
|
|
||||||
</li>
|
|
||||||
<li>op
|
|
||||||
: <a class="el" href="structtjtransform.html#a2525aab4ba6978a1c273f74fef50e498">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>options
|
|
||||||
: <a class="el" href="structtjtransform.html#ac0e74655baa4402209a21e1ae481c8f6">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>r
|
|
||||||
: <a class="el" href="structtjtransform.html#ac324e5e442abec8a961e5bf219db12cf">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>w
|
|
||||||
: <a class="el" href="structtjregion.html#ab6eb73ceef584fc23c8c8097926dce42">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>x
|
|
||||||
: <a class="el" href="structtjregion.html#a4b6a37a93997091b26a75831fa291ad9">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>y
|
|
||||||
: <a class="el" href="structtjregion.html#a7b3e0c24cfe87acc80e334cafdcf22c2">tjregion</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,107 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Data Fields - Variables</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="contents">
|
|
||||||
 <ul>
|
|
||||||
<li>customFilter
|
|
||||||
: <a class="el" href="structtjtransform.html#afd7fc262df33f741e120ef4183202ef5">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>data
|
|
||||||
: <a class="el" href="structtjtransform.html#a688fe8f1a8ecc12a538d9e561cf338e3">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>denom
|
|
||||||
: <a class="el" href="structtjscalingfactor.html#aefbcdf3e9e62274b2d312c695f133ce3">tjscalingfactor</a>
|
|
||||||
</li>
|
|
||||||
<li>h
|
|
||||||
: <a class="el" href="structtjregion.html#aecefc45a26f4d8b60dd4d825c1710115">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>num
|
|
||||||
: <a class="el" href="structtjscalingfactor.html#a9b011e57f981ee23083e2c1aa5e640ec">tjscalingfactor</a>
|
|
||||||
</li>
|
|
||||||
<li>op
|
|
||||||
: <a class="el" href="structtjtransform.html#a2525aab4ba6978a1c273f74fef50e498">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>options
|
|
||||||
: <a class="el" href="structtjtransform.html#ac0e74655baa4402209a21e1ae481c8f6">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>r
|
|
||||||
: <a class="el" href="structtjtransform.html#ac324e5e442abec8a961e5bf219db12cf">tjtransform</a>
|
|
||||||
</li>
|
|
||||||
<li>w
|
|
||||||
: <a class="el" href="structtjregion.html#ab6eb73ceef584fc23c8c8097926dce42">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>x
|
|
||||||
: <a class="el" href="structtjregion.html#a4b6a37a93997091b26a75831fa291ad9">tjregion</a>
|
|
||||||
</li>
|
|
||||||
<li>y
|
|
||||||
: <a class="el" href="structtjregion.html#a7b3e0c24cfe87acc80e334cafdcf22c2">tjregion</a>
|
|
||||||
</li>
|
|
||||||
</ul>
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
76
android/extern/libjpeg-turbo/doc/html/index.html
vendored
@@ -1,76 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Main Page</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="header">
|
|
||||||
<div class="headertitle">
|
|
||||||
<div class="title">TurboJPEG Documentation</div> </div>
|
|
||||||
</div><!--header-->
|
|
||||||
<div class="contents">
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
35
android/extern/libjpeg-turbo/doc/html/jquery.js
vendored
51
android/extern/libjpeg-turbo/doc/html/menu.js
vendored
@@ -1,51 +0,0 @@
|
|||||||
/*
|
|
||||||
@licstart The following is the entire license notice for the JavaScript code in this file.
|
|
||||||
|
|
||||||
The MIT License (MIT)
|
|
||||||
|
|
||||||
Copyright (C) 1997-2020 by Dimitri van Heesch
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
||||||
and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
||||||
including without limitation the rights to use, copy, modify, merge, publish, distribute,
|
|
||||||
sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or
|
|
||||||
substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
|
|
||||||
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
||||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
||||||
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
|
|
||||||
@licend The above is the entire license notice for the JavaScript code in this file
|
|
||||||
*/
|
|
||||||
function initMenu(relPath,searchEnabled,serverSide,searchPage,search) {
|
|
||||||
function makeTree(data,relPath) {
|
|
||||||
var result='';
|
|
||||||
if ('children' in data) {
|
|
||||||
result+='<ul>';
|
|
||||||
for (var i in data.children) {
|
|
||||||
result+='<li><a href="'+relPath+data.children[i].url+'">'+
|
|
||||||
data.children[i].text+'</a>'+
|
|
||||||
makeTree(data.children[i],relPath)+'</li>';
|
|
||||||
}
|
|
||||||
result+='</ul>';
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
$('#main-nav').append(makeTree(menudata,relPath));
|
|
||||||
$('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu');
|
|
||||||
if (searchEnabled) {
|
|
||||||
if (serverSide) {
|
|
||||||
$('#main-menu').append('<li style="float:right"><div id="MSearchBox" class="MSearchBoxInactive"><div class="left"><form id="FSearchBox" action="'+relPath+searchPage+'" method="get"><img id="MSearchSelect" src="'+relPath+'search/mag.svg" alt=""/><input type="text" id="MSearchField" name="query" value="'+search+'" size="20" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)"></form></div><div class="right"></div></div></li>');
|
|
||||||
} else {
|
|
||||||
$('#main-menu').append('<li style="float:right"><div id="MSearchBox" class="MSearchBoxInactive"><span class="left"><img id="MSearchSelect" src="'+relPath+'search/mag_sel.svg" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()" alt=""/><input type="text" id="MSearchField" value="'+search+'" accesskey="S" onfocus="searchBox.OnSearchFieldFocus(true)" onblur="searchBox.OnSearchFieldFocus(false)" onkeyup="searchBox.OnSearchFieldChange(event)"/></span><span class="right"><a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="'+relPath+'search/close.svg" alt=""/></a></span></div></li>');
|
|
||||||
}
|
|
||||||
}
|
|
||||||
$('#main-menu').smartmenus();
|
|
||||||
}
|
|
||||||
/* @license-end */
|
|
||||||
@@ -1,33 +0,0 @@
|
|||||||
/*
|
|
||||||
@licstart The following is the entire license notice for the JavaScript code in this file.
|
|
||||||
|
|
||||||
The MIT License (MIT)
|
|
||||||
|
|
||||||
Copyright (C) 1997-2020 by Dimitri van Heesch
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
||||||
and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
||||||
including without limitation the rights to use, copy, modify, merge, publish, distribute,
|
|
||||||
sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or
|
|
||||||
substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
|
|
||||||
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
||||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
||||||
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
|
|
||||||
@licend The above is the entire license notice for the JavaScript code in this file
|
|
||||||
*/
|
|
||||||
var menudata={children:[
|
|
||||||
{text:"Main Page",url:"index.html"},
|
|
||||||
{text:"Modules",url:"modules.html"},
|
|
||||||
{text:"Data Structures",url:"annotated.html",children:[
|
|
||||||
{text:"Data Structures",url:"annotated.html"},
|
|
||||||
{text:"Data Structure Index",url:"classes.html"},
|
|
||||||
{text:"Data Fields",url:"functions.html",children:[
|
|
||||||
{text:"All",url:"functions.html"},
|
|
||||||
{text:"Variables",url:"functions_vars.html"}]}]}]}
|
|
||||||
@@ -1,81 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html xmlns="http://www.w3.org/1999/xhtml">
|
|
||||||
<head>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<meta name="viewport" content="width=device-width, initial-scale=1"/>
|
|
||||||
<title>TurboJPEG: Modules</title>
|
|
||||||
<link href="tabs.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="jquery.js"></script>
|
|
||||||
<script type="text/javascript" src="dynsections.js"></script>
|
|
||||||
<link href="search/search.css" rel="stylesheet" type="text/css"/>
|
|
||||||
<script type="text/javascript" src="search/searchdata.js"></script>
|
|
||||||
<script type="text/javascript" src="search/search.js"></script>
|
|
||||||
<link href="doxygen.css" rel="stylesheet" type="text/css" />
|
|
||||||
<link href="doxygen-extra.css" rel="stylesheet" type="text/css"/>
|
|
||||||
</head>
|
|
||||||
<body>
|
|
||||||
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
|
|
||||||
<div id="titlearea">
|
|
||||||
<table cellspacing="0" cellpadding="0">
|
|
||||||
<tbody>
|
|
||||||
<tr style="height: 56px;">
|
|
||||||
<td id="projectalign" style="padding-left: 0.5em;">
|
|
||||||
<div id="projectname">TurboJPEG
|
|
||||||
 <span id="projectnumber">2.1.4</span>
|
|
||||||
</div>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
<!-- end header part -->
|
|
||||||
<!-- Generated by Doxygen 1.8.20 -->
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
var searchBox = new SearchBox("searchBox", "search",false,'Search');
|
|
||||||
/* @license-end */
|
|
||||||
</script>
|
|
||||||
<script type="text/javascript" src="menudata.js"></script>
|
|
||||||
<script type="text/javascript" src="menu.js"></script>
|
|
||||||
<script type="text/javascript">
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
$(function() {
|
|
||||||
initMenu('',true,false,'search.php','Search');
|
|
||||||
$(document).ready(function() { init_search(); });
|
|
||||||
});
|
|
||||||
/* @license-end */</script>
|
|
||||||
<div id="main-nav"></div>
|
|
||||||
</div><!-- top -->
|
|
||||||
<!-- window showing the filter options -->
|
|
||||||
<div id="MSearchSelectWindow"
|
|
||||||
onmouseover="return searchBox.OnSearchSelectShow()"
|
|
||||||
onmouseout="return searchBox.OnSearchSelectHide()"
|
|
||||||
onkeydown="return searchBox.OnSearchSelectKey(event)">
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- iframe showing the search results (closed by default) -->
|
|
||||||
<div id="MSearchResultsWindow">
|
|
||||||
<iframe src="javascript:void(0)" frameborder="0"
|
|
||||||
name="MSearchResults" id="MSearchResults">
|
|
||||||
</iframe>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div class="header">
|
|
||||||
<div class="headertitle">
|
|
||||||
<div class="title">Modules</div> </div>
|
|
||||||
</div><!--header-->
|
|
||||||
<div class="contents">
|
|
||||||
<div class="textblock">Here is a list of all modules:</div><div class="directory">
|
|
||||||
<table class="directory">
|
|
||||||
<tr id="row_0_" class="even"><td class="entry"><span style="width:16px;display:inline-block;"> </span><a class="el" href="group___turbo_j_p_e_g.html" target="_self">TurboJPEG</a></td><td class="desc">TurboJPEG API </td></tr>
|
|
||||||
</table>
|
|
||||||
</div><!-- directory -->
|
|
||||||
</div><!-- contents -->
|
|
||||||
<!-- start footer part -->
|
|
||||||
<hr class="footer"/><address class="footer"><small>
|
|
||||||
Generated by <a href="http://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.8.20
|
|
||||||
</small></address>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
BIN
android/extern/libjpeg-turbo/doc/html/nav_f.png
vendored
|
Before Width: | Height: | Size: 153 B |
BIN
android/extern/libjpeg-turbo/doc/html/nav_g.png
vendored
|
Before Width: | Height: | Size: 95 B |
BIN
android/extern/libjpeg-turbo/doc/html/nav_h.png
vendored
|
Before Width: | Height: | Size: 98 B |
BIN
android/extern/libjpeg-turbo/doc/html/open.png
vendored
|
Before Width: | Height: | Size: 123 B |
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['customfilter_0',['customFilter',['../structtjtransform.html#afd7fc262df33f741e120ef4183202ef5',1,'tjtransform']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_1.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['data_1',['data',['../structtjtransform.html#a688fe8f1a8ecc12a538d9e561cf338e3',1,'tjtransform']]],
|
|
||||||
['denom_2',['denom',['../structtjscalingfactor.html#aefbcdf3e9e62274b2d312c695f133ce3',1,'tjscalingfactor']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_2.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['h_3',['h',['../structtjregion.html#aecefc45a26f4d8b60dd4d825c1710115',1,'tjregion']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_3.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['num_4',['num',['../structtjscalingfactor.html#a9b011e57f981ee23083e2c1aa5e640ec',1,'tjscalingfactor']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_4.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['op_5',['op',['../structtjtransform.html#a2525aab4ba6978a1c273f74fef50e498',1,'tjtransform']]],
|
|
||||||
['options_6',['options',['../structtjtransform.html#ac0e74655baa4402209a21e1ae481c8f6',1,'tjtransform']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_5.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['r_7',['r',['../structtjtransform.html#ac324e5e442abec8a961e5bf219db12cf',1,'tjtransform']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_6.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,103 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tj_5fnumcs_8',['TJ_NUMCS',['../group___turbo_j_p_e_g.html#ga39f57a6fb02d9cf32e7b6890099b5a71',1,'turbojpeg.h']]],
|
|
||||||
['tj_5fnumerr_9',['TJ_NUMERR',['../group___turbo_j_p_e_g.html#ga79bde1b4a3e2351e00887e47781b966e',1,'turbojpeg.h']]],
|
|
||||||
['tj_5fnumpf_10',['TJ_NUMPF',['../group___turbo_j_p_e_g.html#ga7010a4402f54a45ba822ad8675a4655e',1,'turbojpeg.h']]],
|
|
||||||
['tj_5fnumsamp_11',['TJ_NUMSAMP',['../group___turbo_j_p_e_g.html#ga5ef3d169162ce77ce348e292a0b7477c',1,'turbojpeg.h']]],
|
|
||||||
['tj_5fnumxop_12',['TJ_NUMXOP',['../group___turbo_j_p_e_g.html#ga0f6dbd18adf38b7d46ac547f0f4d562c',1,'turbojpeg.h']]],
|
|
||||||
['tjalloc_13',['tjAlloc',['../group___turbo_j_p_e_g.html#gaec627dd4c5f30b7a775a7aea3bec5d83',1,'turbojpeg.h']]],
|
|
||||||
['tjalphaoffset_14',['tjAlphaOffset',['../group___turbo_j_p_e_g.html#ga5af0ab065feefd526debf1e20c43e837',1,'turbojpeg.h']]],
|
|
||||||
['tjblueoffset_15',['tjBlueOffset',['../group___turbo_j_p_e_g.html#ga84e2e35d3f08025f976ec1ec53693dea',1,'turbojpeg.h']]],
|
|
||||||
['tjbufsize_16',['tjBufSize',['../group___turbo_j_p_e_g.html#ga67ac12fee79073242cb216e07c9f1f90',1,'turbojpeg.h']]],
|
|
||||||
['tjbufsizeyuv2_17',['tjBufSizeYUV2',['../group___turbo_j_p_e_g.html#ga5e5aac9e8bcf17049279301e2466474c',1,'turbojpeg.h']]],
|
|
||||||
['tjcompress2_18',['tjCompress2',['../group___turbo_j_p_e_g.html#gafbdce0112fd78fd38efae841443a9bcf',1,'turbojpeg.h']]],
|
|
||||||
['tjcompressfromyuv_19',['tjCompressFromYUV',['../group___turbo_j_p_e_g.html#gab40f5096a72fd7e5bda9d6b58fa37e2e',1,'turbojpeg.h']]],
|
|
||||||
['tjcompressfromyuvplanes_20',['tjCompressFromYUVPlanes',['../group___turbo_j_p_e_g.html#ga29ec5dfbd2d84b8724e951d6fa0d5d9e',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_21',['TJCS',['../group___turbo_j_p_e_g.html#ga4f83ad3368e0e29d1957be0efa7c3720',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fcmyk_22',['TJCS_CMYK',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a6c8b636152ac8195b869587db315ee53',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fgray_23',['TJCS_GRAY',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720ab3e7d6a87f695e45b81c1b5262b5a50a',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5frgb_24',['TJCS_RGB',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a677cb7ccb85c4038ac41964a2e09e555',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fycbcr_25',['TJCS_YCbCr',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a7389b8f65bb387ffedce3efd0d78ec75',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fycck_26',['TJCS_YCCK',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a53839e0fe867b76b58d16b0a1a7c598e',1,'turbojpeg.h']]],
|
|
||||||
['tjdecodeyuv_27',['tjDecodeYUV',['../group___turbo_j_p_e_g.html#ga97c2cedc1e2bade15a84164c94e503c1',1,'turbojpeg.h']]],
|
|
||||||
['tjdecodeyuvplanes_28',['tjDecodeYUVPlanes',['../group___turbo_j_p_e_g.html#ga10e837c07fa9d25770565b237d3898d9',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompress2_29',['tjDecompress2',['../group___turbo_j_p_e_g.html#gae9eccef8b682a48f43a9117c231ed013',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompressheader3_30',['tjDecompressHeader3',['../group___turbo_j_p_e_g.html#ga0595681096bba7199cc6f3533cb25f77',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompresstoyuv2_31',['tjDecompressToYUV2',['../group___turbo_j_p_e_g.html#ga5a3093e325598c17a9f004323af6fafa',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompresstoyuvplanes_32',['tjDecompressToYUVPlanes',['../group___turbo_j_p_e_g.html#gaa59f901a5258ada5bd0185ad59368540',1,'turbojpeg.h']]],
|
|
||||||
['tjdestroy_33',['tjDestroy',['../group___turbo_j_p_e_g.html#ga75f355fa27225ba1a4ee392c852394d2',1,'turbojpeg.h']]],
|
|
||||||
['tjencodeyuv3_34',['tjEncodeYUV3',['../group___turbo_j_p_e_g.html#ga5d619e0a02b71e05a8dffb764f6d7a64',1,'turbojpeg.h']]],
|
|
||||||
['tjencodeyuvplanes_35',['tjEncodeYUVPlanes',['../group___turbo_j_p_e_g.html#gae2d04c72457fe7f4d60cf78ab1b1feb1',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_36',['TJERR',['../group___turbo_j_p_e_g.html#gafbc17cfa57d0d5d11fea35ac025950fe',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_5ffatal_37',['TJERR_FATAL',['../group___turbo_j_p_e_g.html#ggafbc17cfa57d0d5d11fea35ac025950feafc9cceeada13122b09e4851e3788039a',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_5fwarning_38',['TJERR_WARNING',['../group___turbo_j_p_e_g.html#ggafbc17cfa57d0d5d11fea35ac025950fea342dd6e2aedb47bb257b4e7568329b59',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5faccuratedct_39',['TJFLAG_ACCURATEDCT',['../group___turbo_j_p_e_g.html#gacb233cfd722d66d1ccbf48a7de81f0e0',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5fbottomup_40',['TJFLAG_BOTTOMUP',['../group___turbo_j_p_e_g.html#ga72ecf4ebe6eb702d3c6f5ca27455e1ec',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5ffastdct_41',['TJFLAG_FASTDCT',['../group___turbo_j_p_e_g.html#gaabce235db80d3f698b27f36cbd453da2',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5ffastupsample_42',['TJFLAG_FASTUPSAMPLE',['../group___turbo_j_p_e_g.html#ga4ee4506c81177a06f77e2504a22efd2d',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5flimitscans_43',['TJFLAG_LIMITSCANS',['../group___turbo_j_p_e_g.html#ga163e6482dc5096831feef9c79ff3f805',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5fnorealloc_44',['TJFLAG_NOREALLOC',['../group___turbo_j_p_e_g.html#ga8808d403c68b62aaa58a4c1e58e98963',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5fprogressive_45',['TJFLAG_PROGRESSIVE',['../group___turbo_j_p_e_g.html#ga43b426750b46190a25d34a67ef76df1b',1,'turbojpeg.h']]],
|
|
||||||
['tjflag_5fstoponwarning_46',['TJFLAG_STOPONWARNING',['../group___turbo_j_p_e_g.html#ga519cfa4ef6c18d9e5b455fdf59306a3a',1,'turbojpeg.h']]],
|
|
||||||
['tjfree_47',['tjFree',['../group___turbo_j_p_e_g.html#gaea863d2da0cdb609563aabdf9196514b',1,'turbojpeg.h']]],
|
|
||||||
['tjgeterrorcode_48',['tjGetErrorCode',['../group___turbo_j_p_e_g.html#ga414feeffbf860ebd31c745df203de410',1,'turbojpeg.h']]],
|
|
||||||
['tjgeterrorstr2_49',['tjGetErrorStr2',['../group___turbo_j_p_e_g.html#ga1ead8574f9f39fbafc6b497124e7aafa',1,'turbojpeg.h']]],
|
|
||||||
['tjgetscalingfactors_50',['tjGetScalingFactors',['../group___turbo_j_p_e_g.html#ga193d0977b3b9966d53a6c402e90899b1',1,'turbojpeg.h']]],
|
|
||||||
['tjgreenoffset_51',['tjGreenOffset',['../group___turbo_j_p_e_g.html#ga82d6e35da441112a411da41923c0ba2f',1,'turbojpeg.h']]],
|
|
||||||
['tjhandle_52',['tjhandle',['../group___turbo_j_p_e_g.html#ga758d2634ecb4949de7815cba621f5763',1,'turbojpeg.h']]],
|
|
||||||
['tjinitcompress_53',['tjInitCompress',['../group___turbo_j_p_e_g.html#ga9d63a05fc6d813f4aae06107041a37e8',1,'turbojpeg.h']]],
|
|
||||||
['tjinitdecompress_54',['tjInitDecompress',['../group___turbo_j_p_e_g.html#ga52300eac3f3d9ef4bab303bc244f62d3',1,'turbojpeg.h']]],
|
|
||||||
['tjinittransform_55',['tjInitTransform',['../group___turbo_j_p_e_g.html#ga928beff6ac248ceadf01089fc6b41957',1,'turbojpeg.h']]],
|
|
||||||
['tjloadimage_56',['tjLoadImage',['../group___turbo_j_p_e_g.html#gaffbd83c375e79f5db4b5c5d8ad4466e7',1,'turbojpeg.h']]],
|
|
||||||
['tjmcuheight_57',['tjMCUHeight',['../group___turbo_j_p_e_g.html#gabd247bb9fecb393eca57366feb8327bf',1,'turbojpeg.h']]],
|
|
||||||
['tjmcuwidth_58',['tjMCUWidth',['../group___turbo_j_p_e_g.html#ga9e61e7cd47a15a173283ba94e781308c',1,'turbojpeg.h']]],
|
|
||||||
['tjpad_59',['TJPAD',['../group___turbo_j_p_e_g.html#ga0aba955473315e405295d978f0c16511',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_60',['TJPF',['../group___turbo_j_p_e_g.html#gac916144e26c3817ac514e64ae5d12e2a',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fabgr_61',['TJPF_ABGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa1ba1a7f1631dbeaa49a0a85fc4a40081',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fargb_62',['TJPF_ARGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aae8f846ed9d9de99b6e1dfe448848765c',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgr_63',['TJPF_BGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aab10624437fb8ef495a0b153e65749839',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgra_64',['TJPF_BGRA',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aac037ff1845cf9b74bb81a3659c2b9fb4',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgrx_65',['TJPF_BGRX',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa2a1fbf569ca79897eae886e3376ca4c8',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fcmyk_66',['TJPF_CMYK',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa7f5100ec44c91994e243f1cf55553f8b',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fgray_67',['TJPF_GRAY',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa5431b54b015337705f13118073711a1a',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgb_68',['TJPF_RGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa7ce93230bff449518ce387c17e6ed37c',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgba_69',['TJPF_RGBA',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa88d2e88fab67f6503cf972e14851cc12',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgbx_70',['TJPF_RGBX',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa83973bebb7e2dc6fa8bae89ff3f42e01',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5funknown_71',['TJPF_UNKNOWN',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa84c1a6cead7952998e2fb895844a21ed',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fxbgr_72',['TJPF_XBGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aaf6603b27147de47e212e75dac027b2af',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fxrgb_73',['TJPF_XRGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aadae996905efcfa3b42a0bb3bea7f9d84',1,'turbojpeg.h']]],
|
|
||||||
['tjpixelsize_74',['tjPixelSize',['../group___turbo_j_p_e_g.html#gad77cf8fe5b2bfd3cb3f53098146abb4c',1,'turbojpeg.h']]],
|
|
||||||
['tjplaneheight_75',['tjPlaneHeight',['../group___turbo_j_p_e_g.html#ga1a209696c6a80748f20e134b3c64789f',1,'turbojpeg.h']]],
|
|
||||||
['tjplanesizeyuv_76',['tjPlaneSizeYUV',['../group___turbo_j_p_e_g.html#gab4ab7b24f6e797d79abaaa670373961d',1,'turbojpeg.h']]],
|
|
||||||
['tjplanewidth_77',['tjPlaneWidth',['../group___turbo_j_p_e_g.html#ga63fb66bb1e36c74008c4634360becbb1',1,'turbojpeg.h']]],
|
|
||||||
['tjredoffset_78',['tjRedOffset',['../group___turbo_j_p_e_g.html#gadd9b446742ac8a3923f7992c7988fea8',1,'turbojpeg.h']]],
|
|
||||||
['tjregion_79',['tjregion',['../structtjregion.html',1,'']]],
|
|
||||||
['tjsamp_80',['TJSAMP',['../group___turbo_j_p_e_g.html#ga1d047060ea80bb9820d540bb928e9074',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f411_81',['TJSAMP_411',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a28ec62575e5ea295c3fde3001dc628e2',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f420_82',['TJSAMP_420',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a63085dbf683cfe39e513cdb6343e3737',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f422_83',['TJSAMP_422',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a136130902cc578f11f32429b59368404',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f440_84',['TJSAMP_440',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074accf740e6f3aa6ba20ba922cad13cb974',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f444_85',['TJSAMP_444',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074afb8da4f44197837bdec0a4f593dacae3',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5fgray_86',['TJSAMP_GRAY',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a3f1c9504842ddc7a48d0f690754b6248',1,'turbojpeg.h']]],
|
|
||||||
['tjsaveimage_87',['tjSaveImage',['../group___turbo_j_p_e_g.html#ga6f445b22d8933ae4815b3370a538d879',1,'turbojpeg.h']]],
|
|
||||||
['tjscaled_88',['TJSCALED',['../group___turbo_j_p_e_g.html#ga84878bb65404204743aa18cac02781df',1,'turbojpeg.h']]],
|
|
||||||
['tjscalingfactor_89',['tjscalingfactor',['../structtjscalingfactor.html',1,'']]],
|
|
||||||
['tjtransform_90',['tjtransform',['../structtjtransform.html',1,'tjtransform'],['../group___turbo_j_p_e_g.html#ga9cb8abf4cc91881e04a0329b2270be25',1,'tjTransform(tjhandle handle, const unsigned char *jpegBuf, unsigned long jpegSize, int n, unsigned char **dstBufs, unsigned long *dstSizes, tjtransform *transforms, int flags): turbojpeg.h'],['../group___turbo_j_p_e_g.html#ga504805ec0161f1b505397ca0118bf8fd',1,'tjtransform(): turbojpeg.h']]],
|
|
||||||
['tjxop_91',['TJXOP',['../group___turbo_j_p_e_g.html#ga2de531af4e7e6c4f124908376b354866',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fhflip_92',['TJXOP_HFLIP',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866aa0df69776caa30f0fa28e26332d311ce',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fnone_93',['TJXOP_NONE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866aad88c0366cd3f7d0eac9d7a3fa1c2c27',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot180_94',['TJXOP_ROT180',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a140952eb8dd0300accfcc22726d69692',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot270_95',['TJXOP_ROT270',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a3064ee5dfb7f032df332818587567a08',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot90_96',['TJXOP_ROT90',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a43b2bbb23bc4bd548422d43fbe9af128',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5ftranspose_97',['TJXOP_TRANSPOSE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a31060aed199f886afdd417f80499c32d',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5ftransverse_98',['TJXOP_TRANSVERSE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866af3b14d488aea6ece9e5b3df73a74d6a4',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fvflip_99',['TJXOP_VFLIP',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a324eddfbec53b7e691f61e56929d0d5d',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fcopynone_100',['TJXOPT_COPYNONE',['../group___turbo_j_p_e_g.html#ga153b468cfb905d0de61706c838986fe8',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fcrop_101',['TJXOPT_CROP',['../group___turbo_j_p_e_g.html#ga9c771a757fc1294add611906b89ab2d2',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fgray_102',['TJXOPT_GRAY',['../group___turbo_j_p_e_g.html#ga3acee7b48ade1b99e5588736007c2589',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fnooutput_103',['TJXOPT_NOOUTPUT',['../group___turbo_j_p_e_g.html#gafbf992bbf6e006705886333703ffab31',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fperfect_104',['TJXOPT_PERFECT',['../group___turbo_j_p_e_g.html#ga50e03cb5ed115330e212417429600b00',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5fprogressive_105',['TJXOPT_PROGRESSIVE',['../group___turbo_j_p_e_g.html#gad2371c80674584ecc1a7d75e564cf026',1,'turbojpeg.h']]],
|
|
||||||
['tjxopt_5ftrim_106',['TJXOPT_TRIM',['../group___turbo_j_p_e_g.html#ga319826b7eb1583c0595bbe7b95428709',1,'turbojpeg.h']]],
|
|
||||||
['turbojpeg_107',['TurboJPEG',['../group___turbo_j_p_e_g.html',1,'']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_7.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['w_108',['w',['../structtjregion.html#ab6eb73ceef584fc23c8c8097926dce42',1,'tjregion']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_8.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['x_109',['x',['../structtjregion.html#a4b6a37a93997091b26a75831fa291ad9',1,'tjregion']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="all_9.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['y_110',['y',['../structtjregion.html#a7b3e0c24cfe87acc80e334cafdcf22c2',1,'tjregion']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="classes_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,6 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tjregion_111',['tjregion',['../structtjregion.html',1,'']]],
|
|
||||||
['tjscalingfactor_112',['tjscalingfactor',['../structtjscalingfactor.html',1,'']]],
|
|
||||||
['tjtransform_113',['tjtransform',['../structtjtransform.html',1,'']]]
|
|
||||||
];
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
viewBox="0 0 11 11"
|
|
||||||
height="11"
|
|
||||||
width="11"
|
|
||||||
id="svg2"
|
|
||||||
version="1.1">
|
|
||||||
<metadata
|
|
||||||
id="metadata8">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<defs
|
|
||||||
id="defs6" />
|
|
||||||
<path
|
|
||||||
id="path12"
|
|
||||||
d="M 5.5 0.5 A 5 5 0 0 0 0.5 5.5 A 5 5 0 0 0 5.5 10.5 A 5 5 0 0 0 10.5 5.5 A 5 5 0 0 0 5.5 0.5 z M 3.5820312 3 A 0.58291923 0.58291923 0 0 1 4 3.1757812 L 5.5 4.6757812 L 7 3.1757812 A 0.58291923 0.58291923 0 0 1 7.4003906 3 A 0.58291923 0.58291923 0 0 1 7.8242188 4 L 6.3242188 5.5 L 7.8242188 7 A 0.58291923 0.58291923 0 1 1 7 7.8242188 L 5.5 6.3242188 L 4 7.8242188 A 0.58291923 0.58291923 0 1 1 3.1757812 7 L 4.6757812 5.5 L 3.1757812 4 A 0.58291923 0.58291923 0 0 1 3.5820312 3 z "
|
|
||||||
style="stroke-width:1.09870648;fill:#bababa;fill-opacity:1" />
|
|
||||||
</svg>
|
|
||||||
|
Before Width: | Height: | Size: 1.3 KiB |
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="enums_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,8 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tjcs_162',['TJCS',['../group___turbo_j_p_e_g.html#ga4f83ad3368e0e29d1957be0efa7c3720',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_163',['TJERR',['../group___turbo_j_p_e_g.html#gafbc17cfa57d0d5d11fea35ac025950fe',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_164',['TJPF',['../group___turbo_j_p_e_g.html#gac916144e26c3817ac514e64ae5d12e2a',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_165',['TJSAMP',['../group___turbo_j_p_e_g.html#ga1d047060ea80bb9820d540bb928e9074',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_166',['TJXOP',['../group___turbo_j_p_e_g.html#ga2de531af4e7e6c4f124908376b354866',1,'turbojpeg.h']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="enumvalues_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,37 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tjcs_5fcmyk_167',['TJCS_CMYK',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a6c8b636152ac8195b869587db315ee53',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fgray_168',['TJCS_GRAY',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720ab3e7d6a87f695e45b81c1b5262b5a50a',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5frgb_169',['TJCS_RGB',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a677cb7ccb85c4038ac41964a2e09e555',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fycbcr_170',['TJCS_YCbCr',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a7389b8f65bb387ffedce3efd0d78ec75',1,'turbojpeg.h']]],
|
|
||||||
['tjcs_5fycck_171',['TJCS_YCCK',['../group___turbo_j_p_e_g.html#gga4f83ad3368e0e29d1957be0efa7c3720a53839e0fe867b76b58d16b0a1a7c598e',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_5ffatal_172',['TJERR_FATAL',['../group___turbo_j_p_e_g.html#ggafbc17cfa57d0d5d11fea35ac025950feafc9cceeada13122b09e4851e3788039a',1,'turbojpeg.h']]],
|
|
||||||
['tjerr_5fwarning_173',['TJERR_WARNING',['../group___turbo_j_p_e_g.html#ggafbc17cfa57d0d5d11fea35ac025950fea342dd6e2aedb47bb257b4e7568329b59',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fabgr_174',['TJPF_ABGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa1ba1a7f1631dbeaa49a0a85fc4a40081',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fargb_175',['TJPF_ARGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aae8f846ed9d9de99b6e1dfe448848765c',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgr_176',['TJPF_BGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aab10624437fb8ef495a0b153e65749839',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgra_177',['TJPF_BGRA',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aac037ff1845cf9b74bb81a3659c2b9fb4',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fbgrx_178',['TJPF_BGRX',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa2a1fbf569ca79897eae886e3376ca4c8',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fcmyk_179',['TJPF_CMYK',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa7f5100ec44c91994e243f1cf55553f8b',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fgray_180',['TJPF_GRAY',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa5431b54b015337705f13118073711a1a',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgb_181',['TJPF_RGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa7ce93230bff449518ce387c17e6ed37c',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgba_182',['TJPF_RGBA',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa88d2e88fab67f6503cf972e14851cc12',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5frgbx_183',['TJPF_RGBX',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa83973bebb7e2dc6fa8bae89ff3f42e01',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5funknown_184',['TJPF_UNKNOWN',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aa84c1a6cead7952998e2fb895844a21ed',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fxbgr_185',['TJPF_XBGR',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aaf6603b27147de47e212e75dac027b2af',1,'turbojpeg.h']]],
|
|
||||||
['tjpf_5fxrgb_186',['TJPF_XRGB',['../group___turbo_j_p_e_g.html#ggac916144e26c3817ac514e64ae5d12e2aadae996905efcfa3b42a0bb3bea7f9d84',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f411_187',['TJSAMP_411',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a28ec62575e5ea295c3fde3001dc628e2',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f420_188',['TJSAMP_420',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a63085dbf683cfe39e513cdb6343e3737',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f422_189',['TJSAMP_422',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a136130902cc578f11f32429b59368404',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f440_190',['TJSAMP_440',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074accf740e6f3aa6ba20ba922cad13cb974',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5f444_191',['TJSAMP_444',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074afb8da4f44197837bdec0a4f593dacae3',1,'turbojpeg.h']]],
|
|
||||||
['tjsamp_5fgray_192',['TJSAMP_GRAY',['../group___turbo_j_p_e_g.html#gga1d047060ea80bb9820d540bb928e9074a3f1c9504842ddc7a48d0f690754b6248',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fhflip_193',['TJXOP_HFLIP',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866aa0df69776caa30f0fa28e26332d311ce',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fnone_194',['TJXOP_NONE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866aad88c0366cd3f7d0eac9d7a3fa1c2c27',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot180_195',['TJXOP_ROT180',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a140952eb8dd0300accfcc22726d69692',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot270_196',['TJXOP_ROT270',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a3064ee5dfb7f032df332818587567a08',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5frot90_197',['TJXOP_ROT90',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a43b2bbb23bc4bd548422d43fbe9af128',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5ftranspose_198',['TJXOP_TRANSPOSE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a31060aed199f886afdd417f80499c32d',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5ftransverse_199',['TJXOP_TRANSVERSE',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866af3b14d488aea6ece9e5b3df73a74d6a4',1,'turbojpeg.h']]],
|
|
||||||
['tjxop_5fvflip_200',['TJXOP_VFLIP',['../group___turbo_j_p_e_g.html#gga2de531af4e7e6c4f124908376b354866a324eddfbec53b7e691f61e56929d0d5d',1,'turbojpeg.h']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="functions_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,31 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tjalloc_114',['tjAlloc',['../group___turbo_j_p_e_g.html#gaec627dd4c5f30b7a775a7aea3bec5d83',1,'turbojpeg.h']]],
|
|
||||||
['tjbufsize_115',['tjBufSize',['../group___turbo_j_p_e_g.html#ga67ac12fee79073242cb216e07c9f1f90',1,'turbojpeg.h']]],
|
|
||||||
['tjbufsizeyuv2_116',['tjBufSizeYUV2',['../group___turbo_j_p_e_g.html#ga5e5aac9e8bcf17049279301e2466474c',1,'turbojpeg.h']]],
|
|
||||||
['tjcompress2_117',['tjCompress2',['../group___turbo_j_p_e_g.html#gafbdce0112fd78fd38efae841443a9bcf',1,'turbojpeg.h']]],
|
|
||||||
['tjcompressfromyuv_118',['tjCompressFromYUV',['../group___turbo_j_p_e_g.html#gab40f5096a72fd7e5bda9d6b58fa37e2e',1,'turbojpeg.h']]],
|
|
||||||
['tjcompressfromyuvplanes_119',['tjCompressFromYUVPlanes',['../group___turbo_j_p_e_g.html#ga29ec5dfbd2d84b8724e951d6fa0d5d9e',1,'turbojpeg.h']]],
|
|
||||||
['tjdecodeyuv_120',['tjDecodeYUV',['../group___turbo_j_p_e_g.html#ga97c2cedc1e2bade15a84164c94e503c1',1,'turbojpeg.h']]],
|
|
||||||
['tjdecodeyuvplanes_121',['tjDecodeYUVPlanes',['../group___turbo_j_p_e_g.html#ga10e837c07fa9d25770565b237d3898d9',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompress2_122',['tjDecompress2',['../group___turbo_j_p_e_g.html#gae9eccef8b682a48f43a9117c231ed013',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompressheader3_123',['tjDecompressHeader3',['../group___turbo_j_p_e_g.html#ga0595681096bba7199cc6f3533cb25f77',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompresstoyuv2_124',['tjDecompressToYUV2',['../group___turbo_j_p_e_g.html#ga5a3093e325598c17a9f004323af6fafa',1,'turbojpeg.h']]],
|
|
||||||
['tjdecompresstoyuvplanes_125',['tjDecompressToYUVPlanes',['../group___turbo_j_p_e_g.html#gaa59f901a5258ada5bd0185ad59368540',1,'turbojpeg.h']]],
|
|
||||||
['tjdestroy_126',['tjDestroy',['../group___turbo_j_p_e_g.html#ga75f355fa27225ba1a4ee392c852394d2',1,'turbojpeg.h']]],
|
|
||||||
['tjencodeyuv3_127',['tjEncodeYUV3',['../group___turbo_j_p_e_g.html#ga5d619e0a02b71e05a8dffb764f6d7a64',1,'turbojpeg.h']]],
|
|
||||||
['tjencodeyuvplanes_128',['tjEncodeYUVPlanes',['../group___turbo_j_p_e_g.html#gae2d04c72457fe7f4d60cf78ab1b1feb1',1,'turbojpeg.h']]],
|
|
||||||
['tjfree_129',['tjFree',['../group___turbo_j_p_e_g.html#gaea863d2da0cdb609563aabdf9196514b',1,'turbojpeg.h']]],
|
|
||||||
['tjgeterrorcode_130',['tjGetErrorCode',['../group___turbo_j_p_e_g.html#ga414feeffbf860ebd31c745df203de410',1,'turbojpeg.h']]],
|
|
||||||
['tjgeterrorstr2_131',['tjGetErrorStr2',['../group___turbo_j_p_e_g.html#ga1ead8574f9f39fbafc6b497124e7aafa',1,'turbojpeg.h']]],
|
|
||||||
['tjgetscalingfactors_132',['tjGetScalingFactors',['../group___turbo_j_p_e_g.html#ga193d0977b3b9966d53a6c402e90899b1',1,'turbojpeg.h']]],
|
|
||||||
['tjinitcompress_133',['tjInitCompress',['../group___turbo_j_p_e_g.html#ga9d63a05fc6d813f4aae06107041a37e8',1,'turbojpeg.h']]],
|
|
||||||
['tjinitdecompress_134',['tjInitDecompress',['../group___turbo_j_p_e_g.html#ga52300eac3f3d9ef4bab303bc244f62d3',1,'turbojpeg.h']]],
|
|
||||||
['tjinittransform_135',['tjInitTransform',['../group___turbo_j_p_e_g.html#ga928beff6ac248ceadf01089fc6b41957',1,'turbojpeg.h']]],
|
|
||||||
['tjloadimage_136',['tjLoadImage',['../group___turbo_j_p_e_g.html#gaffbd83c375e79f5db4b5c5d8ad4466e7',1,'turbojpeg.h']]],
|
|
||||||
['tjplaneheight_137',['tjPlaneHeight',['../group___turbo_j_p_e_g.html#ga1a209696c6a80748f20e134b3c64789f',1,'turbojpeg.h']]],
|
|
||||||
['tjplanesizeyuv_138',['tjPlaneSizeYUV',['../group___turbo_j_p_e_g.html#gab4ab7b24f6e797d79abaaa670373961d',1,'turbojpeg.h']]],
|
|
||||||
['tjplanewidth_139',['tjPlaneWidth',['../group___turbo_j_p_e_g.html#ga63fb66bb1e36c74008c4634360becbb1',1,'turbojpeg.h']]],
|
|
||||||
['tjsaveimage_140',['tjSaveImage',['../group___turbo_j_p_e_g.html#ga6f445b22d8933ae4815b3370a538d879',1,'turbojpeg.h']]],
|
|
||||||
['tjtransform_141',['tjTransform',['../group___turbo_j_p_e_g.html#ga9cb8abf4cc91881e04a0329b2270be25',1,'turbojpeg.h']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="groups_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['turbojpeg_201',['TurboJPEG',['../group___turbo_j_p_e_g.html',1,'']]]
|
|
||||||
];
|
|
||||||
@@ -1,74 +0,0 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
|
||||||
<!-- Created with Inkscape (http://www.inkscape.org/) -->
|
|
||||||
|
|
||||||
<svg
|
|
||||||
xmlns:dc="http://purl.org/dc/elements/1.1/"
|
|
||||||
xmlns:cc="http://creativecommons.org/ns#"
|
|
||||||
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
|
|
||||||
xmlns:svg="http://www.w3.org/2000/svg"
|
|
||||||
xmlns="http://www.w3.org/2000/svg"
|
|
||||||
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
|
|
||||||
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
|
|
||||||
version="1.1"
|
|
||||||
id="svg2"
|
|
||||||
width="20"
|
|
||||||
height="19"
|
|
||||||
viewBox="0 0 20 19"
|
|
||||||
sodipodi:docname="mag_sel.svg"
|
|
||||||
inkscape:version="0.92.5 (2060ec1f9f, 2020-04-08)">
|
|
||||||
<metadata
|
|
||||||
id="metadata8">
|
|
||||||
<rdf:RDF>
|
|
||||||
<cc:Work
|
|
||||||
rdf:about="">
|
|
||||||
<dc:format>image/svg+xml</dc:format>
|
|
||||||
<dc:type
|
|
||||||
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
|
|
||||||
<dc:title></dc:title>
|
|
||||||
</cc:Work>
|
|
||||||
</rdf:RDF>
|
|
||||||
</metadata>
|
|
||||||
<defs
|
|
||||||
id="defs6" />
|
|
||||||
<sodipodi:namedview
|
|
||||||
pagecolor="#ffffff"
|
|
||||||
bordercolor="#666666"
|
|
||||||
borderopacity="1"
|
|
||||||
objecttolerance="10"
|
|
||||||
gridtolerance="10"
|
|
||||||
guidetolerance="10"
|
|
||||||
inkscape:pageopacity="0"
|
|
||||||
inkscape:pageshadow="2"
|
|
||||||
inkscape:window-width="1920"
|
|
||||||
inkscape:window-height="2096"
|
|
||||||
id="namedview4"
|
|
||||||
showgrid="false"
|
|
||||||
fit-margin-top="0"
|
|
||||||
fit-margin-left="0"
|
|
||||||
fit-margin-right="0"
|
|
||||||
fit-margin-bottom="0"
|
|
||||||
inkscape:zoom="32"
|
|
||||||
inkscape:cx="5.9792688"
|
|
||||||
inkscape:cy="1.1436277"
|
|
||||||
inkscape:window-x="1920"
|
|
||||||
inkscape:window-y="27"
|
|
||||||
inkscape:window-maximized="0"
|
|
||||||
inkscape:current-layer="svg2" />
|
|
||||||
<circle
|
|
||||||
style="fill:#000000;fill-opacity:0;stroke:#656565;stroke-width:1.4;stroke-opacity:1;stroke-miterlimit:4;stroke-dasharray:none"
|
|
||||||
id="path4611"
|
|
||||||
cx="5.5"
|
|
||||||
cy="8.5"
|
|
||||||
r="3.5" />
|
|
||||||
<path
|
|
||||||
style="fill:#656565;fill-opacity:1;stroke:none;stroke-width:1px;stroke-linecap:butt;stroke-linejoin:miter;stroke-opacity:1"
|
|
||||||
d="M 11,7 13.5,10 16,7 Z"
|
|
||||||
id="path4609"
|
|
||||||
inkscape:connector-curvature="0"
|
|
||||||
sodipodi:nodetypes="cccc" />
|
|
||||||
<path
|
|
||||||
style="fill:none;stroke:#656565;stroke-width:1.4;stroke-linecap:round;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
|
|
||||||
d="m 8.1085854,11.109059 2.7823556,2.782356"
|
|
||||||
id="path4630"
|
|
||||||
inkscape:connector-curvature="0" />
|
|
||||||
</svg>
|
|
||||||
|
Before Width: | Height: | Size: 2.3 KiB |
@@ -1,12 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,255 +0,0 @@
|
|||||||
/*---------------- Search Box */
|
|
||||||
|
|
||||||
#MSearchBox {
|
|
||||||
white-space : nowrap;
|
|
||||||
background: white;
|
|
||||||
border-radius: 0.65em;
|
|
||||||
box-shadow: inset 0.5px 0.5px 3px 0px #555;
|
|
||||||
z-index: 102;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchBox .left {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle;
|
|
||||||
height: 1.4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchSelect {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle;
|
|
||||||
height: 1.4em;
|
|
||||||
padding: 0 0 0 0.3em;
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchField {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle;
|
|
||||||
width: 7.5em;
|
|
||||||
height: 1.1em;
|
|
||||||
margin: 0 0.15em;
|
|
||||||
padding: 0;
|
|
||||||
line-height: 1em;
|
|
||||||
border:none;
|
|
||||||
color: #909090;
|
|
||||||
outline: none;
|
|
||||||
font-family: Arial, Verdana, sans-serif;
|
|
||||||
-webkit-border-radius: 0px;
|
|
||||||
border-radius: 0px;
|
|
||||||
background: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
#MSearchBox .right {
|
|
||||||
display: inline-block;
|
|
||||||
vertical-align: middle;
|
|
||||||
width: 1.4em;
|
|
||||||
height: 1.4em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchClose {
|
|
||||||
display: none;
|
|
||||||
font-size: inherit;
|
|
||||||
background : none;
|
|
||||||
border: none;
|
|
||||||
margin: 0;
|
|
||||||
padding: 0;
|
|
||||||
outline: none;
|
|
||||||
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchCloseImg {
|
|
||||||
height: 1.4em;
|
|
||||||
padding: 0.3em;
|
|
||||||
margin: 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
.MSearchBoxActive #MSearchField {
|
|
||||||
color: #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
#main-menu > li:last-child {
|
|
||||||
/* This <li> object is the parent of the search bar */
|
|
||||||
display: flex;
|
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
|
||||||
height: 36px;
|
|
||||||
margin-right: 1em;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*---------------- Search filter selection */
|
|
||||||
|
|
||||||
#MSearchSelectWindow {
|
|
||||||
display: none;
|
|
||||||
position: absolute;
|
|
||||||
left: 0; top: 0;
|
|
||||||
border: 1px solid #90A5CE;
|
|
||||||
background-color: #F9FAFC;
|
|
||||||
z-index: 10001;
|
|
||||||
padding-top: 4px;
|
|
||||||
padding-bottom: 4px;
|
|
||||||
-moz-border-radius: 4px;
|
|
||||||
-webkit-border-top-left-radius: 4px;
|
|
||||||
-webkit-border-top-right-radius: 4px;
|
|
||||||
-webkit-border-bottom-left-radius: 4px;
|
|
||||||
-webkit-border-bottom-right-radius: 4px;
|
|
||||||
-webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15);
|
|
||||||
}
|
|
||||||
|
|
||||||
.SelectItem {
|
|
||||||
font: 8pt Arial, Verdana, sans-serif;
|
|
||||||
padding-left: 2px;
|
|
||||||
padding-right: 12px;
|
|
||||||
border: 0px;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.SelectionMark {
|
|
||||||
margin-right: 4px;
|
|
||||||
font-family: monospace;
|
|
||||||
outline-style: none;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.SelectItem {
|
|
||||||
display: block;
|
|
||||||
outline-style: none;
|
|
||||||
color: #000000;
|
|
||||||
text-decoration: none;
|
|
||||||
padding-left: 6px;
|
|
||||||
padding-right: 12px;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.SelectItem:focus,
|
|
||||||
a.SelectItem:active {
|
|
||||||
color: #000000;
|
|
||||||
outline-style: none;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.SelectItem:hover {
|
|
||||||
color: #FFFFFF;
|
|
||||||
background-color: #3D578C;
|
|
||||||
outline-style: none;
|
|
||||||
text-decoration: none;
|
|
||||||
cursor: pointer;
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*---------------- Search results window */
|
|
||||||
|
|
||||||
iframe#MSearchResults {
|
|
||||||
width: 60ex;
|
|
||||||
height: 15em;
|
|
||||||
}
|
|
||||||
|
|
||||||
#MSearchResultsWindow {
|
|
||||||
display: none;
|
|
||||||
position: absolute;
|
|
||||||
left: 0; top: 0;
|
|
||||||
border: 1px solid #000;
|
|
||||||
background-color: #EEF1F7;
|
|
||||||
z-index:10000;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* ----------------------------------- */
|
|
||||||
|
|
||||||
|
|
||||||
#SRIndex {
|
|
||||||
clear:both;
|
|
||||||
padding-bottom: 15px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SREntry {
|
|
||||||
font-size: 10pt;
|
|
||||||
padding-left: 1ex;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRPage .SREntry {
|
|
||||||
font-size: 8pt;
|
|
||||||
padding: 1px 5px;
|
|
||||||
}
|
|
||||||
|
|
||||||
body.SRPage {
|
|
||||||
margin: 5px 2px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRChildren {
|
|
||||||
padding-left: 3ex; padding-bottom: .5em
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRPage .SRChildren {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRSymbol {
|
|
||||||
font-weight: bold;
|
|
||||||
color: #425E97;
|
|
||||||
font-family: Arial, Verdana, sans-serif;
|
|
||||||
text-decoration: none;
|
|
||||||
outline: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.SRScope {
|
|
||||||
display: block;
|
|
||||||
color: #425E97;
|
|
||||||
font-family: Arial, Verdana, sans-serif;
|
|
||||||
text-decoration: none;
|
|
||||||
outline: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
a.SRSymbol:focus, a.SRSymbol:active,
|
|
||||||
a.SRScope:focus, a.SRScope:active {
|
|
||||||
text-decoration: underline;
|
|
||||||
}
|
|
||||||
|
|
||||||
span.SRScope {
|
|
||||||
padding-left: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRPage .SRStatus {
|
|
||||||
padding: 2px 5px;
|
|
||||||
font-size: 8pt;
|
|
||||||
font-style: italic;
|
|
||||||
}
|
|
||||||
|
|
||||||
.SRResult {
|
|
||||||
display: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
DIV.searchresults {
|
|
||||||
margin-left: 10px;
|
|
||||||
margin-right: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
/*---------------- External search page results */
|
|
||||||
|
|
||||||
.searchresult {
|
|
||||||
background-color: #F0F3F8;
|
|
||||||
}
|
|
||||||
|
|
||||||
.pages b {
|
|
||||||
color: white;
|
|
||||||
padding: 5px 5px 3px 5px;
|
|
||||||
background-image: url("../tab_a.png");
|
|
||||||
background-repeat: repeat-x;
|
|
||||||
text-shadow: 0 1px 1px #000000;
|
|
||||||
}
|
|
||||||
|
|
||||||
.pages {
|
|
||||||
line-height: 17px;
|
|
||||||
margin-left: 4px;
|
|
||||||
text-decoration: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
.hl {
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
#searchresults {
|
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.searchpages {
|
|
||||||
margin-top: 10px;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -1,814 +0,0 @@
|
|||||||
/*
|
|
||||||
@licstart The following is the entire license notice for the JavaScript code in this file.
|
|
||||||
|
|
||||||
The MIT License (MIT)
|
|
||||||
|
|
||||||
Copyright (C) 1997-2020 by Dimitri van Heesch
|
|
||||||
|
|
||||||
Permission is hereby granted, free of charge, to any person obtaining a copy of this software
|
|
||||||
and associated documentation files (the "Software"), to deal in the Software without restriction,
|
|
||||||
including without limitation the rights to use, copy, modify, merge, publish, distribute,
|
|
||||||
sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is
|
|
||||||
furnished to do so, subject to the following conditions:
|
|
||||||
|
|
||||||
The above copyright notice and this permission notice shall be included in all copies or
|
|
||||||
substantial portions of the Software.
|
|
||||||
|
|
||||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING
|
|
||||||
BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
|
|
||||||
NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,
|
|
||||||
DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
||||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
|
||||||
|
|
||||||
@licend The above is the entire license notice for the JavaScript code in this file
|
|
||||||
*/
|
|
||||||
function convertToId(search)
|
|
||||||
{
|
|
||||||
var result = '';
|
|
||||||
for (i=0;i<search.length;i++)
|
|
||||||
{
|
|
||||||
var c = search.charAt(i);
|
|
||||||
var cn = c.charCodeAt(0);
|
|
||||||
if (c.match(/[a-z0-9\u0080-\uFFFF]/))
|
|
||||||
{
|
|
||||||
result+=c;
|
|
||||||
}
|
|
||||||
else if (cn<16)
|
|
||||||
{
|
|
||||||
result+="_0"+cn.toString(16);
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
result+="_"+cn.toString(16);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return result;
|
|
||||||
}
|
|
||||||
|
|
||||||
function getXPos(item)
|
|
||||||
{
|
|
||||||
var x = 0;
|
|
||||||
if (item.offsetWidth)
|
|
||||||
{
|
|
||||||
while (item && item!=document.body)
|
|
||||||
{
|
|
||||||
x += item.offsetLeft;
|
|
||||||
item = item.offsetParent;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return x;
|
|
||||||
}
|
|
||||||
|
|
||||||
function getYPos(item)
|
|
||||||
{
|
|
||||||
var y = 0;
|
|
||||||
if (item.offsetWidth)
|
|
||||||
{
|
|
||||||
while (item && item!=document.body)
|
|
||||||
{
|
|
||||||
y += item.offsetTop;
|
|
||||||
item = item.offsetParent;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return y;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* A class handling everything associated with the search panel.
|
|
||||||
|
|
||||||
Parameters:
|
|
||||||
name - The name of the global variable that will be
|
|
||||||
storing this instance. Is needed to be able to set timeouts.
|
|
||||||
resultPath - path to use for external files
|
|
||||||
*/
|
|
||||||
function SearchBox(name, resultsPath, inFrame, label)
|
|
||||||
{
|
|
||||||
if (!name || !resultsPath) { alert("Missing parameters to SearchBox."); }
|
|
||||||
|
|
||||||
// ---------- Instance variables
|
|
||||||
this.name = name;
|
|
||||||
this.resultsPath = resultsPath;
|
|
||||||
this.keyTimeout = 0;
|
|
||||||
this.keyTimeoutLength = 500;
|
|
||||||
this.closeSelectionTimeout = 300;
|
|
||||||
this.lastSearchValue = "";
|
|
||||||
this.lastResultsPage = "";
|
|
||||||
this.hideTimeout = 0;
|
|
||||||
this.searchIndex = 0;
|
|
||||||
this.searchActive = false;
|
|
||||||
this.insideFrame = inFrame;
|
|
||||||
this.searchLabel = label;
|
|
||||||
|
|
||||||
// ----------- DOM Elements
|
|
||||||
|
|
||||||
this.DOMSearchField = function()
|
|
||||||
{ return document.getElementById("MSearchField"); }
|
|
||||||
|
|
||||||
this.DOMSearchSelect = function()
|
|
||||||
{ return document.getElementById("MSearchSelect"); }
|
|
||||||
|
|
||||||
this.DOMSearchSelectWindow = function()
|
|
||||||
{ return document.getElementById("MSearchSelectWindow"); }
|
|
||||||
|
|
||||||
this.DOMPopupSearchResults = function()
|
|
||||||
{ return document.getElementById("MSearchResults"); }
|
|
||||||
|
|
||||||
this.DOMPopupSearchResultsWindow = function()
|
|
||||||
{ return document.getElementById("MSearchResultsWindow"); }
|
|
||||||
|
|
||||||
this.DOMSearchClose = function()
|
|
||||||
{ return document.getElementById("MSearchClose"); }
|
|
||||||
|
|
||||||
this.DOMSearchBox = function()
|
|
||||||
{ return document.getElementById("MSearchBox"); }
|
|
||||||
|
|
||||||
// ------------ Event Handlers
|
|
||||||
|
|
||||||
// Called when focus is added or removed from the search field.
|
|
||||||
this.OnSearchFieldFocus = function(isActive)
|
|
||||||
{
|
|
||||||
this.Activate(isActive);
|
|
||||||
}
|
|
||||||
|
|
||||||
this.OnSearchSelectShow = function()
|
|
||||||
{
|
|
||||||
var searchSelectWindow = this.DOMSearchSelectWindow();
|
|
||||||
var searchField = this.DOMSearchSelect();
|
|
||||||
|
|
||||||
if (this.insideFrame)
|
|
||||||
{
|
|
||||||
var left = getXPos(searchField);
|
|
||||||
var top = getYPos(searchField);
|
|
||||||
left += searchField.offsetWidth + 6;
|
|
||||||
top += searchField.offsetHeight;
|
|
||||||
|
|
||||||
// show search selection popup
|
|
||||||
searchSelectWindow.style.display='block';
|
|
||||||
left -= searchSelectWindow.offsetWidth;
|
|
||||||
searchSelectWindow.style.left = left + 'px';
|
|
||||||
searchSelectWindow.style.top = top + 'px';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
var left = getXPos(searchField);
|
|
||||||
var top = getYPos(searchField);
|
|
||||||
top += searchField.offsetHeight;
|
|
||||||
|
|
||||||
// show search selection popup
|
|
||||||
searchSelectWindow.style.display='block';
|
|
||||||
searchSelectWindow.style.left = left + 'px';
|
|
||||||
searchSelectWindow.style.top = top + 'px';
|
|
||||||
}
|
|
||||||
|
|
||||||
// stop selection hide timer
|
|
||||||
if (this.hideTimeout)
|
|
||||||
{
|
|
||||||
clearTimeout(this.hideTimeout);
|
|
||||||
this.hideTimeout=0;
|
|
||||||
}
|
|
||||||
return false; // to avoid "image drag" default event
|
|
||||||
}
|
|
||||||
|
|
||||||
this.OnSearchSelectHide = function()
|
|
||||||
{
|
|
||||||
this.hideTimeout = setTimeout(this.name +".CloseSelectionWindow()",
|
|
||||||
this.closeSelectionTimeout);
|
|
||||||
}
|
|
||||||
|
|
||||||
// Called when the content of the search field is changed.
|
|
||||||
this.OnSearchFieldChange = function(evt)
|
|
||||||
{
|
|
||||||
if (this.keyTimeout) // kill running timer
|
|
||||||
{
|
|
||||||
clearTimeout(this.keyTimeout);
|
|
||||||
this.keyTimeout = 0;
|
|
||||||
}
|
|
||||||
|
|
||||||
var e = (evt) ? evt : window.event; // for IE
|
|
||||||
if (e.keyCode==40 || e.keyCode==13)
|
|
||||||
{
|
|
||||||
if (e.shiftKey==1)
|
|
||||||
{
|
|
||||||
this.OnSearchSelectShow();
|
|
||||||
var win=this.DOMSearchSelectWindow();
|
|
||||||
for (i=0;i<win.childNodes.length;i++)
|
|
||||||
{
|
|
||||||
var child = win.childNodes[i]; // get span within a
|
|
||||||
if (child.className=='SelectItem')
|
|
||||||
{
|
|
||||||
child.focus();
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
window.frames.MSearchResults.postMessage("take_focus", "*");
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (e.keyCode==27) // Escape out of the search field
|
|
||||||
{
|
|
||||||
this.DOMSearchField().blur();
|
|
||||||
this.DOMPopupSearchResultsWindow().style.display = 'none';
|
|
||||||
this.DOMSearchClose().style.display = 'none';
|
|
||||||
this.lastSearchValue = '';
|
|
||||||
this.Activate(false);
|
|
||||||
return;
|
|
||||||
}
|
|
||||||
|
|
||||||
// strip whitespaces
|
|
||||||
var searchValue = this.DOMSearchField().value.replace(/ +/g, "");
|
|
||||||
|
|
||||||
if (searchValue != this.lastSearchValue) // search value has changed
|
|
||||||
{
|
|
||||||
if (searchValue != "") // non-empty search
|
|
||||||
{
|
|
||||||
// set timer for search update
|
|
||||||
this.keyTimeout = setTimeout(this.name + '.Search()',
|
|
||||||
this.keyTimeoutLength);
|
|
||||||
}
|
|
||||||
else // empty search field
|
|
||||||
{
|
|
||||||
this.DOMPopupSearchResultsWindow().style.display = 'none';
|
|
||||||
this.DOMSearchClose().style.display = 'none';
|
|
||||||
this.lastSearchValue = '';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
this.SelectItemCount = function(id)
|
|
||||||
{
|
|
||||||
var count=0;
|
|
||||||
var win=this.DOMSearchSelectWindow();
|
|
||||||
for (i=0;i<win.childNodes.length;i++)
|
|
||||||
{
|
|
||||||
var child = win.childNodes[i]; // get span within a
|
|
||||||
if (child.className=='SelectItem')
|
|
||||||
{
|
|
||||||
count++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
return count;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.SelectItemSet = function(id)
|
|
||||||
{
|
|
||||||
var i,j=0;
|
|
||||||
var win=this.DOMSearchSelectWindow();
|
|
||||||
for (i=0;i<win.childNodes.length;i++)
|
|
||||||
{
|
|
||||||
var child = win.childNodes[i]; // get span within a
|
|
||||||
if (child.className=='SelectItem')
|
|
||||||
{
|
|
||||||
var node = child.firstChild;
|
|
||||||
if (j==id)
|
|
||||||
{
|
|
||||||
node.innerHTML='•';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
node.innerHTML=' ';
|
|
||||||
}
|
|
||||||
j++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Called when an search filter selection is made.
|
|
||||||
// set item with index id as the active item
|
|
||||||
this.OnSelectItem = function(id)
|
|
||||||
{
|
|
||||||
this.searchIndex = id;
|
|
||||||
this.SelectItemSet(id);
|
|
||||||
var searchValue = this.DOMSearchField().value.replace(/ +/g, "");
|
|
||||||
if (searchValue!="" && this.searchActive) // something was found -> do a search
|
|
||||||
{
|
|
||||||
this.Search();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
this.OnSearchSelectKey = function(evt)
|
|
||||||
{
|
|
||||||
var e = (evt) ? evt : window.event; // for IE
|
|
||||||
if (e.keyCode==40 && this.searchIndex<this.SelectItemCount()) // Down
|
|
||||||
{
|
|
||||||
this.searchIndex++;
|
|
||||||
this.OnSelectItem(this.searchIndex);
|
|
||||||
}
|
|
||||||
else if (e.keyCode==38 && this.searchIndex>0) // Up
|
|
||||||
{
|
|
||||||
this.searchIndex--;
|
|
||||||
this.OnSelectItem(this.searchIndex);
|
|
||||||
}
|
|
||||||
else if (e.keyCode==13 || e.keyCode==27)
|
|
||||||
{
|
|
||||||
this.OnSelectItem(this.searchIndex);
|
|
||||||
this.CloseSelectionWindow();
|
|
||||||
this.DOMSearchField().focus();
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
// --------- Actions
|
|
||||||
|
|
||||||
// Closes the results window.
|
|
||||||
this.CloseResultsWindow = function()
|
|
||||||
{
|
|
||||||
this.DOMPopupSearchResultsWindow().style.display = 'none';
|
|
||||||
this.DOMSearchClose().style.display = 'none';
|
|
||||||
this.Activate(false);
|
|
||||||
}
|
|
||||||
|
|
||||||
this.CloseSelectionWindow = function()
|
|
||||||
{
|
|
||||||
this.DOMSearchSelectWindow().style.display = 'none';
|
|
||||||
}
|
|
||||||
|
|
||||||
// Performs a search.
|
|
||||||
this.Search = function()
|
|
||||||
{
|
|
||||||
this.keyTimeout = 0;
|
|
||||||
|
|
||||||
// strip leading whitespace
|
|
||||||
var searchValue = this.DOMSearchField().value.replace(/^ +/, "");
|
|
||||||
|
|
||||||
var code = searchValue.toLowerCase().charCodeAt(0);
|
|
||||||
var idxChar = searchValue.substr(0, 1).toLowerCase();
|
|
||||||
if ( 0xD800 <= code && code <= 0xDBFF && searchValue > 1) // surrogate pair
|
|
||||||
{
|
|
||||||
idxChar = searchValue.substr(0, 2);
|
|
||||||
}
|
|
||||||
|
|
||||||
var resultsPage;
|
|
||||||
var resultsPageWithSearch;
|
|
||||||
var hasResultsPage;
|
|
||||||
|
|
||||||
var idx = indexSectionsWithContent[this.searchIndex].indexOf(idxChar);
|
|
||||||
if (idx!=-1)
|
|
||||||
{
|
|
||||||
var hexCode=idx.toString(16);
|
|
||||||
resultsPage = this.resultsPath + '/' + indexSectionNames[this.searchIndex] + '_' + hexCode + '.html';
|
|
||||||
resultsPageWithSearch = resultsPage+'?'+escape(searchValue);
|
|
||||||
hasResultsPage = true;
|
|
||||||
}
|
|
||||||
else // nothing available for this search term
|
|
||||||
{
|
|
||||||
resultsPage = this.resultsPath + '/nomatches.html';
|
|
||||||
resultsPageWithSearch = resultsPage;
|
|
||||||
hasResultsPage = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
window.frames.MSearchResults.location = resultsPageWithSearch;
|
|
||||||
var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow();
|
|
||||||
|
|
||||||
if (domPopupSearchResultsWindow.style.display!='block')
|
|
||||||
{
|
|
||||||
var domSearchBox = this.DOMSearchBox();
|
|
||||||
this.DOMSearchClose().style.display = 'inline-block';
|
|
||||||
if (this.insideFrame)
|
|
||||||
{
|
|
||||||
var domPopupSearchResults = this.DOMPopupSearchResults();
|
|
||||||
domPopupSearchResultsWindow.style.position = 'relative';
|
|
||||||
domPopupSearchResultsWindow.style.display = 'block';
|
|
||||||
var width = document.body.clientWidth - 8; // the -8 is for IE :-(
|
|
||||||
domPopupSearchResultsWindow.style.width = width + 'px';
|
|
||||||
domPopupSearchResults.style.width = width + 'px';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
var domPopupSearchResults = this.DOMPopupSearchResults();
|
|
||||||
var left = getXPos(domSearchBox) + 150; // domSearchBox.offsetWidth;
|
|
||||||
var top = getYPos(domSearchBox) + 20; // domSearchBox.offsetHeight + 1;
|
|
||||||
domPopupSearchResultsWindow.style.display = 'block';
|
|
||||||
left -= domPopupSearchResults.offsetWidth;
|
|
||||||
domPopupSearchResultsWindow.style.top = top + 'px';
|
|
||||||
domPopupSearchResultsWindow.style.left = left + 'px';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
this.lastSearchValue = searchValue;
|
|
||||||
this.lastResultsPage = resultsPage;
|
|
||||||
}
|
|
||||||
|
|
||||||
// -------- Activation Functions
|
|
||||||
|
|
||||||
// Activates or deactivates the search panel, resetting things to
|
|
||||||
// their default values if necessary.
|
|
||||||
this.Activate = function(isActive)
|
|
||||||
{
|
|
||||||
if (isActive || // open it
|
|
||||||
this.DOMPopupSearchResultsWindow().style.display == 'block'
|
|
||||||
)
|
|
||||||
{
|
|
||||||
this.DOMSearchBox().className = 'MSearchBoxActive';
|
|
||||||
|
|
||||||
var searchField = this.DOMSearchField();
|
|
||||||
|
|
||||||
if (searchField.value == this.searchLabel) // clear "Search" term upon entry
|
|
||||||
{
|
|
||||||
searchField.value = '';
|
|
||||||
this.searchActive = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (!isActive) // directly remove the panel
|
|
||||||
{
|
|
||||||
this.DOMSearchBox().className = 'MSearchBoxInactive';
|
|
||||||
this.DOMSearchField().value = this.searchLabel;
|
|
||||||
this.searchActive = false;
|
|
||||||
this.lastSearchValue = ''
|
|
||||||
this.lastResultsPage = '';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// -----------------------------------------------------------------------
|
|
||||||
|
|
||||||
// The class that handles everything on the search results page.
|
|
||||||
function SearchResults(name)
|
|
||||||
{
|
|
||||||
// The number of matches from the last run of <Search()>.
|
|
||||||
this.lastMatchCount = 0;
|
|
||||||
this.lastKey = 0;
|
|
||||||
this.repeatOn = false;
|
|
||||||
|
|
||||||
// Toggles the visibility of the passed element ID.
|
|
||||||
this.FindChildElement = function(id)
|
|
||||||
{
|
|
||||||
var parentElement = document.getElementById(id);
|
|
||||||
var element = parentElement.firstChild;
|
|
||||||
|
|
||||||
while (element && element!=parentElement)
|
|
||||||
{
|
|
||||||
if (element.nodeName == 'DIV' && element.className == 'SRChildren')
|
|
||||||
{
|
|
||||||
return element;
|
|
||||||
}
|
|
||||||
|
|
||||||
if (element.nodeName == 'DIV' && element.hasChildNodes())
|
|
||||||
{
|
|
||||||
element = element.firstChild;
|
|
||||||
}
|
|
||||||
else if (element.nextSibling)
|
|
||||||
{
|
|
||||||
element = element.nextSibling;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
do
|
|
||||||
{
|
|
||||||
element = element.parentNode;
|
|
||||||
}
|
|
||||||
while (element && element!=parentElement && !element.nextSibling);
|
|
||||||
|
|
||||||
if (element && element!=parentElement)
|
|
||||||
{
|
|
||||||
element = element.nextSibling;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
this.Toggle = function(id)
|
|
||||||
{
|
|
||||||
var element = this.FindChildElement(id);
|
|
||||||
if (element)
|
|
||||||
{
|
|
||||||
if (element.style.display == 'block')
|
|
||||||
{
|
|
||||||
element.style.display = 'none';
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
element.style.display = 'block';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
// Searches for the passed string. If there is no parameter,
|
|
||||||
// it takes it from the URL query.
|
|
||||||
//
|
|
||||||
// Always returns true, since other documents may try to call it
|
|
||||||
// and that may or may not be possible.
|
|
||||||
this.Search = function(search)
|
|
||||||
{
|
|
||||||
if (!search) // get search word from URL
|
|
||||||
{
|
|
||||||
search = window.location.search;
|
|
||||||
search = search.substring(1); // Remove the leading '?'
|
|
||||||
search = unescape(search);
|
|
||||||
}
|
|
||||||
|
|
||||||
search = search.replace(/^ +/, ""); // strip leading spaces
|
|
||||||
search = search.replace(/ +$/, ""); // strip trailing spaces
|
|
||||||
search = search.toLowerCase();
|
|
||||||
search = convertToId(search);
|
|
||||||
|
|
||||||
var resultRows = document.getElementsByTagName("div");
|
|
||||||
var matches = 0;
|
|
||||||
|
|
||||||
var i = 0;
|
|
||||||
while (i < resultRows.length)
|
|
||||||
{
|
|
||||||
var row = resultRows.item(i);
|
|
||||||
if (row.className == "SRResult")
|
|
||||||
{
|
|
||||||
var rowMatchName = row.id.toLowerCase();
|
|
||||||
rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_'
|
|
||||||
|
|
||||||
if (search.length<=rowMatchName.length &&
|
|
||||||
rowMatchName.substr(0, search.length)==search)
|
|
||||||
{
|
|
||||||
row.style.display = 'block';
|
|
||||||
matches++;
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
row.style.display = 'none';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
i++;
|
|
||||||
}
|
|
||||||
document.getElementById("Searching").style.display='none';
|
|
||||||
if (matches == 0) // no results
|
|
||||||
{
|
|
||||||
document.getElementById("NoMatches").style.display='block';
|
|
||||||
}
|
|
||||||
else // at least one result
|
|
||||||
{
|
|
||||||
document.getElementById("NoMatches").style.display='none';
|
|
||||||
}
|
|
||||||
this.lastMatchCount = matches;
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
|
|
||||||
// return the first item with index index or higher that is visible
|
|
||||||
this.NavNext = function(index)
|
|
||||||
{
|
|
||||||
var focusItem;
|
|
||||||
while (1)
|
|
||||||
{
|
|
||||||
var focusName = 'Item'+index;
|
|
||||||
focusItem = document.getElementById(focusName);
|
|
||||||
if (focusItem && focusItem.parentNode.parentNode.style.display=='block')
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
else if (!focusItem) // last element
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
focusItem=null;
|
|
||||||
index++;
|
|
||||||
}
|
|
||||||
return focusItem;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.NavPrev = function(index)
|
|
||||||
{
|
|
||||||
var focusItem;
|
|
||||||
while (1)
|
|
||||||
{
|
|
||||||
var focusName = 'Item'+index;
|
|
||||||
focusItem = document.getElementById(focusName);
|
|
||||||
if (focusItem && focusItem.parentNode.parentNode.style.display=='block')
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
else if (!focusItem) // last element
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
focusItem=null;
|
|
||||||
index--;
|
|
||||||
}
|
|
||||||
return focusItem;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.ProcessKeys = function(e)
|
|
||||||
{
|
|
||||||
if (e.type == "keydown")
|
|
||||||
{
|
|
||||||
this.repeatOn = false;
|
|
||||||
this.lastKey = e.keyCode;
|
|
||||||
}
|
|
||||||
else if (e.type == "keypress")
|
|
||||||
{
|
|
||||||
if (!this.repeatOn)
|
|
||||||
{
|
|
||||||
if (this.lastKey) this.repeatOn = true;
|
|
||||||
return false; // ignore first keypress after keydown
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (e.type == "keyup")
|
|
||||||
{
|
|
||||||
this.lastKey = 0;
|
|
||||||
this.repeatOn = false;
|
|
||||||
}
|
|
||||||
return this.lastKey!=0;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.Nav = function(evt,itemIndex)
|
|
||||||
{
|
|
||||||
var e = (evt) ? evt : window.event; // for IE
|
|
||||||
if (e.keyCode==13) return true;
|
|
||||||
if (!this.ProcessKeys(e)) return false;
|
|
||||||
|
|
||||||
if (this.lastKey==38) // Up
|
|
||||||
{
|
|
||||||
var newIndex = itemIndex-1;
|
|
||||||
var focusItem = this.NavPrev(newIndex);
|
|
||||||
if (focusItem)
|
|
||||||
{
|
|
||||||
var child = this.FindChildElement(focusItem.parentNode.parentNode.id);
|
|
||||||
if (child && child.style.display == 'block') // children visible
|
|
||||||
{
|
|
||||||
var n=0;
|
|
||||||
var tmpElem;
|
|
||||||
while (1) // search for last child
|
|
||||||
{
|
|
||||||
tmpElem = document.getElementById('Item'+newIndex+'_c'+n);
|
|
||||||
if (tmpElem)
|
|
||||||
{
|
|
||||||
focusItem = tmpElem;
|
|
||||||
}
|
|
||||||
else // found it!
|
|
||||||
{
|
|
||||||
break;
|
|
||||||
}
|
|
||||||
n++;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if (focusItem)
|
|
||||||
{
|
|
||||||
focusItem.focus();
|
|
||||||
}
|
|
||||||
else // return focus to search field
|
|
||||||
{
|
|
||||||
parent.document.getElementById("MSearchField").focus();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (this.lastKey==40) // Down
|
|
||||||
{
|
|
||||||
var newIndex = itemIndex+1;
|
|
||||||
var focusItem;
|
|
||||||
var item = document.getElementById('Item'+itemIndex);
|
|
||||||
var elem = this.FindChildElement(item.parentNode.parentNode.id);
|
|
||||||
if (elem && elem.style.display == 'block') // children visible
|
|
||||||
{
|
|
||||||
focusItem = document.getElementById('Item'+itemIndex+'_c0');
|
|
||||||
}
|
|
||||||
if (!focusItem) focusItem = this.NavNext(newIndex);
|
|
||||||
if (focusItem) focusItem.focus();
|
|
||||||
}
|
|
||||||
else if (this.lastKey==39) // Right
|
|
||||||
{
|
|
||||||
var item = document.getElementById('Item'+itemIndex);
|
|
||||||
var elem = this.FindChildElement(item.parentNode.parentNode.id);
|
|
||||||
if (elem) elem.style.display = 'block';
|
|
||||||
}
|
|
||||||
else if (this.lastKey==37) // Left
|
|
||||||
{
|
|
||||||
var item = document.getElementById('Item'+itemIndex);
|
|
||||||
var elem = this.FindChildElement(item.parentNode.parentNode.id);
|
|
||||||
if (elem) elem.style.display = 'none';
|
|
||||||
}
|
|
||||||
else if (this.lastKey==27) // Escape
|
|
||||||
{
|
|
||||||
parent.searchBox.CloseResultsWindow();
|
|
||||||
parent.document.getElementById("MSearchField").focus();
|
|
||||||
}
|
|
||||||
else if (this.lastKey==13) // Enter
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
this.NavChild = function(evt,itemIndex,childIndex)
|
|
||||||
{
|
|
||||||
var e = (evt) ? evt : window.event; // for IE
|
|
||||||
if (e.keyCode==13) return true;
|
|
||||||
if (!this.ProcessKeys(e)) return false;
|
|
||||||
|
|
||||||
if (this.lastKey==38) // Up
|
|
||||||
{
|
|
||||||
if (childIndex>0)
|
|
||||||
{
|
|
||||||
var newIndex = childIndex-1;
|
|
||||||
document.getElementById('Item'+itemIndex+'_c'+newIndex).focus();
|
|
||||||
}
|
|
||||||
else // already at first child, jump to parent
|
|
||||||
{
|
|
||||||
document.getElementById('Item'+itemIndex).focus();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (this.lastKey==40) // Down
|
|
||||||
{
|
|
||||||
var newIndex = childIndex+1;
|
|
||||||
var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex);
|
|
||||||
if (!elem) // last child, jump to parent next parent
|
|
||||||
{
|
|
||||||
elem = this.NavNext(itemIndex+1);
|
|
||||||
}
|
|
||||||
if (elem)
|
|
||||||
{
|
|
||||||
elem.focus();
|
|
||||||
}
|
|
||||||
}
|
|
||||||
else if (this.lastKey==27) // Escape
|
|
||||||
{
|
|
||||||
parent.searchBox.CloseResultsWindow();
|
|
||||||
parent.document.getElementById("MSearchField").focus();
|
|
||||||
}
|
|
||||||
else if (this.lastKey==13) // Enter
|
|
||||||
{
|
|
||||||
return true;
|
|
||||||
}
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function setKeyActions(elem,action)
|
|
||||||
{
|
|
||||||
elem.setAttribute('onkeydown',action);
|
|
||||||
elem.setAttribute('onkeypress',action);
|
|
||||||
elem.setAttribute('onkeyup',action);
|
|
||||||
}
|
|
||||||
|
|
||||||
function setClassAttr(elem,attr)
|
|
||||||
{
|
|
||||||
elem.setAttribute('class',attr);
|
|
||||||
elem.setAttribute('className',attr);
|
|
||||||
}
|
|
||||||
|
|
||||||
function createResults()
|
|
||||||
{
|
|
||||||
var results = document.getElementById("SRResults");
|
|
||||||
for (var e=0; e<searchData.length; e++)
|
|
||||||
{
|
|
||||||
var id = searchData[e][0];
|
|
||||||
var srResult = document.createElement('div');
|
|
||||||
srResult.setAttribute('id','SR_'+id);
|
|
||||||
setClassAttr(srResult,'SRResult');
|
|
||||||
var srEntry = document.createElement('div');
|
|
||||||
setClassAttr(srEntry,'SREntry');
|
|
||||||
var srLink = document.createElement('a');
|
|
||||||
srLink.setAttribute('id','Item'+e);
|
|
||||||
setKeyActions(srLink,'return searchResults.Nav(event,'+e+')');
|
|
||||||
setClassAttr(srLink,'SRSymbol');
|
|
||||||
srLink.innerHTML = searchData[e][1][0];
|
|
||||||
srEntry.appendChild(srLink);
|
|
||||||
if (searchData[e][1].length==2) // single result
|
|
||||||
{
|
|
||||||
srLink.setAttribute('href',searchData[e][1][1][0]);
|
|
||||||
if (searchData[e][1][1][1])
|
|
||||||
{
|
|
||||||
srLink.setAttribute('target','_parent');
|
|
||||||
}
|
|
||||||
var srScope = document.createElement('span');
|
|
||||||
setClassAttr(srScope,'SRScope');
|
|
||||||
srScope.innerHTML = searchData[e][1][1][2];
|
|
||||||
srEntry.appendChild(srScope);
|
|
||||||
}
|
|
||||||
else // multiple results
|
|
||||||
{
|
|
||||||
srLink.setAttribute('href','javascript:searchResults.Toggle("SR_'+id+'")');
|
|
||||||
var srChildren = document.createElement('div');
|
|
||||||
setClassAttr(srChildren,'SRChildren');
|
|
||||||
for (var c=0; c<searchData[e][1].length-1; c++)
|
|
||||||
{
|
|
||||||
var srChild = document.createElement('a');
|
|
||||||
srChild.setAttribute('id','Item'+e+'_c'+c);
|
|
||||||
setKeyActions(srChild,'return searchResults.NavChild(event,'+e+','+c+')');
|
|
||||||
setClassAttr(srChild,'SRScope');
|
|
||||||
srChild.setAttribute('href',searchData[e][1][c+1][0]);
|
|
||||||
if (searchData[e][1][c+1][1])
|
|
||||||
{
|
|
||||||
srChild.setAttribute('target','_parent');
|
|
||||||
}
|
|
||||||
srChild.innerHTML = searchData[e][1][c+1][2];
|
|
||||||
srChildren.appendChild(srChild);
|
|
||||||
}
|
|
||||||
srEntry.appendChild(srChildren);
|
|
||||||
}
|
|
||||||
srResult.appendChild(srEntry);
|
|
||||||
results.appendChild(srResult);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
function init_search()
|
|
||||||
{
|
|
||||||
var results = document.getElementById("MSearchSelectWindow");
|
|
||||||
for (var key in indexSectionLabels)
|
|
||||||
{
|
|
||||||
var link = document.createElement('a');
|
|
||||||
link.setAttribute('class','SelectItem');
|
|
||||||
link.setAttribute('onclick','searchBox.OnSelectItem('+key+')');
|
|
||||||
link.href='javascript:void(0)';
|
|
||||||
link.innerHTML='<span class="SelectionMark"> </span>'+indexSectionLabels[key];
|
|
||||||
results.appendChild(link);
|
|
||||||
}
|
|
||||||
searchBox.OnSelectItem(0);
|
|
||||||
}
|
|
||||||
/* @license-end */
|
|
||||||
|
Before Width: | Height: | Size: 567 B |
|
Before Width: | Height: | Size: 158 B |
|
Before Width: | Height: | Size: 553 B |
@@ -1,36 +0,0 @@
|
|||||||
var indexSectionsWithContent =
|
|
||||||
{
|
|
||||||
0: "cdhnortwxy",
|
|
||||||
1: "t",
|
|
||||||
2: "t",
|
|
||||||
3: "cdhnortwxy",
|
|
||||||
4: "t",
|
|
||||||
5: "t",
|
|
||||||
6: "t",
|
|
||||||
7: "t"
|
|
||||||
};
|
|
||||||
|
|
||||||
var indexSectionNames =
|
|
||||||
{
|
|
||||||
0: "all",
|
|
||||||
1: "classes",
|
|
||||||
2: "functions",
|
|
||||||
3: "variables",
|
|
||||||
4: "typedefs",
|
|
||||||
5: "enums",
|
|
||||||
6: "enumvalues",
|
|
||||||
7: "groups"
|
|
||||||
};
|
|
||||||
|
|
||||||
var indexSectionLabels =
|
|
||||||
{
|
|
||||||
0: "All",
|
|
||||||
1: "Data Structures",
|
|
||||||
2: "Functions",
|
|
||||||
3: "Variables",
|
|
||||||
4: "Typedefs",
|
|
||||||
5: "Enumerations",
|
|
||||||
6: "Enumerator",
|
|
||||||
7: "Modules"
|
|
||||||
};
|
|
||||||
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="typedefs_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['tjhandle_160',['tjhandle',['../group___turbo_j_p_e_g.html#ga758d2634ecb4949de7815cba621f5763',1,'turbojpeg.h']]],
|
|
||||||
['tjtransform_161',['tjtransform',['../group___turbo_j_p_e_g.html#ga504805ec0161f1b505397ca0118bf8fd',1,'turbojpeg.h']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="variables_0.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['customfilter_142',['customFilter',['../structtjtransform.html#afd7fc262df33f741e120ef4183202ef5',1,'tjtransform']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="variables_1.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['data_143',['data',['../structtjtransform.html#a688fe8f1a8ecc12a538d9e561cf338e3',1,'tjtransform']]],
|
|
||||||
['denom_144',['denom',['../structtjscalingfactor.html#aefbcdf3e9e62274b2d312c695f133ce3',1,'tjscalingfactor']]]
|
|
||||||
];
|
|
||||||
@@ -1,36 +0,0 @@
|
|||||||
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|
|
||||||
<html><head><title></title>
|
|
||||||
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
|
|
||||||
<meta name="generator" content="Doxygen 1.8.20"/>
|
|
||||||
<link rel="stylesheet" type="text/css" href="search.css"/>
|
|
||||||
<script type="text/javascript" src="variables_2.js"></script>
|
|
||||||
<script type="text/javascript" src="search.js"></script>
|
|
||||||
</head>
|
|
||||||
<body class="SRPage">
|
|
||||||
<div id="SRIndex">
|
|
||||||
<div class="SRStatus" id="Loading">Loading...</div>
|
|
||||||
<div id="SRResults"></div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
createResults();
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
<div class="SRStatus" id="Searching">Searching...</div>
|
|
||||||
<div class="SRStatus" id="NoMatches">No Matches</div>
|
|
||||||
<script type="text/javascript"><!--
|
|
||||||
/* @license magnet:?xt=urn:btih:cf05388f2679ee054f2beb29a391d25f4e673ac3&dn=gpl-2.0.txt GPL-v2 */
|
|
||||||
document.getElementById("Loading").style.display="none";
|
|
||||||
document.getElementById("NoMatches").style.display="none";
|
|
||||||
var searchResults = new SearchResults("searchResults");
|
|
||||||
searchResults.Search();
|
|
||||||
window.addEventListener("message", function(event) {
|
|
||||||
if (event.data == "take_focus") {
|
|
||||||
var elem = searchResults.NavNext(0);
|
|
||||||
if (elem) elem.focus();
|
|
||||||
}
|
|
||||||
});
|
|
||||||
/* @license-end */
|
|
||||||
--></script>
|
|
||||||
</div>
|
|
||||||
</body>
|
|
||||||
</html>
|
|
||||||
@@ -1,4 +0,0 @@
|
|||||||
var searchData=
|
|
||||||
[
|
|
||||||
['h_145',['h',['../structtjregion.html#aecefc45a26f4d8b60dd4d825c1710115',1,'tjregion']]]
|
|
||||||
];
|
|
||||||