Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

what is the difference ? #1

Closed
luckyjmcc opened this issue Sep 9, 2016 · 8 comments
Closed

what is the difference ? #1

luckyjmcc opened this issue Sep 9, 2016 · 8 comments

Comments

@luckyjmcc
Copy link

luckyjmcc commented Sep 9, 2016

what is the difference between you package com.glidebitmappool.internal.* and Glide's package com.bumptech.glide.load.engine.bitmap_recycle.* ? except Util.java

@amitshekhariitbhu
Copy link
Owner

it's almost same. From there only I created it for my use-cases and added few things to handle different android versions. That's why it's name is Glide Bitmap Pool.

@luckyjmcc
Copy link
Author

so com.glidebitmappool.internal.* can be remove and use glide‘s instead .

@amitshekhariitbhu
Copy link
Owner

amitshekhariitbhu commented Sep 9, 2016

I am not using Glide. I am using Fresco. But I wanted to have it for my use cases. And Smaller size.

@amitshekhariitbhu
Copy link
Owner

Yes you are free to remove it as per your requirement

@luckyjmcc
Copy link
Author

luckyjmcc commented Sep 9, 2016

thanks , in my opinion , using glide's is a good chooice , in situation below:
`
public class GlideConfiguration implements GlideModule {

@Override
public void applyOptions(Context context, GlideBuilder builder) {
    // Apply options to the builder here.
    builder.setDiskCache(new InternalCacheDiskCacheFactory(context, 10 * 1024));//设置使用InternalCacheDiskCacheFactory磁盘高速缓存的大小
    //builder.setDiskCache(new InternalCacheDiskCacheFactory(context, cacheDirectoryName, yourSizeInBytes));//设置磁盘高速缓存的位置
    //builder.setDiskCache(new ExternalCacheDiskCacheFactory(context, cacheDirectoryName, yourSizeInBytes));//缓存在sd卡上公共缓存目录
    builder.setMemoryCache(new LruResourceCache(10 * 1024));//设置大小和/或实现你希望使用内存缓存
    //builder.setBitmapPool(new LruBitmapPool(10 * 1024));
    //统一本地图片和网络图片的BitmapPool
    builder.setBitmapPool(GlideBitmapPool.getInstance().getBitmapPool());
    builder.setDecodeFormat(DecodeFormat.PREFER_RGB_565);
}

@Override
public void registerComponents(Context context, Glide glide) {
    // register ModelLoaders here.
}

}`

@amitshekhariitbhu
Copy link
Owner

Yes, you are correct. But my use case was different . so I used Fresco Library.

@luckyjmcc
Copy link
Author

thanks !

@amitshekhariitbhu
Copy link
Owner

You are welcome

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants