libvideo
libvideo is crossplatform open-source library for encoding and decoding RGBA video using the H.264 standard. The library supports scaling and cropping incoming and outgoing frames.
libvideo
Copyright (C) 2022 Tomsksoft
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License along
with this program; if not, write to the Free Software Foundation, Inc.,
51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
This software uses code of FFmpeg licensed under the LGPLv2.1
and code of libx264 licensed under the GPLv2.0.
FFmpeg source, libx264 source
libvideo owners are not the owners of FFmpeg and libx264. You can go to the site with the owners using the links above.
libvideo licensed under the GPLv2.0 (more details in the LICENSE file) and owned by the TomskSoft company.
- Windows 10
- Android API 21
- CMake 3.16.0
- Conan 1.56.0
- Visual Studio 2019 (Windows only)
- Linux (Cross build Linux to Android)
On main project directory execute:
debug version
py .ci/prebuild_thirdparty.py --build-debug
release version
py .ci/prebuild_thirdparty.py --build-release
cmake -S . -B build_ -G "Visual Studio 16 2019"
MSBuild /fl /flp:Verbosity=diagnostic /t:Build /p:Configuration=Debug /nologo /m:4 libvideo.sln
Use -pr=.ci/conan_profiles/conan_profile_release if you want build release version
conan build . --build-folder build_
conan create . libvideo/1.0.0@ccor/libvideo --build=missing
conan create . libvideo/1.0.0@ccor/libvideo -tf None --build=missing
On main project directory execute:
debug version
python3 .ci/prebuild_thirdparty.py --build-debug --android
release version
python3 .ci/prebuild_thirdparty.py --build-release --android
- Open libvideo-android folder as Android Studio project
- Use Android Studio to build project
In AndroidSDK folder
./gradlew build
-
Go to AMF SDK github and download project files
-
Create folder "ForAMF", inside this folder create folder "AMF"
-
Download AMF SDK
-
Copy folders "components" and "core" from downloaded "amf/public/include" to "AMF" folder
The path should be like this:
C:/ForAMF/AMF/components C:/ForAMF/AMF/core
-
On main project directory execute:
debug versionpy .ci/prebuild_thirdparty.py --build-debug --enable-amf -cflags <path_to_AMF>
release version
py .ci/prebuild_thirdparty.py --build-release --enable-amf -cflags <path_to_AMF>
For example:
py .ci/prebuild_thirdparty.py --build-release --enable-amf -cflags C:/ForAMF/
C++ code formatted by clang-format and using _clang-format.
libvideo.clang-format based on LLVM format.
For reformatting project files open main project folder and put command:
Windows
clang-format.exe -i -style=file Include/*.h src/*.h src/*.cpp src/Filters/*.h src/Filters/*.cpp src/FormatConvertors/*.h src/FormatConvertors/*.cpp src/WindowsManager/*.h src/WindowsManager/*.cpp test_package/*.cpp test_package/*.h
Linux
clang-format -i -style=file Include/*.h src/*.h src/*.cpp src/Filters/*.h src/Filters/*.cpp src/FormatConvertors/*.h src/FormatConvertors/*.cpp src/WindowsManager/*.h src/WindowsManager/*.cpp test_package/*.cpp test_package/*.h
C++ code analyzing by clang-tidy and using .clang-tidy.
For analyze code while build add --enable-tidy
to prebuild thirdparty stage.
For example:
py .ci/prebuild_thirdparty.py --build-debug --enable-tidy