SDWebImage

Asynchronous image downloader with cache support as a UIImageView category

MIT License

Stars
24.9K
Committers
321

Bot releases are visible (Hide)

SDWebImage - 5.0.0-beta6 - 5.0 Final Beta

Published by dreampiggy over 5 years ago

Fixes

  • Fix the issue that SDWebImagePrefetch in 5.x, will submit all prefetch URLs to manager without any concurrent limit #2631
  • Fix the current transformer cache key generating rules, try to keep the image file extension #2635

Project

  • Move some internal classes into private header files, make it easy to maintain the code #2634
SDWebImage - 4.4.6 - Fix CocoaPods 1.6.0 && WebP issue

Published by dreampiggy over 5 years ago

Fixes

  • Fix the unused user header search path warning for CocoaPods 1.6.0. #2622
  • Fix that WebP with custom ICC Profile will randomly crash, because CGColorSpaceCreateWithICCProfile does not copy the ICC data pointer #2621
  • Fix the issue when WebP contains the ICC Profile with colorSpace other than RGB, which cause the CGImageCreate failed #2627

Project

  • Update the libwebp dependency to support using 1.0 version and above #2625

Performances

  • Nil imageData before decode process to free memory #2624
SDWebImage - Customizable SDWebImage - beta5

Published by dreampiggy over 5 years ago

Fixes

  • Fix encoding options does not works #2602
  • Remove unnecessary CGImage check when encode first frame #2609
SDWebImage - 4.4.5 - Fix modular framework

Published by dreampiggy over 5 years ago

Fixes

  • Revert the modular framework, try to fix some user's install issue when using SDWebImage in prefix header #2604
  • Fix wrong decompression scale calculation #2608
  • Fix shouldDecode check when image format is GIF #2606
  • Fix modify data pointer if webp image scaled down #2607
SDWebImage - Customizable SDWebImage - beta4

Published by dreampiggy over 5 years ago

Features

  • Expose the graphics helper method for coder plugin author and fix scale issue #2523

Performances

  • Decrease animated decode times when cache enable #2468
  • Remove kCGImageSourceShouldCache option when creating image source #2472
  • Add autoreleasepool to release autorelease objects in advance when using GCD #2474

Fixes

  • Add protect when custom animated image class image data is nil during progressive animation check #2466
  • Fix background download #2500

Project

  • Merged targets + MapKit dedicated target for Carthage installs #2476. Carthage user now does not enable MapKit support by default.
  • Upgrade Xcode 10 + using xcconfig for project settings #2494

Notable Changes (from beta3)

Behavior:

  • Move webp component (and libwebp dependency) to SDWebImage/SDWebImageWebPCoder #2469. Any user who use WebP in 5.0.0 should add SDWebImageWebPCoder to your Podfile or Cartfile instead.
  • Refactory cache path about namespace && final cache directory #2535. Now the default disk cache path was moved to suitable path with the namespace.
  • Use the memory bytes size, instead of pixel size to calculate the memory cost function #2568. Now the memory cost function use bytes size instead of pixels count.

Swift Only:

  • Fix the accident changes of Swift API naming for sd_imageDataAsFormat: #2517

You can always check 5.0 migration guide for the latest information for these changes.

SDWebImage - 4.4.4 - 4.4 patch

Published by dreampiggy over 5 years ago

Fixes

  • Fix memory cache image cost miscalculation for 4.x #2486
  • Fix background download for 4.x #2570
  • Fix race condition for creation of download operation when isCancelled is YES but isFinished is NO #2574
  • Fix the current image cost (pixels) for FLAnimatedImage #2558
  • Fix the FLAnimatedImage compatible code issue by introduce a private API #2588
  • Fix that WebP image with ICC Profile does not show color correctly, should use the profile colorspace instead of device colorspace #2585
  • Fix potential memory leaks for ICCP && optimize ICCP handler #2596
  • Fix that WebP decoder in master branch, does not consider the global shouldDecompressImages config and always do pre-draw for static WebP images #2592
  • Fix rare crash when NSMapTable empty keys #2556
  • Retain operation when post download related notifications (Hopefully fix, but if you face crash, please open a issue) #2576

Performances

  • Prioritize SDWebImageDownloaderHighPriority if operation already exists #2575

Project

  • Let SD can be imported using static library by CocoaPods using DEFINES_MODULE #2549
SDWebImage - 4.4.3 - 4.4 patch

Published by dreampiggy almost 6 years ago

See all tickets marked for the 4.4.3 release

Fixes

  • Revert the hack code for FLAnimatedImage, because of the FLAnimatedImage initializer method blocks the main queue #2441
  • Fix extention long length of file name #2516 6c6d848
  • Fix resource key invalid when clean cached disk file #2463
  • Fix the test case testFLAnimatedImageViewSetImageWithURL because of remote resource is not available #2450
  • Add default HTTP User-Agent for specific system #2409
  • Add SDImageFormatHEIF represent mif1 && msf1 brands #2423
  • remove addProgressCallback, add createDownloaderOperationWithUrl #2336
  • Fix the bug when FLAnimatedImageView firstly show one EXIF rotation JPEG UIImage, later animated GIF FLAnimatedImage will also be rotated #2406
  • Replace SDWebImageDownloaderOperation with NSOperation<SDWebImageDownloaderOperationInterface> to make generic #2397
  • Fix wrong image cache type when disk and memory cache missed #2529
  • Fix FLAnimatedImage version check issue for custom property optimalFrameCacheSize && predrawingEnabled #2543

Performances

  • Add autoreleasepool to release autorelease objects in advance when using GCD for 4.x #2475
  • Optimize when scale = 1 #2520

Docs

  • Updated URLs after project was transfered to SDWebImage organization #2510 f9d05d9
  • Tidy up spacing for README.md #2511
  • Remove versioneye from README #2424
SDWebImage - Customizable SDWebImage - beta3

Published by bpoplauschi about 6 years ago

See all tickets marked for the 5.0.0 release

Features

  • Minimum progress interval config for SDWebImageDownloader #2415 #2437 1d8454d
  • Feature disk cache migration from 4.x #2417 #2433
  • Add SDImageFormatHEIF represent mif1 && msf1 brands #2423 (imported from 4.4.3)
  • Add default HTTP User-Agent for specific system #2409 (imported from 4.4.3)
  • Replace valueForKey with objectForKey when access NSDictionary #2399
  • Improved unit tests #2438 #2434
  • Enhanced contributing guide #2416
  • Adopt all the protocol APIs which contains getter value to use property instead, to make the API easy to use or Swift user #2452
  • Remove sd_setAnimationImagesWithURLs API, because its cause ambiguity, behave not consistently and have rare use case #2459
  • Improved SDAnimatedImage protocol with initWithData:scale:options: #2453
  • Extra args for SDSetImageBlock (added cacheType and imageURL) #2449

Fixes

  • Fix that using NS_TYPED_ENUM on SDImageFormat cause the existing Swift API (sd_UTTypeFromImageFormat) naming changed #2413
  • Fix that downloader options about image decoding is not correctly set #2414
  • Make download receive response notification only dispatch to specific observer #2426
  • Fix a race condition during progressive animation load in SDAnimatedImageView #2435
  • Fix the bug that SDWebImageContextCacheKeyFilter wrongly be used as cache serializer and cause crash #2451
  • Fix resource key invalid when clean cached disk file #2462
  • Add no expiration file support of disk cache #2461
SDWebImage - Customizable SDWebImage - beta2

Published by bpoplauschi about 6 years ago

See all tickets marked for the 5.0.0 release

Features

  • Add SDImageCoderWebImageContext coder option, which allow custom coder plugin, to receive the context option from top-level API #2405
  • Updated all existing diagrams for 5.0 release + added new ones (small detailed diagrams for the most important components) #2407

Fixes

  • Fix nullable key for sd_imageLoadOperationForKey #2389
  • Replace __bridge_transfer with __bridge when convert from CFStringRef to NSString #2392
  • Rename sd_UTTypeFromSDImageFormat to sd_UTTypeFromImageFormat #2395
  • Change SDImageFormat to use NS_TYPED_EXTENSIBLE_ENUM instead of fixed enum, to allow custom coder plugins to extend it #2400
SDWebImage - 4.4.2 - 4.4 Patch

Published by bpoplauschi over 6 years ago

See all tickets marked for the 4.4.2 release

Features

  • Cache
    • Ability to change the clear cache option SDImageCacheConfig.diskCacheExpireType #2357
    • Add option to enable or disable weak memory cache for SDImageCache via SDImageCacheConfig.shouldUseWeakMemoryCache #2379
    • Add diskImageDataForKey: sync API for SDImageCache to directly get the image data from disk #2391
  • View Category
    • Add cache control for FLAnimatedImage, this allow user to disable memory cache for associated FLAnimatedImage instance #2378
  • Category
    • Keep the information about image's original compressed format #2390

Fixes

  • View Category
    • Fix FLAnimatedImageView+WebCache delayed draw due to #2047 which is now reverted #2393
    • Check for nullable key when cancel image load operation #2386
  • Manager
    • SDWebImageManager.runningOperations type changed from Array to Set #2382
  • Coder
    • Replace __bridge_transfer with __bridge when convert from CFStringRef to NSString #2394
SDWebImage - Customizable SDWebImage - beta

Published by bpoplauschi over 6 years ago

See all tickets marked for the 5.0.0 release

Infrastructure

  • the new requirements are iOS 8.0+ and macOS 10.10+ #2147
  • Xcode 9+

Backwards incompatible changes

See the 5.0 Migration Guide for a list of comprehensive changes and the way to update your code

Features

  • Introduce SDAnimatedImageView, SDAnimatedImage and refactor the way we handle animated images #2140

  • Added APNG support via dedicated coder SDImageAPNGCoder #2149

  • Refactored SDWebImageDownloader configs, separated them into a dedicated SDWebImageDownloaderConfig object #2263

  • Refactored the way we work with the scale factor #2266

  • Created request and response modifier #2261

  • Refactor Cache Path API #2276

  • Refactor custom cache serializer & headers filter for request level #2280

  • Refactor cache - Support custom memory cache & disk cache #2282

  • Refactor cache - Support custom web cache #2278

  • Refactor - custom image loader - Supports loader protocol #2256

  • Use SDWebImageAvoidDecodeImage to allow user to control force decode feature for individual image request #2283

  • SDImageCache supports disk cache writing options. See SDImageCacheConfig diskCacheWritingOptions #2148

  • SDImageCache now uses NSData writeToFile:options:error instead of NSFileManager createFileAtPath:contents:attributes #2148

  • Moved SDImageCache maxMemoryCost and SDImageCache maxMemoryCountLimit to SDImageCacheConfig #2151

  • Added SDImageCache diskImageDataExistsWithKey: synchronous method #2151

  • Moved UIImage sd_imageLoopCount and UIImage isGIF (and renamed to sd_isAnimated) to UIImage+Metadata category, removed the outdated methods #2152

  • Move context and other type definitions to a separate header (SDWebImageDefine) to allow to be included without dependency #2188

  • Pass context arg from the top level APIs to the bottom level APIs to allow specify logic in the future #2189 d6a3e2c c24c3d3

  • Refactor the image indicator by creating SDWebImageIndicator and SDWebImageProgressIndicator protocols and two concrete classes that implement activity and progress indicators for both UIKit and AppKit #2185 46b62cf

  • Refactor the implementation of SDWebImagePrefetcher so it behaves more like a "shared instance" object, similar to other platform classes. Each instance will manage its own list of urls. #2191 1efc247 92f3d2c bc164d6

  • Refactored and enhanced the way we allow image transformations. Switched from a single delegate method to composition of SDImageTransformer #2219

  • API style refactoring - #2250

    • Use property instead of setters and getters to make the property available in Swift
    • Use class property with the correct name instead of +(instanceType)sharedInstance in singleton to make it more easy to use in Swift. The generated interface should be simple open class var shared { get }
    • Add all nullability annotation to avoid any AnyObject! implicitly unwrapped optionals (Except that null_resettable)
    • Add all Core Foundation Ownership using CF_RETURNS_RETAINED for
      Get Rule and CF_RETURNS_NOT_RETAINED for Create Rule to avoid any Unmanaged CF value
    • Change all key for Dictionary with NS_STRING_ENUM to make it easy to use in Swift with dot syntax
    • Change all global value type which represent enum with NS_TYPED_ENUM to make it easy to use in Swift with dot syntax
  • Remove the extra calculation of image orientation for ImageIO coder & Fix macOS image orientation #2271

  • Added SDWebImageError (defined as NS_ERROR_ENUM) to group all our errors together #2290

  • Added tests for macOS

  • Add the SDWebImageContextStoreCacheType context option to specify target cache type when the image is downloaded by manager and will store to cache #2360

  • Feature watchOS WKInterfaceImage with sd_setImageWithURL #2331

  • Add options to specify query cache sync/async behavior #2312

Fixes

  • SDWebImageManager loadImageWithURL:options:progress:completed: changed the completed param requirement from nullable to nonnull #2164
SDWebImage - 4.4.1 - 4.4 Patch

Published by dreampiggy over 6 years ago

Fixes

  • Coder
    • Fix that WebP (including Animated WebP) decoding issue on iOS 12 #2348 #2347
  • Downloader
    • Fix that the downloader operation may not call the completion block when requesting the same image url in race condition #2346 #2344
SDWebImage - 4.4.0 - watchOS View Category

Published by dreampiggy over 6 years ago

Features

  • View Category
    • Add the support for watchOS to use View Category method (sd_setImageWithURL:) on WKInterfaceImage #2343
    • Add optimalFrameCacheSize && predrawingEnabled options for FLAnimatedImage #2323
  • Cache
    • Add SDImageCacheScaleDownLargeImages to allow cache to scale down large images if need #2281 #2273

Improvements

  • View Category
    • Add UIViewAnimationOptionAllowUserInteraction as default options for convenient image transition #2315
  • Manager
    • Replace @synchronized with dispatch_semaphore_t in SDWebImageManager #2340

Performances

  • Coder
    • Remove the extra calculation of image orientation for ImageIO coder #2313
    • Remove the duplicated process to force decode (draw on bitmap context) in Image/IO's progressive decoding #2314
  • Common
    • Minor optimize for dispatch_queue_async_safe #2329

Fixes

  • Coder
    • Fix that force decode not works for alpha-channel images #2272 #2297
    • Fix WebP Encoding only works for RGBA8888 CGImage but not other color mode #2318
    • Fix the thread-safe issue for coders manager #2274 #2249 #1484
    • Fix the wrong declaration of NSArray generics #2260

Docs

  • Fix function storeImageDataToDisk description #2301
SDWebImage - 4.3.3 - Cache Serializer

Published by dreampiggy over 6 years ago

Features

  • Manager
    • Add cacheSerializer to allow user provide modified version of data when storing the disk cache in SDWebImageManager #2245
    • Add a delegate method to control the custom logic when blocking the failed url #2246

Improvements

  • Project
    • Enable CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF and fix warning #2242
SDWebImage - 4.3.2 - 4.3 Patch

Published by dreampiggy over 6 years ago

See all tickets marked for the 4.3.2 release

Fixes

  • Download Operation
    • Fix that iOS 8 NSURLSessionTaskPriorityHigh symbol not defined in Foundation framework and cause crash #2231 #2230

Improvements

  • Downloader
    • Follow Apple's doc, add NSOperation only after all configuration done #2232
SDWebImage - 4.3.1 - 4.3 Patch

Published by dreampiggy over 6 years ago

See all tickets marked for the 4.3.1 release

Fixes

  • Cache
    • Fix that SDImageCacheQueryDataWhenInMemory should response cacheType to memory cache when the in-memory cache hit #2218
  • Project
    • Fix the macOS wrong minimum deployment target version to 10.9 #2206

Performances

  • Download Operation
    • Decode the image in the operation level's queue instead of URLSession delegate queue #2199

Improvements

  • Coder
    • Create a subclass of NSBitmapImageRep to fix the GIF frame duration issue on macOS #2223
  • View Category
    • Expose the read write to FLAnimatedImage associate to the UIImage to allow advanced feature like placeholder #2220
  • Cache
    • Create a subclass of NSCache using a weak cache #2228
  • Download Operation
    • Improvement download operation for priority and some protect #2208
  • Project
    • Fix CLANG_WARN_OBJC_IMPLICIT_RETAIN_SELF warning #2225
SDWebImage - 4.3.0 - Image Progress & Transition

Published by dreampiggy over 6 years ago

See all tickets marked for the 4.3.0 release

Features

  • View Category
    • Add NSProgress API in sd_imageProgress property represent the image loading progress, this allow user add KVO on it for complicated logic #2172
    • Add Image Transition API in sd_imageTransition property support custom image transition after image load finished #2182
    • Add NSButton WebCache category on macOS #2183
  • Cache
    • Add query cache options for query method #2162
    • Add sync version API diskImageDataExistsWithKey and diskCacheWritingOptions #2190
  • Manager
    • Add a option SDWebImageFromCacheOnly to load the image from cache only and prevent network #2186

Fixes

  • Coder
    • Fix GIF loopCount when the GIF image has no Netscape 2.0 loop extension #2155
  • View Category
    • Fix the issue that setAnimationImagesWithURLs weak reference may dealloc before the animated images was set #2178
  • Cache
    • Fix the getSize method which use the default file manager instead of current file manager #2180
  • Manager
    • Fix the leak of runningOperations on race condition #2177
  • Downloader
    • Ensure all the session delegate completionHandler called and fix the leak when response error code below iOS 10 #2197
    • Fix dispatch_sync blocking the main queue on race condition #2184
    • Fix the thread-safe issue for headers mutable dictionary in downlaoder #2204
  • Download Operation
    • Fix that 0 pixels error should be used when width OR height is zero but not AND #2160
    • Use the synchronized to access NSURLCache and try fix the potential thread-safe problem #2174
  • Prefetcher
    • Fix the issue that prefetcher will cause stack overflow when the input urls list is huge because of recursion function call #2196

Performances

  • View Category
    • Use the associate object to store the FLAnimatedImage into memory cache, avoid blinking or UIView transition #2181

Improvements

  • Cache
    • Remove the extra memory warning notification for AutoPurgeCache #2153
  • Downloader
    • Avoid user accidentally invalidates the session used in shared downloader #2154
  • Project
    • Update the spec file to define the dependency version for libwebp #2169
SDWebImage -

Published by dreampiggy almost 7 years ago

See all tickets marked for the 4.2.3 release

Features

  • Add a public API to allow user to invalidate URLSession used in SDWebImageDownloader to avoid memory leak on non-singleton instance #2116
  • Add a SDWebImageExternalCustomManagerKey context arguments to allow user to custom image manager for UIView category #2115
  • Allow custom SDWebImageDownloaderOperation to handle HTTP redirect #2123

Fixes

  • Fix that FLAnimatedImageView blink and flash when collectionView reload #2102 #2106
  • Fix that SDWebImagePrefetcher startPrefetchingAtIndex accident crash #2110 #2111
  • Fix that Progressive WebP decoding not showing on iOS 11.2 #2130 #2131
  • Fix crash in method implementation of sd_cancelImageLoadOperationWithKey, and avoid retain of operation #2113 #2125 #2132
  • Fix Clang Static Analyzer warning for number nil check from Xcode 9.2 #2142 #2143

Improvements

  • Adopt the current requirement, change ImageIO coder's canDecodeFromHEIC to actual implementation #2146 #2138
  • When store image with no data for SDImageCache, check whether it contains alpha to use PNG or JPEG format #2136
SDWebImage - 4.2 Patch

Published by bpoplauschi almost 7 years ago

See all tickets marked for the 4.2.2 release

Features

  • Update our iOS demo to modern way, add a UIProgressView to show image download progress #2096

Fixes

  • Fix that completion block and set image block are called asynchronously for UIView+WebCache #2093 #2097 #2092
  • Fix WebP progressive decoding may do extra calculate #2095
SDWebImage - 4.2 Patch

Published by bpoplauschi almost 7 years ago

See all tickets marked for the 4.2.1 release

Features

  • Feature refactor built-in coders and support animated webp on macOS #2082 (reusable code into SDWebImageCoderHelper; SDWebImageFrame abstracts animated images frames)

Fixes

  • Fixed EXIF orientation method will crash on iOS 7 because it’s an iOS 8 above API #2082