Java Code Examples for com.bumptech.glide.GlideBuilder#setLogLevel()
The following examples show how to use
com.bumptech.glide.GlideBuilder#setLogLevel() .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DefaultGlideModule.java From star-zone-android with Apache License 2.0 | 6 votes |
@Override public void applyOptions(Context context, GlideBuilder builder) { //磁盘缓存 builder.setDiskCache(new DiskLruCacheFactory(context.getCacheDir().getAbsolutePath(), 50 * 1024 * 1024)); KLog.d("Glide", "glide cache file path >>> " + context.getCacheDir().getAbsolutePath()); //内存缓存 MemorySizeCalculator calculator = new MemorySizeCalculator.Builder(context).build(); int defaultMemoryCacheSize = calculator.getMemoryCacheSize(); int defaultBitmapPoolSize = calculator.getBitmapPoolSize(); //设置比默认大小大1.5倍的缓存和图片池大小 int customMemoryCacheSize = (int) (1.5 * defaultMemoryCacheSize); int customBitmapPoolSize = defaultBitmapPoolSize; builder.setMemoryCache(new LruResourceCache(customMemoryCacheSize)); builder.setBitmapPool(new LruBitmapPool(customBitmapPoolSize)); KLog.d("Glide", "bitmapPoolSize >>>>> " + formatFileSize(context, customBitmapPoolSize) + " / memorySize>>>>>>>> " + formatFileSize(context, customMemoryCacheSize)); builder.setLogLevel(Log.ERROR); }
Example 2
Source File: SignalGlideModule.java From mollyim-android with GNU General Public License v3.0 | 4 votes |
@Override public void applyOptions(Context context, GlideBuilder builder) { builder.setLogLevel(Log.ERROR); // builder.setDiskCache(new NoopDiskCacheFactory()); }
Example 3
Source File: SignalGlideModule.java From bcm-android with GNU General Public License v3.0 | 4 votes |
@Override public void applyOptions(Context context, GlideBuilder builder) { builder.setLogLevel(Log.ERROR); }
Example 4
Source File: SignalGlideModule.java From deltachat-android with GNU General Public License v3.0 | 4 votes |
@Override public void applyOptions(Context context, GlideBuilder builder) { builder.setLogLevel(Log.ERROR); // builder.setDiskCache(new NoopDiskCacheFactory()); }