Skip to content

Releases: bumptech/glide

Glide 4.13.0

08 Feb 00:43
Compare
Choose a tag to compare

Features

Bugs

  • Improve performance of canceling pending requests (627d04a, thanks @yorickhenning)
  • Improve memory overhead when decoding byte[] and ByteBuffer (042f6b5)
  • Avoid returning duplicate transcode classes in the registry (ce8b5e3, thanks @fightyz)
  • Avoid cancelling higher tier (usually higher resolution) preload requests when a lower tier completes (4733d1d)
  • Decrease the maximum FD size limit for certain devices to avoid native crashes (808a685)
  • Fix memory leak caused by unusual activity/fragment lifecycle interactions (8bebf71)
  • Fix decoding videos from assets (52a8cf8)

Deprecations

  • Deprecate .thumbnail(float) to simplify the thumbnail logic, particularly around request listeners. The same behavior can be easily reproduced by using .thumbnail() with a RequestBuilder on which you set size multiplier. (aa23eed)

Behavior Changes

  • Set the default color space to null instead of SRGB (ce6852d, 9dc1f60, thanks @skyinu)
  • Fallback to decoding data from source if possible when writing the source to the disk cache fails (755c39f)
  • Avoid using deprecated APIs for detecting connectivity state on API 24+ (dbdae56, 833ef21)
  • Added support for detecting animated webp's to Glide's ImageHeaderParser (42654b2)

Breaking Changes

Build Changes

Glide 4.12.0

29 Jan 23:54
Compare
Choose a tag to compare

Features

  • Add a Cronet integration library (ba99582, ff29849, 114251e, 1dd0576, 3d54ef5)
  • Add support for width/height to the SvgDecoder in the sample app (@chggr, 5a814a1)
  • Add a thumbnail method that takes a list of RequestBuilders so that you don't have to nest a long series of requests (67b01f6)
  • Add a .error() method that takes a model to more easily start a fallback request. There's a bit of nuance with how this is treated, so if you use it, please read the javadoc carefully (d1aacb5, e442557)

Bugs

  • Hardcode disallowed device models for hardware Bitmaps (0647c41, 90a657b, ddb3934)
  • Fix flickr sample by allowing non-https urls (@landicefu, b2a361a)
  • Fix a verificatio nerror in ParcelFileDescriptorRewinder on API levels < 21 (@mkj-gram , 5b117b3)
  • Fix never returning larger size keys in Flickr sample (@valentinilk, 78ecfd2)
  • Fix bugs caused by items changing sizes while in Glide's LruCache (5090b6d)
  • Fix annotation processor with more than 5 library modules on some platforms (#4106, 7cc865a)
  • Fix ConcurrentModificationException due to race in Glide's trimMemory method (#4162, cce9375)
  • Note that RequestListener.onLoadFailed's model is Nullable (@opayen, 621e2d5)
  • Fix an IllegalArgumentException in GifFrameLoader if the GIF is started before it's visible (@dalinaum, 1ae9a2a)
  • Avoid adding both support and non-support RequestManagers when Glide is used with a FragmentActivity as both a FragmentActivity and a regular Activity (8f354dc)
  • Avoid a memory leak when starting RequestManagers in some cases (14a0e1a)
  • Workaround a JDK bug triggered sometimes by Registry (6aa7ad2)
  • Progress on some workarounds to avoid obscure Hardware Bitmap issues on versions of Android< P (edd96d8, 8584b45, a3a3a65, b0a7efe, 7d7042c, b451065)
  • Avoid claiming annotations in Glide's processor (@cushon, e9e5a2e)
  • Fix issues with clone/autoclone in RequestBuilder (332807a, 11530fd)
  • Fix a bug where we could decode partial images for large PNG files where obtaining the metadata caused us to skip past the limit of our buffer (danfang@, 2b61482)
  • Make sure to rethrow in our exception handling streams to workaround an infinite loop in ExifInterface (59ec98c)
  • Reduce the number of stat() syscalls in Glide's startup (5acc99f)

Deprecations

Behavior Changes

  • Better http status codes in HttpUrlFetcher failures (efe8023)

Breaking Changes

Build Changes

  • Add a Gradle Wrapper Validation Github Action (@JLLeitschuh, d75bb30)
  • Removed Monkeyrunner (5aa0b4f)
  • Update ExifInterface version to 1.2.0 (85868bd)
  • Switch from travis-ci to Github actions for presubmits (dbdb62c)

Glide 4.11.0

08 Jan 23:50
Compare
Choose a tag to compare

Features

  • Add a thread timeout for Glide's threads to reduce memory when Glide is infrequently used in an application (db3acef)
  • Add getters to Bitmap Pool for cache statistics (1382e56, thanks to vtsuei@)
  • Add methods to concurrent integration libraries that allow releasing resources back to Glide's pool (277765705)
  • Allow decoding videos from ByteBuffers so that remote videos can be decoded when using a disk cache strategy other than the default (9190698, #4021)

Bugs

  • Improve ModelLoader error text (83ba102)
  • Fix errors with thumbnail loaders that could cause flashing to placeholders (690f815)
  • Fix an exception using Arrays.addAll on some devices/versions of Android (42d3f07)
  • Work around framework bug that breaks heic/heif decoding on Android Q for applications that opt in to legacy storage or request ACCESS_MEDIA_LOCATION (1c51b24)
  • Improve hardware bitmap use on P+ where more file descriptors are available (e8c841c)
  • Avoid removing caller added listeners in GlideFutures (0acd87c)
  • Avoid propagating unexpected callbacks from cancelled or failed model loaders (7e750ca)
  • Switch to the support exif library to avoid spurious logs (bd6f894, #3851)
  • Fix deadlock when recursively clearing resources, typically GIFs (100ac4a)

Deprecations

Behavior Changes

  • Allow decoding files via FileDescriptors when all other types fail so that files with headers exceeding the buffer size can be decoded (typically DNGs with metadata at the end of the file (9281d8e, thanks to timurrrr@)

Breaking Changes

Build Changes

Glide 4.10.0

18 Sep 22:44
Compare
Choose a tag to compare

Features

  • Added a Mocks library to mock GlideExecutor in unit/emulator tests (e021f6b)
  • Added an integration library to integrate with Guava's ListenableFuture class (9fb1036)
  • Add granular options for rounded corners (f36a9fa, thanks to dlos@)
  • Include day/night mode in resource id cache keys (1b391c4)
  • Add an API that can be called on Glide manually to clear memory, especially when apps are backgrounded (8a094e9, thanks to mikewallstedt@)
  • Add simple support for wide gamut color spaces (15a21b1, 7910f68)
  • Release more memory in the background on M+ (525e7ba)
  • Support Fragments not hosted by Acitivities (71359c7, thanks to Daniel Tomasiewicz)
  • Handle contexts with null application contexts (31b501d, thanks to Daniel Tomasiewicz)

Bugs

  • Fixed incorrect downsampling for rotated images when using Target.SIZE_ORIGINAL (79dac0d, thanks to sonyamollinger@)
  • Fixed returning negative byte values converting ByteBuffers to InputStreams (24f9c28, thanks to sonyamollinger@)
  • Make sure to cancel all preload requests in cancelAll() (047c22d, thanks @paynemiller92)
  • Fixed a series of concurrency bugs introduced by allowing requests to start on background threads (bee6348, 5cccdfb, 01ea6a5, b2a46ef, 6dc03d8, 4de2cda, b96b000, 8907122, 53438b9)
  • Make sure the specified numbers of threads are actually used in the animation executor (#3575, ac4aa53, thanks to @yuriy-budiyev)
  • Avoid blinking when calling RequestManager#pause when the thumbnail portion of a request is complete the full portion is still running (2f56153)
  • Make it less likely to mix support and non-support fragments (2193306, thanks to @limuyang2)
  • Avoid downsampling incorrectly in FitCenter and CenterInside when there was
    an exact power of 2 match in one dimension but not the other (3df5445)
  • Always use orientation corrected sizes in Downsampler (#3673, ebdf8be)
  • Fix transparency in GifDecoder when using RGB_565 (29c553d, thanks to @lihongyu)
  • Handle security exceptions trying to open MediaStore Uris when applications are given access to a MediaStore Uri via an Intent (#3504, 9c48b48)
  • Fix an unused AnimationExecutor (7bb6f11, thanks to @phxnirvana)

Deprecations

  • Deprecate method to set custom tags in CustomViewTarget (c8d646e)

Behavior Changes

  • Custom tags in CustomViewTarget are now ignored because they cause Glide to ignore calls to clear() (c8d646e)

Breaking Changes

Build Changes

Glide 4.9.0

14 Feb 20:53
Compare
Choose a tag to compare

Features

  • Allow applying RequestOptions directly in a RequestBuilder without the generated API (ed20643)

For example previously to apply centerCrop you'd have use a static method and apply():

Glide.with(fragment)
   .load(url)
   .apply(centerCropTransform())
   .into(imageView);

Or use the generated API and the annotation processor:

GlideApp.with(fragment)
   .load(url)
  .centerCrop()
  .into(imageView);

After this change, even without the generated API/annotation processor you can access standard RequestOptions methods directly:

Glide.with(fragment)
  .load(url)
  .centerCrop()
  .into(imageView);

The generated API is still required for API extensions and to include integration libraries. Hopefully this makes it easier for users who do not include integration libraries and for developers of libraries that are currently unable to use the generated API to use Glide.

  • Add Global/Activity/Fragment scoped RequestListeners (37127f0)
  • Add a CustomTarget class to make it easier to reduce some non-essential boilerplate when implementing custom Targets. onLoadCleared still must be implemented by subclasses of CustomTarget (b3b2d7a)
  • Support loading resources from dynamic modules (#3308, b57ef34, thanks to @SUPERCILEX)
  • Add a varargs .transform() method to replace the equivalent .transforms() method (#2875, #3365, 8a26a6b, thanks to @aleien)
  • Make proguard rules consumable by users of the library (f7d8604, thanks to @rehlma)
  • Stop forcing all requests to be posted to the main thread to avoid unnecessary UI thread work and avoid delays caused by UI thread processing time for images loaded on background threads (8f1ea5c)
  • Add Animatable2Compat callbacks to GifDrawable so that users can be notified when a GIF animation with a non infinite loop count finishes (#3438, a150301, thanks to @AnwarShahriar)

Bugs

  • Fixed an issue where different types of requested resources (Bitmap vs Drawable etc) could share a cache key (cad83d2)
  • Work around an odd compiler bug creating new ArrayLists from other collections on some devices/versions of Android (#3296, 2ca790a)
  • Add Nullable/NonNull annotations to LazyHeaders.Builder (#3446, d6345fb, thanks to @r-ralph)
  • Add a transformation to rotate images (other than from EXIF) (1878585, thanks to @Gnzlt)
  • Fix a race that could lead to doing useless work in MultiModelLoader after cancellation (3c9f92f)
  • Fix a bug in SizeConfigStrategy that could lead to a returned Bitmap having an incorrect config (be51b4e)
  • Avoid classifying all images with non-0 exif orientations as having transparency to allow them to be cached as JPEGs instead of PNGs (e515f47)
  • Add a debug API that allows apps to attach a stack trace showing where a Glide request originated from. Note that this is fairly expensive and isn't meant to be used in production (114b885)
  • Fix bugs handling resource Uris that point to resources in other applications (e2df4d0)

Deprecations

  • Deprecated .transforms(), it's replaced with the identical .transform() method (8a26a6b)

Behavior Changes

  • RequestListeners for requests started on background threads can now be called on a background thread (8f1ea5c)

Breaking Changes

  • Subclasses of RequestBuilder/RequestOptions may be broken by ed20643. Typically the breakage is relatively simple to fix, but the exact methods that need to be called or that are exposed may have changed for subclasses.

Build Changes

Glide 4.8.0

16 Aug 17:10
Compare
Choose a tag to compare

Features

  • Multiple RequestListeners can be added to a single request (9328999, thanks to Adrian)
  • Added a safer version of Glide's base target methods that force callers to implement onLoadCleared and deprecated the unsafe versions. Failing to implement onLoadCleared in
    a Target can lead to UIs displaying incorrect images, runtime exceptions, or various other resource re-use errors (3a70607, thanks to azlatin@).

Bugs

  • HEIF orientation is supported on O MR1 and higher via ExifInterface (a3f8114)
  • Improved error message for network failures (#2894, ff463d7)
  • Placeholder/error/fallback drawable and id variants now replace previous calls to the same method with the other variant. For example, placeholder(Drawable) will replace previous calls to .placeholder(R.id.xyz)(2dccb5c)
  • Improved synchronization in ModelLoaderRegistry (62e6c11, thanks to @jnlopar)

Deprecations

  • Deprecated SimpleTarget and ViewTarget, see the CustomViewTarget description in Features in these release notes for more detail.

Behavior Changes

  • Requests that are started with a paused RequestManager, usually in a paused Activity or Fragment, are immediately paused so that they display a placeholder instead of nothing (a55e935)

Breaking Changes

  • The deprecated PREFER_ARGB_8888_DISALLOW_HARDWARE DecodeFormat has been removed. Use RequestOptions#disallowHardwareConfig() instead (7eb59f7)
  • Remove pause() and isPaused() from the internal Request interface (9089752)
  • Glide now uses resource ids (in CustomViewTarget) and therefore can no longer be released as a straight jar.

Build Changes

  • Added support for androidx annotations (c3328fe, thanks to @colinrtwhite)
  • Updated to Android Gradle 3.1.3.

Glide 4.7.0

10 Apr 22:21
Compare
Choose a tag to compare

Features

  • Added support for data Uris when they're provided as Uris (17c1c3d)
  • Improved scrolling performance by optimizing some Glide internal calls (7664c82, d7635bd, 7ff3bde, thanks to paulsowden@)
  • Added support for downsampling in VideoBitmapDecoder (97d130d)
  • Provide better default names for annotation generated classes (58bcf53, thanks to @SUPERCILEX)

Bugs

  • Improved handling of cancellation in VolleyStreamFetcher (a690f38)
  • Improved handling of TRIM_MEMORY_RUNNING_CRITICAL (d939314, thanks to @ygnessin)
  • Avoid delaying the first few requests started in Fragments or Activities by defaulting RequestManagers to started when the containing Activity or Fragment is started (7d1898e)
  • Fixed failures in annotation processor for classes with _ in the package name (99723e3, thanks to @TWiStErRob)
  • Obey themes when retrieving drawables when the appcompat support library is present (5212e95, thanks to @julianostarek)
  • Fixed a bug that could cause loading another application's launcher icon to fail if the calling application's support library version didn't match exactly (f508d7c)
  • Fixed a bug where a pixel was swapped in the output of GifDecoder (7fb8b12, thanks to @mtopolnik)

Behavior Changes

  • VideoBitmapDecoder will now obey DownsampleStrategy (97d130d)
  • Preload ahead the first page when using the RecyclerView or ListView preloader before the user scrolls for the first time (dd7fe18, thanks to Anton111111)

Breaking Changes

Build Changes

Glide 4.6.1

02 Feb 15:42
Compare
Choose a tag to compare

This is a bugfix release of Glide 4.6.0

Bugs

Fixes an issue where pom files in the 4.6.0 release did not list the appropriate dependencies for Glide's various components (#2863)

Glide 4.6.0

01 Feb 16:59
Compare
Choose a tag to compare

This is the January release of Glide.

Features

  • Use buffered streams when writing Bitmap data (860f7d0)
  • Allow re-using ARGB_8888 and RGBA_F16 Bitmaps via re-configuration (2cd953c, 17e0943)

Bugs

  • Return the correct size of RGBA_F16 Bitmaps in Util.getBitmapByteSize to avoid obtaining incorrectly sized Bitmaps for re-use in Downsampler (a198ef6)
  • Avoid converting RGBA_F16 Bitmaps to ARGB_8888 when running transformations that add transparent pixels (73277df)
  • Avoid an exception when loading remote images that aren't yet in the cache as Files with DiskCacheStrategy.AUTOMATIC (0917ef3, #2824)
  • Avoid inefficiently trying identical parts of load paths multiple times (9d3a6ff, thanks to paulsowden@)

Behavior Changes

  • Wide gamut PNGs that were decoded as RGBA_F16 even when BitmapFactory’s inConfig was set to ARGB_8888 may be affected by improved handling of RGBA_F16 when decoding and transforming images. If you see any issues decoding or transforming PNGs on Android O or higher, please file an issue so we can investigate.

Breaking Changes

  • Added correct Nullable annotations to all generated classes (35f6a0a, thanks to @SUPERCILEX)
  • Added correct Nullable annotations to RequestManager and other manager classes (bfa237c, thanks to @SUPERCILEX)
  • Add Nullable annotations to the load package (e9f682f, thanks to @SUPERCILEX)

Build Changes

  • Cut build times for Glide by around a factor of two by parallelizing static analysis and unit test tasks on the main library package and removing the redundant release variants across all modules (3968ccb, 1c7434a, 3af80f4, 95637cf)

Glide 4.5.0

05 Jan 18:53
Compare
Choose a tag to compare

This is the December release of Glide.

Features

  • Add an API to pause all requests for a given Activity or Fragment to allow callers to manually reduce memory when their Fragment or Application is backgrounded (@kurtisnelson, 09e33a2)
  • Fully support Bitmap re-use for RGBA_F16 Bitmaps. Previously Glide supported decoding RGBA_F16 Bitmaps, but would not re-use any stored in the BitmapPool when doing so (cc0288c)
  • Support decoding Videos from resources as AssetFileDescriptors (6e9866b)
  • Added support for the MediaMetadataRetriever#getScaledFrameAtTime method added in OMR1 to marginally reduce memory usage when decoding video frames (ded8f77)
  • Support transcoding BitmapDrawables to byte[]s (015d265)

Bugs

  • Cleaned up old and incorrect @TargetApi annoatations (@SUPERCILEX, 6778396)
  • Added @Nullable and @NonNull annotations to many of Glide's APIs (@SUPERCILEX, dc12b60, c3dafde, 0cffd1d, f541b65, 36e0b80, 650bb77, bd2f215, e35a73b, f37ced1, bb96b63, 276d4ff, c310780, )
  • Fixed a case where restarting an identical request with skipMemoryCache(true) would complete the load from the memory cache (#2663, 3dc1d18)
  • Fixed decoding interlaced and downsampled GIFs as static images (#2698, b64f23d)
  • Added more models to the list of devices requiring a lock when decoding or drawing Bitmaps (@strooooke, #738, c809f7e, e923554)
  • Fixed a race condition where starting multiple loads simultaneously the first time any request is made for a given model and resource could lead to NPEs (#2708, d427cbd)
  • Make the annotation processor tests pass on Windows (@SUPERCILEX, #2709, 2b4be8b)
  • Fix NPE and RuntimeExceptions thrown in DefaultConnectivityMonitor on some devices (c902730)
  • Only trim to half of the memory cache maximum size, not the current size, when background the app (@kurtisnelson, 429b7e2)
  • Fix a StateVerifier exception thrown when ResourceEncoder implementations unexpectedly throw exceptions while writing resources to Glide's disk cache (6c7cf3f)
  • Fix an NPE error message when ResourceDrawableDecoder fails to decode an image (d522ac7)
  • Fix an IllegalStateException if a request using .error() is cleared while the error request is running (#2767, 9c70aa5)
  • Cleaned up a number of accessor classes generated by unnecessarily strict visibility in inner classes (@TWiStErRob, e029694)
  • Updated OkHttp and removed a no longer necessary workaround for ClassCastExceptions thrown by the Android framework on O (#2355, 642b2dc)
  • Added missing annotations to overrides on some of Glide's generated classes (@TWiStErRob, 62d7464, 9fde006, d7bb6f9)
  • Avoid throwing exceptions when LruBitmapPool was asked to provide Bitmaps with a null config (c1036c1)

Behavior Changes

  • Default to aar packaging in POMs, so @aar should no longer be required to avoid warnings about jars depending on aars (06ba344)
  • Default active resource retention to false (73759b9), but leave the option in GlideBuilder to manually enable it. Enabling active resource retention can lead to recycled Bitmap errors or Bitmap re-use bugs if applications call Bitmap.recycle() on any images loaded by Glide or mutate the contents of Bitmaps loaded by Glide.
  • Treat devices with API < 19 as having ActivityManager.isLowRam set to true (#2650, b221d4b)

Breaking Changes

  • Removed deprecated constructors requiring Contexts in most of Glide's default Transformation (23975d9, 733b2e0, 9bedc2b, 55594ba, d8f6224, d840533, 2f76842, 144ac53, 150ebab, 92d761d, a6f1b1c)
  • The @NonNull and @Nullable annotations added in this release may break builds that depend on compiler plugins that do static nullability analysis, typically due a lack of annotations on any implemenations you might have of Glide's interfaces.

Deprecations

Build Changes