프로젝트
GitHub에서 보기
umirtech/ffmpegAndroid
umirtech/ffmpegAndroid has 52 GitHub stars and 32 forks. GitHot measured 0 stars in 24 hours and 0 in 7 days. Last checked 2026-11-21 07:32 UTC. Last push 2026-10-21.
측정된 스타 증가
- in 24h
- 0
- in 7 days
- 0
- in 15 days
- 기록 수집 중
- in 1 month
- 기록 수집 중
서로 겹치는 기간의 순증가량이며 일별 합계가 아닙니다. 측정값이 없으면 비워 둡니다. 스타는 관심도를 나타내며 품질을 보장하지 않습니다.
소개
Compile Latest FFMPEG for Android
창작 및 미디어README.md
OriginalCompile FFMPEG shared (.so) or static (.a) files for android
For Step By Step tutorial Read this Article (Compile FFMPEG For Android)
How to add it to Your Android Studio Project -:
- Create jniLibs folder inside /main folder example
\<Your Project Directory>\<Your Project>\src\main\jniLibs - Copy and paste these files inside jniLibs folder.
- And after that add this in Your cmakeList.txt file
set(IMPORT_DIR ${CMAKE_SOURCE_DIR}/../jniLibs)
# FFmpeg include file
set(FFMPEG_INCLUDE_DIR ${IMPORT_DIR}/${ANDROID_ABI}/include)
set(FFMPEG_LIB_DIR ${IMPORT_DIR}/${ANDROID_ABI}/lib)
include_directories(${FFMPEG_INCLUDE_DIR})
# Codec library
add_library(
avcodec
SHARED
IMPORTED
)
set_target_properties(
avcodec
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libavcodec.so
)
# The filter library is temporarily out of use
add_library(
avfilter
SHARED
IMPORTED
)
set_target_properties(
avfilter
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libavfilter.so
)
# File format libraries are required for most operations
add_library(
avformat
SHARED
IMPORTED
)
set_target_properties(
avformat
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libavformat.so
)
# Tool library
add_library(
avutil
SHARED
IMPORTED
)
set_target_properties(
avutil
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libavutil.so
)
# The resampling library is mainly used for audio conversion.
add_library(
swresample
SHARED
IMPORTED
)
set_target_properties(
swresample
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libswresample.so
)
# Video format conversion library is mainly used for video conversion.
add_library(
swscale
SHARED
IMPORTED
)
set_target_properties(
swscale
PROPERTIES IMPORTED_LOCATION
${FFMPEG_LIB_DIR}/libswscale.so
)
# The main android library, native window, requires this library
target_link_libraries(
<Your-Native-Library>
${log-lib}
android
avcodec
avfilter
avformat
avutil
swresample
swscale
)
- Add this in your Module build.gradle file
defaultConfig {
//............//
ndk.abiFilters 'armeabi-v7a', 'arm64-v8a', 'x86', 'x86_64'
externalNativeBuild {
cmake {
cppFlags "-std=c++17 -fexceptions -frtti"
arguments "-DANDROID_STL=c++_shared"
}
}
}