From c8b616d361585070dcc2b98abaa867a3971120b3 Mon Sep 17 00:00:00 2001 From: xufulong <839789740@qq.com> Date: Sat, 28 Dec 2019 14:24:01 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=87=E4=BB=B6=E5=90=8E=E7=BC=80=E5=A4=A7?= =?UTF-8?q?=E5=B0=8F=E5=86=99=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 文件后缀大小写处理 --- app/CMakeLists.txt | 14 +++++++------- .../main/java/com/frank/ffmpeg/util/FileUtil.java | 2 ++ 2 files changed, 9 insertions(+), 7 deletions(-) diff --git a/app/CMakeLists.txt b/app/CMakeLists.txt index 7d0c703..24dd6a4 100644 --- a/app/CMakeLists.txt +++ b/app/CMakeLists.txt @@ -41,12 +41,12 @@ set_target_properties( ffmpeg PROPERTIES IMPORTED_LOCATION ../../../../libs/${CMAKE_ANDROID_ARCH_ABI}/libffmpeg.so ) -add_library( mp3lame - SHARED - IMPORTED ) -set_target_properties( mp3lame - PROPERTIES IMPORTED_LOCATION - ../../../../libs/${CMAKE_ANDROID_ARCH_ABI}/libmp3lame.so ) +#add_library( mp3lame +# SHARED +# IMPORTED ) +#set_target_properties( mp3lame +# PROPERTIES IMPORTED_LOCATION +# ../../../../libs/${CMAKE_ANDROID_ARCH_ABI}/libmp3lame.so ) set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=gnu++11") @@ -66,7 +66,7 @@ find_library( # Sets the name of the path variable. target_link_libraries( # Specifies the target library. media-handle - mp3lame +# mp3lame ffmpeg -landroid #native_window -ljnigraphics #bitmap diff --git a/app/src/main/java/com/frank/ffmpeg/util/FileUtil.java b/app/src/main/java/com/frank/ffmpeg/util/FileUtil.java index 01a7cde..359588d 100644 --- a/app/src/main/java/com/frank/ffmpeg/util/FileUtil.java +++ b/app/src/main/java/com/frank/ffmpeg/util/FileUtil.java @@ -111,6 +111,7 @@ public class FileUtil { if (TextUtils.isEmpty(path)) { return false; } + path = path.toLowerCase(); return path.endsWith(TYPE_MP3) || path.endsWith(TYPE_AAC) || path.endsWith(TYPE_AMR) @@ -126,6 +127,7 @@ public class FileUtil { if (TextUtils.isEmpty(path)) { return false; } + path = path.toLowerCase(); return path.endsWith(TYPE_MP4) || path.endsWith(TYPE_MKV) || path.endsWith(TYPE_WEBM)