add x26{4,5}

This commit is contained in:
2025-09-06 20:13:56 -05:00
parent 0518a48045
commit a63d9e3e65
5 changed files with 137 additions and 73 deletions

8
Jenkinsfile vendored
View File

@@ -35,8 +35,8 @@ pipeline {
stage('build ffmpeg on darwin') { stage('build ffmpeg on darwin') {
matrix { matrix {
axes { axes {
axis { name 'OPT_LTO'; values 'OPT=0 LTO=false', 'OPT=2 LTO=false', 'OPT=3 LTO=true' } axis { name 'OPT_LTO'; values 'OPT=0 LTO=OFF', 'OPT=3 LTO=ON' }
axis { name 'STATIC'; values 'true', 'false' } axis { name 'STATIC'; values 'ON', 'OFF' }
} }
stages { stages {
stage('build on darwin ') { stage('build on darwin ') {
@@ -53,8 +53,8 @@ pipeline {
axes { axes {
axis { name 'ARCH'; values 'armv8-a', 'x86-64-v3' } axis { name 'ARCH'; values 'armv8-a', 'x86-64-v3' }
axis { name 'DISTRO'; values 'ubuntu-24.04', 'fedora-42', 'debian-13', 'archlinux-latest' } axis { name 'DISTRO'; values 'ubuntu-24.04', 'fedora-42', 'debian-13', 'archlinux-latest' }
axis { name 'OPT_LTO'; values 'OPT=0 LTO=false', 'OPT=3 LTO=true' } axis { name 'OPT_LTO'; values 'OPT=0 LTO=OFF', 'OPT=3 LTO=ON' }
axis { name 'STATIC'; values 'true', 'false' } axis { name 'STATIC'; values 'ON', 'OFF' }
} }
stages { stages {
stage('build ffmpeg on linux using docker') { stage('build ffmpeg on linux using docker') {

View File

@@ -45,17 +45,17 @@ set_compile_opts() {
) )
PKG_CONFIG_PATH="${LIBDIR}/pkgconfig" PKG_CONFIG_PATH="${LIBDIR}/pkgconfig"
export PKG_CONFIG_PATH export PKG_CONFIG_PATH
echo_info "PKG_CONFIG_PATH=${PKG_CONFIG_PATH}"
# add prefix include # add prefix include
C_FLAGS+=("-I${PREFIX}/include") C_FLAGS+=("-I${PREFIX}/include")
# enabling link-time optimization # enabling link-time optimization
# shellcheck disable=SC2034 # shellcheck disable=SC2034
unset LTO_SWITCH LTO_FLAG LTO_BOOL unset LTO_FLAG
export LTO_SWITCH LTO_FLAG LTO_BOOL export LTO_FLAG
if [[ ${LTO} == 'true' ]]; then if [[ ${LTO} == 'ON' ]]; then
echo_info "building with LTO" echo_info "building with LTO"
LTO_SWITCH='ON'
LTO_FLAG='-flto' LTO_FLAG='-flto'
C_FLAGS+=("${LTO_FLAG}") C_FLAGS+=("${LTO_FLAG}")
if ! is_darwin; then if ! is_darwin; then
@@ -65,7 +65,6 @@ set_compile_opts() {
RUSTFLAGS+=("-C lto=yes" "-C inline-threshold=1000" "-C codegen-units=1") RUSTFLAGS+=("-C lto=yes" "-C inline-threshold=1000" "-C codegen-units=1")
else else
echo_info "building without LTO" echo_info "building without LTO"
LTO_SWITCH='OFF'
LTO_FLAG='' LTO_FLAG=''
MESON_FLAGS+=("-Db_lto=false") MESON_FLAGS+=("-Db_lto=false")
RUSTFLAGS+=("-C lto=no") RUSTFLAGS+=("-C lto=no")
@@ -89,15 +88,15 @@ set_compile_opts() {
fi fi
# static/shared linking # static/shared linking
unset PKG_CFG_FLAGS LIB_SUFF unset PKG_CONFIG_FLAGS LIB_SUFF
export PKG_CFG_FLAGS LIB_SUFF export PKG_CONFIG_FLAGS LIB_SUFF
if [[ ${STATIC} == true ]]; then if [[ ${STATIC} == 'ON' ]]; then
LDFLAGS+=('-static') LDFLAGS+=('-static')
CONFIGURE_FLAGS+=('--enable-static') CONFIGURE_FLAGS+=('--enable-static')
MESON_FLAGS+=('--default-library=static') MESON_FLAGS+=('--default-library=static')
CMAKE_FLAGS+=("-DBUILD_SHARED_LIBS=OFF") CMAKE_FLAGS+=("-DBUILD_SHARED_LIBS=OFF")
RUSTFLAGS+=("-C target-feature=+crt-static") RUSTFLAGS+=("-C target-feature=+crt-static")
PKG_CFG_FLAGS='--static' PKG_CONFIG_FLAGS='--static'
# darwin does not support static linkage # darwin does not support static linkage
if ! is_darwin; then if ! is_darwin; then
CMAKE_FLAGS+=("-DCMAKE_EXE_LINKER_FLAGS=-static") CMAKE_FLAGS+=("-DCMAKE_EXE_LINKER_FLAGS=-static")
@@ -123,7 +122,7 @@ set_compile_opts() {
# arm prefers -mcpu over -march for native builds # arm prefers -mcpu over -march for native builds
# https://community.arm.com/arm-community-blogs/b/tools-software-ides-blog/posts/compiler-flags-across-architectures-march-mtune-and-mcpu # https://community.arm.com/arm-community-blogs/b/tools-software-ides-blog/posts/compiler-flags-across-architectures-march-mtune-and-mcpu
local arch_flags=() local arch_flags=()
if [[ ${HOSTTYPE} == "aarch64" && "${ARCH}" == 'native' ]]; then if [[ ${HOSTTYPE} == "aarch64" && ${ARCH} == 'native' ]]; then
arch_flags+=("-mcpu=${ARCH}") arch_flags+=("-mcpu=${ARCH}")
else else
arch_flags+=("-march=${ARCH}") arch_flags+=("-march=${ARCH}")
@@ -145,7 +144,7 @@ set_compile_opts() {
dump_arr CARGO_CINSTALL_FLAGS dump_arr CARGO_CINSTALL_FLAGS
dump_arr CMAKE_FLAGS dump_arr CMAKE_FLAGS
dump_arr MESON_FLAGS dump_arr MESON_FLAGS
dump_arr PKG_CFG_FLAGS dump_arr PKG_CONFIG_FLAGS
# extra ffmpeg flags # extra ffmpeg flags
FFMPEG_EXTRA_FLAGS+=( FFMPEG_EXTRA_FLAGS+=(
@@ -182,23 +181,29 @@ get_build_conf() {
# shellcheck disable=SC2016 # shellcheck disable=SC2016
local BUILDS_CONF=' local BUILDS_CONF='
ffmpeg 8.0 tar.gz https://github.com/FFmpeg/FFmpeg/archive/refs/tags/n${ver}.${ext} ffmpeg 8.0 tar.gz https://github.com/FFmpeg/FFmpeg/archive/refs/tags/n${ver}.${ext}
libsvtav1_psy 3.0.2-A tar.gz https://github.com/BlueSwordM/svt-av1-psyex/archive/refs/tags/v${ver}.${ext} dovi_tool,hdr10plus_tool,cpuinfo
hdr10plus_tool 1.7.1 tar.gz https://github.com/quietvoid/hdr10plus_tool/archive/refs/tags/${ver}.${ext} hdr10plus_tool 1.7.1 tar.gz https://github.com/quietvoid/hdr10plus_tool/archive/refs/tags/${ver}.${ext}
dovi_tool 2.3.0 tar.gz https://github.com/quietvoid/dovi_tool/archive/refs/tags/${ver}.${ext} dovi_tool 2.3.0 tar.gz https://github.com/quietvoid/dovi_tool/archive/refs/tags/${ver}.${ext}
cpuinfo latest git https://github.com/pytorch/cpuinfo/
libsvtav1 3.1.2 tar.gz https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v${ver}/SVT-AV1-v${ver}.${ext} libsvtav1 3.1.2 tar.gz https://gitlab.com/AOMediaCodec/SVT-AV1/-/archive/v${ver}/SVT-AV1-v${ver}.${ext}
libsvtav1_psy 3.0.2-A tar.gz https://github.com/BlueSwordM/svt-av1-psyex/archive/refs/tags/v${ver}.${ext} dovi_tool,hdr10plus_tool,cpuinfo
librav1e 0.8.1 tar.gz https://github.com/xiph/rav1e/archive/refs/tags/v${ver}.${ext} librav1e 0.8.1 tar.gz https://github.com/xiph/rav1e/archive/refs/tags/v${ver}.${ext}
libaom 3.12.1 tar.gz https://storage.googleapis.com/aom-releases/libaom-${ver}.${ext} libaom 3.12.1 tar.gz https://storage.googleapis.com/aom-releases/libaom-${ver}.${ext}
libvmaf 3.0.0 tar.gz https://github.com/Netflix/vmaf/archive/refs/tags/v${ver}.${ext} libvmaf 3.0.0 tar.gz https://github.com/Netflix/vmaf/archive/refs/tags/v${ver}.${ext}
libopus 1.5.2 tar.gz https://github.com/xiph/opus/releases/download/v${ver}/opus-${ver}.${ext} libopus 1.5.2 tar.gz https://github.com/xiph/opus/releases/download/v${ver}/opus-${ver}.${ext}
libdav1d 1.5.1 tar.xz http://downloads.videolan.org/videolan/dav1d/${ver}/dav1d-${ver}.${ext} libdav1d 1.5.1 tar.xz http://downloads.videolan.org/videolan/dav1d/${ver}/dav1d-${ver}.${ext}
cpuinfo latest git https://github.com/pytorch/cpuinfo/ libx264 latest git https://code.videolan.org/videolan/x264.git
libx265 4.1 tar.gz https://bitbucket.org/multicoreware/x265_git/downloads/x265_${ver}.${ext} libnuma
libnuma 2.0.19 tar.gz https://github.com/numactl/numactl/archive/refs/tags/v${ver}.${ext}
' '
local supported_builds=() local supported_builds=()
unset ver ext url deps extracted_dir unset ver ext url deps extracted_dir
while read -r line; do while read -r line; do
test "${line}" == '' && continue test "${line}" == '' && continue
IFS=' ' read -r build ver ext url deps <<<"${line}" IFS=$' \t' read -r build ver ext url deps <<<"${line}"
supported_builds+=("${build}") supported_builds+=("${build}")
if [[ ${getBuild} != "${build}" ]]; then if [[ ${getBuild} != "${build}" ]]; then
build='' build=''
@@ -287,6 +292,20 @@ download_release() {
# for git downloads # for git downloads
test -d "${base_dl_path}" || test -d "${base_dl_path}" ||
git clone "${url}" "${base_dl_path}" || return 1 git clone "${url}" "${base_dl_path}" || return 1
(
cd "${base_dl_path}" || exit 1
local localHEAD remoteHEAD
localHEAD="$(git rev-parse HEAD)"
IFS=$' \t' read -r remoteHEAD _ <<< \
"$(git ls-remote "$(git config --get remote.origin.url)" HEAD)"
if [[ ${localHEAD} != "${remoteHEAD}" ]]; then
git pull --ff-only
fi
localHEAD="$(git rev-parse HEAD)"
if [[ ${localHEAD} != "${remoteHEAD}" ]]; then
echo_exit "could not update git for ${build}"
fi
) || return 1
# create new build directory # create new build directory
test -d "${extracted_dir}" || test -d "${extracted_dir}" ||
@@ -389,46 +408,11 @@ sanitize_sysroot_libs() {
return 0 return 0
} }
### RUST ### del_pkgconfig_gcc_s() {
build_hdr10plus_tool() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/hdr10plus_tool" \
"${PREFIX}/bin/" || return 1
# build libhdr10plus
cd hdr10plus || return 1
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'libhdr10plus-rs' || return 1
}
build_dovi_tool() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/dovi_tool" \
"${PREFIX}/bin/" || return 1
# build libdovi
cd dolby_vision || return 1
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'libdovi' || return 1
}
build_librav1e() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/rav1e" \
"${PREFIX}/bin/" || return 1
# build librav1e
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'librav1e' || return 1
# HACK PATCH # HACK PATCH
# remove '-lgcc_s' from pkgconfig for static builds # remove '-lgcc_s' from pkgconfig for static builds
if [[ ${STATIC} == 'true' ]]; then if [[ ${STATIC} == 'ON' ]]; then
local fname='rav1e.pc' local fname="$1"
local cfg="${PKG_CONFIG_PATH}/${fname}" local cfg="${PKG_CONFIG_PATH}/${fname}"
local newCfg="${TMP_DIR}/${fname}" local newCfg="${TMP_DIR}/${fname}"
test -f "${cfg}" || return 1 test -f "${cfg}" || return 1
@@ -446,6 +430,46 @@ build_librav1e() {
fi fi
} }
### RUST ###
build_hdr10plus_tool() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/hdr10plus_tool" \
"${PREFIX}/bin/" || return 1
# build libhdr10plus
cd hdr10plus || return 1
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'libhdr10plus-rs' || return 1
}
build_dovi_tool() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/dovi_tool" \
"${PREFIX}/bin/" || return 1
# build libdovi
cd dolby_vision || return 1
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'libdovi' || return 1
}
build_librav1e() {
cargo build "${CARGO_FLAGS[@]}" || return 1
${SUDO_MODIFY} cp \
"target/${CARGO_BUILD_TYPE}/rav1e" \
"${PREFIX}/bin/" || return 1
# build librav1e
cargo cbuild "${CARGO_FLAGS[@]}" || return 1
${SUDO_CARGO} bash -lc "PATH=\"${PATH}\" cargo cinstall ${CARGO_CINSTALL_FLAGS[*]}" || return 1
sanitize_sysroot_libs 'librav1e' || return 1
del_pkgconfig_gcc_s 'rav1e.pc' || return 1
}
### CMAKE ### ### CMAKE ###
build_cpuinfo() { build_cpuinfo() {
cmake \ cmake \
@@ -458,6 +482,7 @@ build_cpuinfo() {
${SUDO_MODIFY} make -j"${JOBS}" install || return 1 ${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libcpuinfo' || return 1 sanitize_sysroot_libs 'libcpuinfo' || return 1
} }
build_libsvtav1() { build_libsvtav1() {
cmake \ cmake \
"${CMAKE_FLAGS[@]}" \ "${CMAKE_FLAGS[@]}" \
@@ -468,6 +493,7 @@ build_libsvtav1() {
${SUDO_MODIFY} make -j"${JOBS}" install || return 1 ${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libSvtAv1Enc' || return 1 sanitize_sysroot_libs 'libSvtAv1Enc' || return 1
} }
build_libsvtav1_psy() { build_libsvtav1_psy() {
local hdr10pluslib="$(find -L "${PREFIX}" -type f -name "libhdr10plus-rs.${USE_LIB_SUFF}")" local hdr10pluslib="$(find -L "${PREFIX}" -type f -name "libhdr10plus-rs.${USE_LIB_SUFF}")"
local dovilib="$(find -L "${PREFIX}" -type f -name "libdovi.${USE_LIB_SUFF}")" local dovilib="$(find -L "${PREFIX}" -type f -name "libdovi.${USE_LIB_SUFF}")"
@@ -485,6 +511,7 @@ build_libsvtav1_psy() {
${SUDO_MODIFY} make -j"${JOBS}" install || return 1 ${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libSvtAv1Enc' || return 1 sanitize_sysroot_libs 'libSvtAv1Enc' || return 1
} }
build_libaom() { build_libaom() {
cmake \ cmake \
"${CMAKE_FLAGS[@]}" \ "${CMAKE_FLAGS[@]}" \
@@ -495,6 +522,7 @@ build_libaom() {
${SUDO_MODIFY} make -j"${JOBS}" install || return 1 ${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libaom' || return 1 sanitize_sysroot_libs 'libaom' || return 1
} }
build_libopus() { build_libopus() {
cmake \ cmake \
"${CMAKE_FLAGS[@]}" || return 1 "${CMAKE_FLAGS[@]}" || return 1
@@ -503,6 +531,19 @@ build_libopus() {
sanitize_sysroot_libs 'libopus' || return 1 sanitize_sysroot_libs 'libopus' || return 1
} }
build_libx265() {
cmake \
"${CMAKE_FLAGS[@]}" \
-G "Unix Makefiles" \
-DHIGH_BIT_DEPTH=ON \
-DENABLE_HDR10_PLUS=ON \
./source || return 1
ccache make -j"${JOBS}" || return 1
${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libx265' || return 1
del_pkgconfig_gcc_s 'x265.pc' || return 1
}
### MESON ### ### MESON ###
build_libdav1d() { build_libdav1d() {
local enableAsm=true local enableAsm=true
@@ -518,6 +559,7 @@ build_libdav1d() {
${SUDO_MODIFY} ninja -vC build.user install || return 1 ${SUDO_MODIFY} ninja -vC build.user install || return 1
sanitize_sysroot_libs 'libdav1d' || return 1 sanitize_sysroot_libs 'libdav1d' || return 1
} }
build_libvmaf() { build_libvmaf() {
cd libvmaf || return 1 cd libvmaf || return 1
python3 -m virtualenv .venv python3 -m virtualenv .venv
@@ -534,7 +576,7 @@ build_libvmaf() {
# HACK PATCH # HACK PATCH
# add '-lstdc++' to pkgconfig for static builds # add '-lstdc++' to pkgconfig for static builds
if [[ ${STATIC} == 'true' ]]; then if [[ ${STATIC} == 'ON' ]]; then
local fname='libvmaf.pc' local fname='libvmaf.pc'
local cfg="${PKG_CONFIG_PATH}/${fname}" local cfg="${PKG_CONFIG_PATH}/${fname}"
local newCfg="${TMP_DIR}/${fname}" local newCfg="${TMP_DIR}/${fname}"
@@ -554,6 +596,23 @@ build_libvmaf() {
} }
### AUTOTOOLS ### ### AUTOTOOLS ###
build_libx264() {
./configure \
"${CONFIGURE_FLAGS[@]}" || return 1
ccache make -j"${JOBS}" || return 1
${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libx264' || return 1
}
build_libnuma() {
./autogen.sh || return 1
./configure \
"${CONFIGURE_FLAGS[@]}" || return 1
ccache make -j"${JOBS}" || return 1
${SUDO_MODIFY} make -j"${JOBS}" install || return 1
sanitize_sysroot_libs 'libnuma' || return 1
}
add_project_versioning_to_ffmpeg() { add_project_versioning_to_ffmpeg() {
local optFile local optFile
local fname='ffmpeg_opt.c' local fname='ffmpeg_opt.c'
@@ -618,7 +677,7 @@ build_ffmpeg() {
./configure \ ./configure \
"${ffmpegFlags[@]}" \ "${ffmpegFlags[@]}" \
--pkg-config='pkg-config' \ --pkg-config='pkg-config' \
--pkg-config-flags="${PKG_CFG_FLAGS}" \ --pkg-config-flags="${PKG_CONFIG_FLAGS}" \
--enable-gpl \ --enable-gpl \
--enable-version3 \ --enable-version3 \
--enable-nonfree \ --enable-nonfree \
@@ -634,7 +693,7 @@ sanity_check_ffmpeg() {
if has_cmd ldd; then if has_cmd ldd; then
while read -r line; do while read -r line; do
echo "${line}" echo "${line}"
if [[ ${STATIC} == 'true' ]]; then if [[ ${STATIC} == 'ON' ]]; then
echo static echo static
else else
echo hi echo hi

View File

@@ -8,11 +8,11 @@
# clean build directories before building # clean build directories before building
DEFAULT_CLEAN=true DEFAULT_CLEAN=true
# enable link time optimization # enable link time optimization
DEFAULT_LTO=true DEFAULT_LTO=ON
# optimization level (0-3) # optimization level (0-3)
DEFAULT_OPT=3 DEFAULT_OPT=3
# static or shared build # static or shared build
DEFAULT_STATIC=true DEFAULT_STATIC=ON
# architecture type (x86-64-v{1,2,3,4}, armv8-a, etc) # architecture type (x86-64-v{1,2,3,4}, armv8-a, etc)
DEFAULT_ARCH=native DEFAULT_ARCH=native
# prefix to install to, default is local install # prefix to install to, default is local install
@@ -25,6 +25,8 @@ libdav1d \
libaom \ libaom \
librav1e \ librav1e \
libvmaf \ libvmaf \
libx264 \
libx265 \
" "
# user-overridable compile option variable names # user-overridable compile option variable names

View File

@@ -27,7 +27,7 @@ set_efg_opts() {
local maxOpt=${numOpts} local maxOpt=${numOpts}
test $# -lt ${minOpt} && echo_fail "not enough arguments" && efg_usage && return 1 test $# -lt ${minOpt} && echo_fail "not enough arguments" && efg_usage && return 1
test $# -gt ${maxOpt} && echo_fail "too many arguments" && efg_usage && return 1 test $# -gt ${maxOpt} && echo_fail "too many arguments" && efg_usage && return 1
OPTIND=1 local OPTARG OPTIND
while getopts "${opts}" flag; do while getopts "${opts}" flag; do
case "${flag}" in case "${flag}" in
I) I)
@@ -177,6 +177,7 @@ efg_encode() {
local out="${EFG_DIR}/grain-${grain}-${file}" local out="${EFG_DIR}/grain-${grain}-${file}"
encode -P 10 -g ${grain} -i "${vid}" "${out}" encode -P 10 -g ${grain} -i "${vid}" "${out}"
echo -e "\tgrain: ${grain}, bitrate: $(get_avg_bitrate "${out}")" >>"${GRAIN_LOG}" echo -e "\tgrain: ${grain}, bitrate: $(get_avg_bitrate "${out}")" >>"${GRAIN_LOG}"
rm "${out}"
done done
done done
@@ -220,7 +221,9 @@ efg_plot() {
done done
# plot data # plot data
bash -c 'echo $COLUMNS $LINES' >/dev/null 2>&1 # run subprocess for bash COLUMNS/LINES
shopt -s checkwinsize
(true)
gnuplot -p -e "\ gnuplot -p -e "\
set terminal dumb size ${COLUMNS}, ${LINES}; \ set terminal dumb size ${COLUMNS}, ${LINES}; \
set autoscale; \ set autoscale; \

View File

@@ -129,7 +129,7 @@ set_encode_opts() {
test $# -lt ${minOpt} && echo_fail "not enough arguments" && encode_usage && return 1 test $# -lt ${minOpt} && echo_fail "not enough arguments" && encode_usage && return 1
test $# -gt ${maxOpt} && echo_fail "too many arguments" && encode_usage && return 1 test $# -gt ${maxOpt} && echo_fail "too many arguments" && encode_usage && return 1
local optsUsed=0 local optsUsed=0
OPTIND=1 local OPTARG OPTIND
while getopts "${opts}" flag; do while getopts "${opts}" flag; do
case "${flag}" in case "${flag}" in
I) I)