| Index: components/favicon_base/select_favicon_frames.h
|
| diff --git a/components/favicon_base/select_favicon_frames.h b/components/favicon_base/select_favicon_frames.h
|
| index 597a8f195e5bfbf46f9549a434a56e89889af689..92953ecec2d68057bc938547fc81f35fd489e3e1 100644
|
| --- a/components/favicon_base/select_favicon_frames.h
|
| +++ b/components/favicon_base/select_favicon_frames.h
|
| @@ -21,14 +21,14 @@ class Size;
|
| extern const float kSelectFaviconFramesInvalidScore;
|
|
|
| // Takes a list of all bitmaps found in a .ico file, and creates an
|
| -// ImageSkia that's |desired_size| x |desired_size| DIP big. This
|
| +// ImageSkia that's |desired_size_in_dip| x |desired_size_in_dip| big. This
|
| // function adds a representation at every desired scale factor.
|
| -// If |desired_size| is 0, the largest bitmap is returned unmodified.
|
| +// If |desired_size_in_dip| is 0, the largest bitmap is returned unmodified.
|
| // |original_sizes| are the original sizes of the bitmaps. (For instance,
|
| // WebContents::DownloadImage() does resampling if it is passed a max size.)
|
| // If score is non-NULL, it receives a score between 0 (bad) and 1 (good)
|
| // that describes how well |bitmaps| were able to produce an image at
|
| -// |desired_size| for |scale_factors|.
|
| +// |desired_size_in_dip| for |scale_factors|.
|
| // The score is arbitrary, but it's best for exact size matches,
|
| // and gets worse the more resampling needs to happen.
|
| // If the resampling algorithm is modified, the resampling done in
|
| @@ -38,24 +38,22 @@ gfx::ImageSkia SelectFaviconFrames(
|
| const std::vector<SkBitmap>& bitmaps,
|
| const std::vector<gfx::Size>& original_sizes,
|
| const std::vector<ui::ScaleFactor>& scale_factors,
|
| - int desired_size,
|
| + int desired_size_in_dip,
|
| float* score);
|
|
|
| // Takes a list of the pixel sizes of a favicon's favicon bitmaps and returns
|
| -// the indices of the best sizes to use to create an ImageSkia that's
|
| -// |desired_size| x |desired_size| DIP big. If |desired_size| is 0, the index
|
| -// of the largest size is returned. If score is non-NULL, it receives a score
|
| -// between 0 (bad) and 1 (good) that describes how well the bitmap data with
|
| -// the sizes at |best_indices| will produce an image of |desired_size| DIP for
|
| -// |scale_factors|. The score is arbitrary, but it's best for exact size
|
| +// the indices of the best sizes to use to create an ImageSkia with
|
| +// ImageSkiaReps with edge sizes |desired_sizes|. If '0' is one of
|
| +// |desired_sizes|, the index of the largest size is returned. If |score| is
|
| +// non-NULL, |score| is set to a value between 0 (bad) and 1 (good) that
|
| +// describes how well the bitmap data with the sizes at |best_indices| will
|
| +// produce the ImageSkia. The score is arbitrary, but it's best for exact
|
| // matches, and gets worse the more resampling needs to happen.
|
| -// TODO(pkotwicz): Remove need to pass in |scale_factors|.
|
| // TODO(pkotwicz): Remove callers of this method for which |frame_pixel_sizes|
|
| // are the sizes of the favicon bitmaps after they were resized.
|
| void SelectFaviconFrameIndices(
|
| const std::vector<gfx::Size>& frame_pixel_sizes,
|
| - const std::vector<ui::ScaleFactor>& scale_factors,
|
| - int desired_size,
|
| + const std::vector<int>& desired_sizes,
|
| std::vector<size_t>* best_indices,
|
| float* score);
|
|
|
|
|