SDWebImage / SDWebImage/SDWebImageWebPCoder
Frames loading
まだ誰も着手していません。
- 主要言語
- Objective-C
- スター
- 277
- フォーク
- 101
- PR マージ指標
- 30日以内にマージされた PR はありません
説明
Hello, I'm trying to use animated webp images as cells for collection view and it works nice on new devices, but on devices like iPhone 7 I have such an issue: on first appearing of cell the loading of images is freezed, and scrolling is not (I can scroll the collection without freezes, so it is not main thread lock). There are approximately 50 cells of images, and they loads by frame. After some time (I guess when all frames of images are passed) all cells begin to animate correctly (after closing and reopening the screen too). Looks like it is something connected with caching. All webp-s are local files, so it is not network loading. Am doing something wrong? Here is the code:
SDWebImageManager.shared.optionsProcessor = SDWebImageOptionsProcessor { _, options, context in
var mutableOptions = options
mutableOptions.insert([.retryFailed, .highPriority/*, .preloadAllFrames*/]) // no efffect on frames loading
return SDWebImageOptionsResult(options: mutableOptions, context: context)
}
SDImageCodersManager.shared.addCoder(SDImageWebPCoder.shared)
SDWebImageDownloader.shared.setValue("image/webp,image/*,*/*;q=0.8", forHTTPHeaderField: "Accept")
...
var stickerImageView = SDAnimatedImageView(frame: .zero)
// stickerImageView.shouldIncrementalLoad = true // no efffect on frames loading
stickerImageView.sd_imageTransition = .fade(duration: 0.3)
...
stickerImageView.sd_setImage(with: url, placeholderImage: placeholder)
コントリビューションガイド
このリポジトリのコントリビューションガイドは索引されていません
はじめの一歩
- issue を最後まで読み、次にプロジェクトのコントリビューションガイドを読みます。
- 着手することを issue にコメントします — 二人が同じ作業をするのを防げます。
- リポジトリをフォークし、ブランチを切って変更します。
- issue 番号を参照したプルリクエストを送ります。
調査の方向性
まず、古い iOS デバイスまたは同等の環境で、SDAnimatedImageView、SDWebImageManager、SDImageCodersManager を使用して、アニメーション WebP のコレクションビューのケースを再現します。ローカル画像が処理またはキャッシュされた後の、初回表示とその後のアニメーションを比較します。約 50 個のローカルなアニメーション WebP セルが、報告されている初期フリーズなしに正しく読み込みとアニメーションを開始すれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- ios, objective-c, swift
- 領域
- mobile, performance
- issue の種類
- バグ
- 難易度
- 4/5
- 見積もり時間
- 3〜5日
- 活発さ
- 停滞
- 明瞭さ
- 説明が足りない
- 初心者へのやさしさ
- 35/100