Created
February 21, 2015 15:39
-
-
Save therne/4c1eaf3cc164f8fa05cb to your computer and use it in GitHub Desktop.
Glide Init
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* Glide (이미지 로딩 라이브러리)를 초기화한다. | |
*/ | |
void initGlide() { | |
Glide.setup(new GlideBuilder(this) | |
.setDiskCache(DiskLruCacheWrapper.get(Glide.getPhotoCacheDir(this), DISK_CACHE_SIZE)) | |
.setDecodeFormat(DecodeFormat.PREFER_RGB_565) | |
); | |
Glide.get(this).register(GlideUrl.class, InputStream.class, | |
new OkHttpUrlLoader.Factory(new OkHttpClient())); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment