2016-03-09 12:08:24 +00:00
|
|
|
# A simple Dockerfile for building Kvazaar from the git repository
|
|
|
|
# Example build command when in this directory: docker build -t kvazaar .
|
2016-03-11 08:53:10 +00:00
|
|
|
#
|
|
|
|
# Example usage
|
|
|
|
# Run with an input YUV file and output HEVC binary file
|
|
|
|
# docker run -i -a STDIN -a STDOUT kvazaar -i - --input-res=320x240 -o - < testfile_320x240.yuv > out.265
|
|
|
|
#
|
|
|
|
# Use libav or ffmpeg to input (almost) any format and convert it to YUV420 for kvazaar, audio is disabled
|
|
|
|
#
|
|
|
|
# RESOLUTION=`avconv -i input.avi 2>&1 | grep Stream | grep -oP ', \K[0-9]+x[0-9]+'`
|
|
|
|
# avconv -i input.avi -an -f rawvideo -pix_fmt yuv420p - | docker run -i -a STDIN -a STDOUT kvazaar -i - --wpp --threads=8 --input-res=$RESOLUTION --preset=ultrafast -o - > output.265
|
|
|
|
# or
|
|
|
|
# RESOLUTION=`ffmpeg -i input.avi 2>&1 | grep Stream | grep -oP ', \K[0-9]+x[0-9]+'`
|
|
|
|
# ffmpeg -i input.avi -an -f rawvideo -pix_fmt yuv420p - | docker run -i -a STDIN -a STDOUT kvazaar -i - --wpp --threads=8 --input-res=$RESOLUTION --preset=ultrafast -o - > output.265
|
|
|
|
#
|
2016-03-09 12:08:24 +00:00
|
|
|
|
|
|
|
# Use Ubuntu 15.10 as a base for now, it's around 136MB
|
2016-03-09 09:12:50 +00:00
|
|
|
FROM ubuntu:15.10
|
2016-03-09 12:08:24 +00:00
|
|
|
|
2016-03-11 08:53:10 +00:00
|
|
|
MAINTAINER Marko Viitanen <fador@iki.fi>
|
|
|
|
|
2016-03-09 12:08:24 +00:00
|
|
|
# List of needed packages to be able to build kvazaar with autotools
|
2016-08-18 07:00:26 +00:00
|
|
|
ENV REQUIRED_PACKAGES automake autoconf libtool m4 build-essential git yasm pkgconf
|
2016-03-09 12:08:24 +00:00
|
|
|
|
|
|
|
# Run all the commands in one RUN so we don't have any extra history
|
|
|
|
# data in the image.
|
2016-03-11 08:53:10 +00:00
|
|
|
RUN apt-get update \
|
|
|
|
&& apt-get install -y $REQUIRED_PACKAGES \
|
|
|
|
&& apt-get clean \
|
2018-03-18 06:12:41 +00:00
|
|
|
&& git clone --depth=1 git://github.com/ultravideo/kvazaar.git \
|
|
|
|
&& cd kvazaar \
|
|
|
|
&& ./autogen.sh \
|
|
|
|
&& ./configure --disable-shared \
|
|
|
|
&& make\
|
|
|
|
&& make install \
|
|
|
|
&& AUTOINSTALLED_PACKAGES=`apt-mark showauto` \
|
|
|
|
&& apt-get remove --purge --force-yes -y $REQUIRED_PACKAGES $AUTOINSTALLED_PACKAGES \
|
|
|
|
&& apt-get clean autoclean \
|
|
|
|
&& apt-get autoremove -y \
|
|
|
|
&& rm -rf /var/lib/{apt,dpkg,cache,log}/
|
2016-03-11 11:34:28 +00:00
|
|
|
ENTRYPOINT ["kvazaar"]
|
2016-03-09 09:12:50 +00:00
|
|
|
CMD ["--help"]
|