A well-designed local image and video selector for Android

Overview

Image

Matisse

Build Status Download

Matisse is a well-designed local image and video selector for Android. You can

  • Use it in Activity or Fragment
  • Select images including JPEG, PNG, GIF and videos including MPEG, MP4
  • Apply different themes, including two built-in themes and custom themes
  • Different image loaders
  • Define custom filter rules
  • More to find out yourself
Zhihu Style Dracula Style Preview

Download

Gradle:

repositories {
    jcenter()
}

dependencies {
    implementation 'com.zhihu.android:matisse:$latest_version'
}

Check out Matisse releases to see more unstable versions.

ProGuard

If you use Glide as your image engine, add rules as Glide's README says.
And add extra rule:

-dontwarn com.squareup.picasso.**

If you use Picasso as your image engine, add rules as Picasso's README says.
And add extra rule:

-dontwarn com.bumptech.glide.**

Attention: The above progurad rules are correct.

How do I use Matisse?

Permission

The library requires two permissions:

  • android.permission.READ_EXTERNAL_STORAGE
  • android.permission.WRITE_EXTERNAL_STORAGE

So if you are targeting Android 6.0+, you need to handle runtime permission request before next step.

Simple usage snippet


Start MatisseActivity from current Activity or Fragment:

Matisse.from(MainActivity.this)
        .choose(MimeType.allOf())
        .countable(true)
        .maxSelectable(9)
        .addFilter(new GifSizeFilter(320, 320, 5 * Filter.K * Filter.K))
        .gridExpectedSize(getResources().getDimensionPixelSize(R.dimen.grid_expected_size))
        .restrictOrientation(ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED)
        .thumbnailScale(0.85f)
        .imageEngine(new GlideEngine())
        .showPreview(false) // Default is `true`
        .forResult(REQUEST_CODE_CHOOSE);

Themes

There are two built-in themes you can use to start MatisseActivity:

  • R.style.Matisse_Zhihu (light mode)
  • R.style.Matisse_Dracula (dark mode)

And Also you can define your own theme as you wish.

Receive Result

In onActivityResult() callback of the starting Activity or Fragment:

List<Uri> mSelected;

@Override
protected void onActivityResult(int requestCode, int resultCode, Intent data) {
    super.onActivityResult(requestCode, resultCode, data);
    if (requestCode == REQUEST_CODE_CHOOSE && resultCode == RESULT_OK) {
        mSelected = Matisse.obtainResult(data);
        Log.d("Matisse", "mSelected: " + mSelected);
    }
}

More

Find more details about Matisse in wiki.

Contributing

Matisse is an Open Source Project

Thanks

This library is inspired by Laevatein and uses some of its source code.

License

Copyright 2017 Zhihu Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Comments
  • 设置maxcount为9,当选中了9个,继续去点击选中第10个时,崩溃

    设置maxcount为9,当选中了9个,继续去点击选中第10个时,崩溃

    Describe the bug 设置maxcount为9,当选中了9个,继续去点击选中第10个时,崩溃

    Smartphone (please complete the following information): Android 6.0

    **异常信息 java.lang.NoClassDefFoundError: Failed resolution of: Lcom/zhihu/matisse/R$plurals

    need more info 
    opened by ganzhubing 17
  • 添加依赖问题

    添加依赖问题

    implementation 'com.zhihu.android:matisse:$latest_version' 添加依赖后同步报错 Unable to resolve dependency for ':app@debug/compileClasspath': Could not resolve com.zhihu.android:matisse:$latest_version.

    opened by duckmoon 10
  • 打开相册,点击图片打开图片详情,按home键返回桌面,过一段时间后重新进入,崩溃

    打开相册,点击图片打开图片详情,按home键返回桌面,过一段时间后重新进入,崩溃

    java.lang.RuntimeException: Unable to resume activity {com.huodao.hdphone/com.zhihu.matisse.internal.ui.AlbumPreviewActivity}: android.database.StaleDataException: Attempted to access a cursor after it has been closed. at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3542) at android.app.ActivityThread.handleResumeActivity(ActivityThread.java:3582) at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1610) at android.os.Handler.dispatchMessage(Handler.java:102) at android.os.Looper.loop(Looper.java:154) at android.app.ActivityThread.main(ActivityThread.java:6243) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:912) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:802) Caused by: android.database.StaleDataException: Attempted to access a cursor after it has been closed. at android.database.BulkCursorToCursorAdaptor.throwIfCursorIsClosed(BulkCursorToCursorAdaptor.java:63) at android.database.BulkCursorToCursorAdaptor.getCount(BulkCursorToCursorAdaptor.java:69) at android.database.AbstractCursor.moveToPosition(AbstractCursor.java:219) at android.database.AbstractCursor.moveToNext(AbstractCursor.java:268) at android.database.CursorWrapper.moveToNext(CursorWrapper.java:202) at com.zhihu.matisse.internal.ui.AlbumPreviewActivity.onAlbumMediaLoad(AlbumPreviewActivity.java:71) at com.zhihu.matisse.internal.model.AlbumMediaCollection.onLoadFinished(AlbumMediaCollection.java:64) at com.zhihu.matisse.internal.model.AlbumMediaCollection.onLoadFinished(AlbumMediaCollection.java:33) at android.support.v4.app.LoaderManagerImpl$LoaderObserver.onChanged(LoaderManagerImpl.java:248) at android.arch.lifecycle.LiveData.considerNotify(LiveData.java:109) at android.arch.lifecycle.LiveData.dispatchingValue(LiveData.java:126) at android.arch.lifecycle.LiveData.setValue(LiveData.java:282) at android.arch.lifecycle.MutableLiveData.setValue(MutableLiveData.java:33) at android.support.v4.app.LoaderManagerImpl$LoaderInfo.setValue(LoaderManagerImpl.java:188) at android.support.v4.app.LoaderManagerImpl$LoaderInfo.onLoadComplete(LoaderManagerImpl.java:173) at android.support.v4.content.Loader.deliverResult(Loader.java:130) at android.support.v4.content.CursorLoader.deliverResult(CursorLoader.java:107) at android.support.v4.content.CursorLoader.onStartLoading(CursorLoader.java:153) at android.support.v4.content.Loader.startLoading(Loader.java:283) at android.support.v4.app.LoaderManagerImpl$LoaderInfo.onActive(LoaderManagerImpl.java:76) at android.arch.lifecycle.LiveData$ObserverWrapper.activeStateChanged(LiveData.java:410) at android.arch.lifecycle.LiveData$LifecycleBoundObserver.onStateChanged(LiveData.java:368) at android.arch.lifecycle.LifecycleRegistry$ObserverWithState.dispatchEvent(LifecycleRegistry.java:354) at android.arch.lifecycle.LifecycleRegistry.forwardPass(LifecycleRegistry.java:292) at android.arch.lifecycle.LifecycleRegistry.sync(LifecycleRegistry.java:332) at android.arch.lifecycle.LifecycleRegistry.moveToState(LifecycleRegistry.java:137) at android.arch.lifecycle.LifecycleRegistry.handleLifecycleEvent(LifecycleRegistry.java:123) at android.arch.lifecycle.ReportFragment.dispatch(ReportFragment.java:121) at android.arch.lifecycle.ReportFragment.onStart(ReportFragment.java:81) at android.app.Fragment.performStart(Fragment.java:2378) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1035) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1179) at android.app.FragmentManagerImpl.moveToState(FragmentManager.java:1161) at android.app.FragmentManagerImpl.dispatchStart(FragmentManager.java:2052) at android.app.FragmentController.dispatchStart(FragmentController.java:187) at android.app.Activity.performStart(Activity.java:6779) at android.app.Activity.performRestart(Activity.java:6847) 07-03 07:29:11.624 13779-13779/com.huodao.hdphone E/AndroidRuntime: at android.app.Activity.performResume(Activity.java:6852) at android.app.ActivityThread.performResumeActivity(ActivityThread.java:3513)

    bug 
    opened by jiaozhige 9
  • How to hide types that are not allowed from Matisse?

    How to hide types that are not allowed from Matisse?

    Hi guys, me again, I've made a fork of this library because I had to make some minor changes in order to use it into one of my projects, some of them I've already pull requested here, but the point is that I need to hide files that are not allowed by my application, for example, if I have Matisse.from(this).choose(MimeType.ofVideo(), false) I want to hide all the media that aren't video files, that's an UX request from my development team, I've tried to change the AlbumMediaAdapter by filtering and I have some success, but I still have white frames in the RecyclerView, I don't get why, even trying to use notifyItemChanged or notifyDatasetChanged these gaps don't move away. Do you know why or there's a better way to achieve this?

    These are the changes that I've made so far, I know that's not the best option doing this on adapter, but I need to achieve a fast prototype of this feature.

    @Override
        protected void onBindViewHolder(final RecyclerView.ViewHolder holder, Cursor cursor) {
            final Item item = Item.valueOf(cursor);
    
            if (holder instanceof CaptureViewHolder) {
                CaptureViewHolder captureViewHolder = (CaptureViewHolder) holder;
                Drawable[] drawables = captureViewHolder.mHint.getCompoundDrawables();
                TypedArray ta = holder.itemView.getContext().getTheme().obtainStyledAttributes(
                        new int[]{R.attr.capture_textColor});
                int color = ta.getColor(0, 0);
                ta.recycle();
                for (Drawable drawable : drawables) {
                    if (drawable != null) {
                        drawable.setColorFilter(color, PorterDuff.Mode.SRC_IN);
                    }
                }
            } else if (holder instanceof MediaViewHolder) {
                MediaViewHolder mediaViewHolder = (MediaViewHolder) holder;
    
                if (mSelectionSpec.mimeTypeSet.toString().contains(item.mimeType)) {
                    mediaViewHolder.mMediaGrid.preBindMedia(new MediaGrid.PreBindInfo(
                            getImageResize(mediaViewHolder.mMediaGrid.getContext()),
                            mPlaceholder,
                            mSelectionSpec.countable,
                            holder
                    ));
    
                    mediaViewHolder.mMediaGrid.bindMedia(item);
                    mediaViewHolder.mMediaGrid.setOnMediaGridClickListener(this);
                    setCheckStatus(item, mediaViewHolder.mMediaGrid);
                } else {
                    mediaViewHolder.mMediaGrid.setVisibility(View.GONE);
                }
            }
        } 
    

    Thanks in advance. :)

    opened by bruferrari 9
  • issue importing

    issue importing

    I get this:

    Unable to load class 'org.gradle.api.internal.component.Usage'. Possible causes for this unexpected error include:
    Gradle's dependency cache may be corrupt (this sometimes occurs after a network connection timeout.) Re-download dependencies and sync project (requires network)
    The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem. Stop Gradle build processes (requires restart)
    Your project may be using a third-party plugin which is not compatible with the other plugins in the project or the version of Gradle requested by the project.
    In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.
    

    image

    opened by AndroidDeveloperLB 9
  • use picasso, then crash

    use picasso, then crash

    java.lang.NoSuchMethodError: No static method with(Landroid/content/Context;)Lcom/squareup/picasso/Picasso; in class Lcom/squareup/picasso/Picasso; or its super classes (declaration of 'com.squareup.picasso.Picasso' appears in /data/app/com.miduoxing.www-1/split_lib_dependencies_apk.apk) at com.zhihu.matisse.engine.impl.PicassoEngine.loadThumbnail(PicassoEngine.java:34) at com.zhihu.matisse.internal.ui.widget.PhotoGrid.setImage(PhotoGrid.java:112) at com.zhihu.matisse.internal.ui.widget.PhotoGrid.bindPhoto(PhotoGrid.java:80) at com.zhihu.matisse.internal.ui.adapter.AlbumPhotosAdapter.onBindViewHolder(AlbumPhotosAdapter.java:111) at com.zhihu.matisse.internal.ui.adapter.RecyclerViewCursorAdapter.onBindViewHolder(RecyclerViewCursorAdapter.java:44) at android.support.v7.widget.RecyclerView$Adapter.onBindViewHolder(RecyclerView.java:6356) at android.support.v7.widget.RecyclerView$Adapter.bindViewHolder(RecyclerView.java:6389) at android.support.v7.widget.RecyclerView$Recycler.tryBindViewHolderByDeadline(RecyclerView.java:5335) at android.support.v7.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:5598) at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5440) at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5436) at android.support.v7.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:2224) at android.support.v7.widget.GridLayoutManager.layoutChunk(GridLayoutManager.java:556) at android.support.v7.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1511) at android.support.v7.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:595) at android.support.v7.widget.GridLayoutManager.onLayoutChildren(GridLayoutManager.java:170) at android.support.v7.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:3583) at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:3312) at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:3844) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323) at android.widget.FrameLayout.onLayout(FrameLayout.java:261) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323) at android.widget.FrameLayout.onLayout(FrameLayout.java:261) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.RelativeLayout.onLayout(RelativeLayout.java:1079) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323) at android.widget.FrameLayout.onLayout(FrameLayout.java:261) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1741) at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1585) at android.widget.LinearLayout.onLayout(LinearLayout.java:1494) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323) at android.widget.FrameLayout.onLayout(FrameLayout.java:261) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.LinearLayout.setChildFrame(LinearLayout.java:1741) at android.widget.LinearLayout.layoutVertical(LinearLayout.java:1585) at android.widget.LinearLayout.onLayout(LinearLayout.java:1494) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.widget.FrameLayout.layoutChildren(FrameLayout.java:323) at android.widget.FrameLayout.onLayout(FrameLayout.java:261) at com.android.internal.policy.DecorView.onLayout(DecorView.java:730) at android.view.View.layout(View.java:17663) at android.view.ViewGroup.layout(ViewGroup.java:5577) at android.view.ViewRootImpl.performLayout(ViewRootImpl.java:2383) at android.view.ViewRootImpl.performTraversals(ViewRootImpl.java:2105) at android.view.ViewRootImpl.doTraversal(ViewRootImpl.java:1291) at android.view.ViewRootImpl$TraversalRunnable.run(ViewRootImpl.java:6396) at android.view.Choreographer$CallbackRecord.run(Choreographer.java:876) at android.view.Choreographer.doCallbacks(Choreographer.java:688) at android.view.Choreographer.doFrame(Choreographer.java:623) at android.view.Choreographer$FrameDisplayEventReceiver.run(Choreographer.java:862) at android.os.Handler.handleCallback(Handler.java:754) at android.os.Handler.dispatchMessage(Handler.java:95) at android.os.Looper.loop(Looper.java:163) at android.app.ActivityThread.main(ActivityThread.java:6221) at java.lang.reflect.Method.invoke(Native Method) at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:904) at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:794)

    opened by fanmaoyu0871 8
  • Galary not opening in android Q (10)

    Galary not opening in android Q (10)

    My Application is crashing in android Q (10) it's working fine in the older version

    is your library supported in android 10?

    compileSdkVersion 29
    targetSdkVersion 29
    

    getting this error

    Caused by java.lang.IllegalArgumentException: Invalid column COUNT(*) AS count
           at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:170)
           at android.database.DatabaseUtils.readExceptionFromParcel(DatabaseUtils.java:140)
           at android.content.ContentProviderProxy.query(ContentProviderNative.java:437)
           at android.content.ContentResolver.query(ContentResolver.java:962)
           at android.content.ContentResolver.query(ContentResolver.java:890)
           at androidx.core.content.ContentResolverCompat.query(ContentResolverCompat.java:81)
           at androidx.loader.content.CursorLoader.loadInBackground(CursorLoader.java:63)
           at com.zhihu.matisse.internal.loader.AlbumLoader.loadInBackground(AlbumLoader.java:97)
           at com.zhihu.matisse.internal.loader.AlbumLoader.loadInBackground(AlbumLoader.java:33)
           at androidx.loader.content.AsyncTaskLoader.onLoadInBackground(AsyncTaskLoader.java:307)
           at androidx.loader.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:60)
           at androidx.loader.content.AsyncTaskLoader$LoadTask.doInBackground(AsyncTaskLoader.java:48)
           at androidx.loader.content.ModernAsyncTask$2.call(ModernAsyncTask.java:141)
           at java.util.concurrent.FutureTask.run(FutureTask.java:266)
           at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1167)
           at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:641)
           at java.lang.Thread.run(Thread.java:919)
    

    Please help me what is wrong problem in the library and I am using

    //image picker
        implementation 'com.zhihu.android:matisse:0.5.2-beta5'
     //glide
        implementation 'com.github.bumptech.glide:glide:4.10.0'
        annotationProcessor 'com.github.bumptech.glide:compiler:4.10.0'
    

    my code for opening galary

     Matisse.from(activity)
                        .choose(MimeType.ofImage())
                        .showSingleMediaType(true)
                        .theme(R.style.Matisse_Dracula)
                        .countable(false)
                        .addFilter(GifSizeFilter(320, 320, 5 * Filter.K * Filter.K))
                        .maxSelectable(1)
                        .originalEnable(false)
                        .maxOriginalSize(0)
                        .imageEngine(Glide4Engine())
                        .forResult(REQUEST_GALLERY)
    
    

    Smartphone (please complete the following information):

    • Device: ONEPLUS A6010
    • OS: Q

    Any help would be highly appreciated

    opened by Miteshmakwana73 7
  •  java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference

    java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference

    特殊机型报错,魅蓝Note5 java.lang.NullPointerException: Attempt to invoke virtual method 'boolean java.lang.String.equals(java.lang.Object)' on a null object reference at com.zhihu.matisse.internal.entity.Item.isGif(Item.java:91) at com.zhihu.matisse.internal.ui.widget.PhotoGrid.setGifTag(PhotoGrid.java:88) at com.zhihu.matisse.internal.ui.widget.PhotoGrid.bindPhoto(PhotoGrid.java:78) at com.zhihu.matisse.internal.ui.adapter.AlbumPhotosAdapter.onBindViewHolder(AlbumPhotosAdapter.java:111) at com.zhihu.matisse.internal.ui.adapter.RecyclerViewCursorAdapter.onBindViewHolder(RecyclerViewCursorAdapter.java:44) at android.support.v7.widget.RecyclerView$Adapter.onBindViewHolder(RecyclerView.java:6673) at android.support.v7.widget.RecyclerView$Adapter.bindViewHolder(RecyclerView.java:6714) at android.support.v7.widget.RecyclerView$Recycler.tryBindViewHolderByDeadline(RecyclerView.java:5647) at android.support.v7.widget.RecyclerView$Recycler.tryGetViewHolderForPositionByDeadline(RecyclerView.java:5913) at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5752) at android.support.v7.widget.RecyclerView$Recycler.getViewForPosition(RecyclerView.java:5748) at android.support.v7.widget.LinearLayoutManager$LayoutState.next(LinearLayoutManager.java:2232) at android.support.v7.widget.GridLayoutManager.layoutChunk(GridLayoutManager.java:556) at android.support.v7.widget.LinearLayoutManager.fill(LinearLayoutManager.java:1519) at android.support.v7.widget.LinearLayoutManager.onLayoutChildren(LinearLayoutManager.java:614) at android.support.v7.widget.GridLayoutManager.onLayoutChildren(GridLayoutManager.java:170) at android.support.v7.widget.RecyclerView.dispatchLayoutStep2(RecyclerView.java:3812) at android.support.v7.widget.RecyclerView.dispatchLayout(RecyclerView.java:3529) at android.support.v7.widget.RecyclerView.onLayout(RecyclerView.java:4082)

    need more info 
    opened by zhangman523 7
  • 我用了glide4.6.1

    我用了glide4.6.1

    java.lang.NoSuchMethodError: No virtual method load(Landroid/net/Uri;)Lcom/bumptech/glide/DrawableTypeRequest; in class Lcom/bumptech/glide/RequestManager; or its super classes (declaration of 'com.bumptech.glide.RequestManager' appears in /data/app/com.dfs168.ttxn-cXFwl7okLTkW8FHbv7Vczg==/split_lib_dependencies_apk.apk)
        at com.zhihu.matisse.engine.impl.GlideEngine.loadThumbnail(GlideEngine.java:36)
        at com.zhihu.matisse.internal.ui.widget.PhotoGrid.setImage(PhotoGrid.java:112)
        at com.zhihu.matisse.internal.ui.widget.PhotoGrid.bindPhoto(PhotoGrid.java:80)
        at com.zhihu.matisse.internal.ui.adapter.AlbumPhotosAdapter.onBindViewHolder(AlbumPhotosAdapter.java:111)
        at com.zhihu.matisse.internal.ui.adapter.RecyclerViewCursorAdapter.onBindViewHolder(RecyclerViewCursorAdapter.java:44)
    
    opened by liumingmad 7
  • 这个地方写反了

    这个地方写反了

    ProGuard If you use Glide as your image engine, add rules as Glide's README says. And add extra rule: -dontwarn com.squareup.picasso.** If you use Picasso as your image engine, add rules as Picasso's README says. And add extra rule: -dontwarn com.bumptech.glide.**

    opened by cv0cv0 7
  • Unable to load class 'org.gradle.api.internal.component.Usage'

    Unable to load class 'org.gradle.api.internal.component.Usage'

    gradle 失败,下面是log,请问这个这么破

    Error:Unable to load class 'org.gradle.api.internal.component.Usage'.
    Possible causes for this unexpected error include:<ul><li>Gradle's dependency cache may be corrupt (this sometimes occurs after a network connection timeout.)
    <a href="syncProject">Re-download dependencies and sync project (requires network)</a></li><li>The state of a Gradle build process (daemon) may be corrupt. Stopping all Gradle daemons may solve this problem.
    <a href="stopGradleDaemons">Stop Gradle build processes (requires restart)</a></li><li>Your project may be using a third-party plugin which is not compatible with the other plugins in the project or the version of Gradle requested by the project.</li></ul>In the case of corrupt Gradle processes, you can also try closing the IDE and then killing all Java processes.
    
    opened by naivor 7
  • Replace ViewPager with ViewPager2 to achieve better performance.

    Replace ViewPager with ViewPager2 to achieve better performance.

    Above of all, please let me show the appreciation of this project. But a little problem came to me when I migrated the codes to my own project. That is, ViewPager's performance is not good enough. Whenever a preview page is slided in, a new PreviewItemFragment is crated. So I replace ViewPager with ViewPager2, which automatically caches one page on each side of the current preview page. I hope it will be helpful to the project :)

    opened by kn0w-n0thing 0
  • Upgrade appCompat version for using  ActivityResultLauncher

    Upgrade appCompat version for using ActivityResultLauncher

    Hi I upgrade appCompat version to 1.3.0 for using ActivityResultLauncher instead of deprecated onActivityResult(). higher version of appCompat cause unexpected crash.

    opened by ashrafimostafa 0
  • 同时限制图片数量和视频数量不起作用

    同时限制图片数量和视频数量不起作用

    Describe the bug 使用 maxSelectablePerMediaType(8,1);设置限制最大数量不起作用

    先选中视频,这时候会限制视频数量,但这时也不能选中图片了???逻辑不太对吧

    更离谱的是,先选中图片,这时候竟然图片和视频都没有数量限制了,what??

    有人了解这个问题吗?

    opened by pinguoooo 0
Releases(v0.5.3-beta3)
Owner
Zhihu
知乎 GitHub 官方帐号 ,欢迎关注我们的技术专栏 https://zhuanlan.zhihu.com/hackers
Zhihu
Simple Java image-scaling library implementing Chris Campbell's incremental scaling algorithm as well as Java2D's "best-practices" image-scaling techniques.

imgscalr - Java Image-Scaling Library http://www.thebuzzmedia.com/software/imgscalr-java-image-scaling-library/ Changelog --------- 4.2 * Added sup

Riyad Kalla 1.1k Jan 5, 2023
Usign ascii characters, recreate an image following a local path

CMDImage Usign ascii characters, recreate an image following a local path README El código toma una imagen desde una ruta local para convertirlo en ca

Alexander Hernández 13 Aug 30, 2022
Roman Beskrovnyi 250 Jan 9, 2023
Fast computer vision library for SFM, calibration, fiducials, tracking, image processing, and more.

Table of Contents Introduction Cloning Repository Quick Start Gradle and Maven Building from Source Dependencies Help/Contact Introduction BoofCV is a

Peter Abeles 916 Jan 6, 2023
Provide image storage and access services.

Provide image storage and access services.

shiyq 2 Jan 23, 2022
Diagrams as code is a term used for storing the source of a diagram image as a text file.

Diagrams as code Diagrams as code is a term used for storing the source of a diagram image as a text file. Examples are architecture diagrams, or diag

null 26 Nov 21, 2022
Custom Image Server for use with ShareX

rImageServer How to use: Normal Instalation: Download .jar Start: javar -jar [filename].jar Edit: imageserver.propierties Check if web works -> Go to

Ryzeon 11 May 21, 2022
Luban—Image compression with efficiency very close to WeChat Moments

Luban—Image compression with efficiency very close to WeChat Moments

郑梓斌 13.1k Dec 29, 2022
Pw0 Framewrok - magical android pentest app 🔮! Pixie Dust, Handshakes, Deauth, Nmap, Port scanner and more!

Pw0 Framework Pw0 Framewrok - magical android pentest app ?? ! Features: Pixie Dust Handshakes Deauth Nmap Port scanner and more! Version: 0.2 Beta Au

Huntmix 17 Sep 27, 2021
ZXing ("Zebra Crossing") barcode scanning library for Java, Android

Project in Maintenance Mode Only The project is in maintenance mode, meaning, changes are driven by contributed patches. Only bug fixes and minor enha

ZXing Project 30.5k Jan 4, 2023
Anthos Edge Use Cases for bringing apps and computation closer to the location where the action is, to improve response times and save bandwidth.

Anthos Bare Metal Edge Use Cases Edge computing is a distributed computing paradigm that brings computation and data storage closer to the location wh

Google Cloud Platform 27 Dec 20, 2022
Java interface to OpenCV, FFmpeg, and more

JavaCV Commercial support: Introduction JavaCV uses wrappers from the JavaCPP Presets of commonly used libraries by researchers in the field of comput

Bytedeco 6.4k Jan 4, 2023
TwelveMonkeys ImageIO: Additional plug-ins and extensions for Java's ImageIO

About TwelveMonkeys ImageIO is a collection of plugins and extensions for Java's ImageIO. These plugins extend the number of image file formats suppor

Harald Kuhr 1.6k Jan 5, 2023
Traditional roguelike game with pixel-art graphics and simple interface

Traditional roguelike game with pixel-art graphics and simple interface

Evan Debenham 2.5k Dec 30, 2022
Million+ point universal gravity simulation using OpenGL and OpenCL

Universe Simulation on GPU A multi-million particle gravity simulation. The main program is org.davu.app.Space.main See each package.html for code det

David Uselmann 2 Jan 31, 2022
This project allows the exchange of files between your local disk and a D64 image (Commodore 64 image disk) . Ce projet permet l'échange de fichiers entre votre disque local et une image D64 (Image de disquette du Commodore 64).

DiskToolC64 Ce projet permet l'échange de fichiers entre votre disque local et une image D64 (Image de disquette du Commodore 64). Introduction Les fi

Eddy BRIERE 3 Oct 12, 2022
Simple Java image-scaling library implementing Chris Campbell's incremental scaling algorithm as well as Java2D's "best-practices" image-scaling techniques.

imgscalr - Java Image-Scaling Library http://www.thebuzzmedia.com/software/imgscalr-java-image-scaling-library/ Changelog --------- 4.2 * Added sup

Riyad Kalla 1.1k Jan 5, 2023
Geoponics is an E-Commerce Android Based Application Designed for Farmers As Well As Normal Users to Buy and Sell Agricultural goods!

Geoponics : E-Commerce Application Geoponics is an E-Commerce Android Based Aplication Designed for Farmers As Well As Normal Users to Buy and Sell Ag

Prasad 3 Aug 31, 2021