{"id":13644042,"url":"https://github.com/CarGuo/FrescoUtils","last_synced_at":"2025-04-21T06:32:50.442Z","repository":{"id":107563233,"uuid":"73922132","full_name":"CarGuo/FrescoUtils","owner":"CarGuo","description":"Fresco 的封装，快速上手，图像后处理，超大图高清预览，缩小放大，双击放大等一一俱全。简书 http://www.jianshu.com/p/cd058a924288","archived":false,"fork":false,"pushed_at":"2023-01-06T10:09:40.000Z","size":10236,"stargazers_count":360,"open_issues_count":4,"forks_count":95,"subscribers_count":18,"default_branch":"master","last_synced_at":"2025-04-06T04:09:52.626Z","etag":null,"topics":["android","fresco","image","imageloader"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/CarGuo.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2016-11-16T13:20:40.000Z","updated_at":"2024-08-04T15:51:23.000Z","dependencies_parsed_at":"2023-06-08T12:15:38.536Z","dependency_job_id":null,"html_url":"https://github.com/CarGuo/FrescoUtils","commit_stats":null,"previous_names":[],"tags_count":11,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CarGuo%2FFrescoUtils","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CarGuo%2FFrescoUtils/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CarGuo%2FFrescoUtils/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/CarGuo%2FFrescoUtils/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/CarGuo","download_url":"https://codeload.github.com/CarGuo/FrescoUtils/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":250008276,"owners_count":21359956,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["android","fresco","image","imageloader"],"created_at":"2024-08-02T01:01:56.806Z","updated_at":"2025-04-21T06:32:45.433Z","avatar_url":"https://github.com/CarGuo.png","language":"Java","funding_links":[],"categories":["图片"],"sub_categories":[],"readme":"## Fresco 的封装，快速上手，图像后处理，超大图高清预览，缩小放大，双击放大等一一俱全。\n\n[![](https://jitpack.io/v/CarGuo/FrescoUtils.svg)](https://jitpack.io/#CarGuo/FrescoUtils)\n[![Build Status](https://travis-ci.org/CarGuo/FrescoUtils.svg?branch=master)](https://travis-ci.org/CarGuo/FrescoUtils)\n\n### [新 GSYImageLoader 图片加载工具，集成Glide、Picasso、Fresco的图片加载管理器](https://github.com/CarGuo/GSYImageLoader)\n\n## 依赖\n\n#### 在project下的build.gradle添加\n```\nallprojects {\n\trepositories {\n\t\t...\n\t\tmaven { url 'https://jitpack.io' }\n\t}\n}\n```\n#### 在module下的build.gradle添加\n```\ndependencies {\n   implementation \"com.github.CarGuo:FrescoUtils:c39608c9b2\"\n}\n\n```\n\n-----------------------------\n\n####  1.2.1\n\nupdate fresco to 1.8.0\n\n\n####  1.1.0\n\nupdate fresco to 1.7.1\n\nupdate subsampling-scale-image-view to 3.9.0\n\nupdate photodraweeview to 1.1.3\n\nupdate gradle to 4.0.1\n\n#### 1.0.8\n\nupdate fresco to 1.5.0\n\n\n#### 1.0.7 增加option配置方法；\n\n```\n/**\n * @param imageView  图片加载控件\n * @param loadOption 加载配置构造器\n */\npublic static void loadFrescoImage(FrescoImageView imageView, LoadOption loadOption) \n```\n\n* 1.0.6 update fresco to 1.3.0；\n\n* 1.0.5 update fresco to 1.2.0；移除无用依赖；\n\n* 1.0.4 update fresco to 1.0.1，update scaleImage to 3.6.0\n\n* 1.0.3 update fresco to 1.0.0\n\n* 1.0.2 最低API调整到15\n\n* 1.0.1 增加了额FrescoHelper直接超大图加载接口\n\n```\n/**\n * 超大图片的就接口\n *\n * @param context   上下玩\n * @param imageView 图片加载控件\n * @param imageUri  图片地址\n * @param defaultId 默认失败图片\n */\npublic static void loadBigImage(final Context context, final SubsamplingScaleImageView imageView, String imageUri, final int defaultId)\n```\n\n\u003ch4\u003e\u003ca href=\"http://www.jianshu.com/p/cd058a924288\"\u003e简书入口 这里有详细介绍\u003c/a\u003e\u003c/h4\u003e\n\n## 效果显示\n\u003cimg src=\"https://github.com/CarGuo/FrescoUtils/blob/master/01.jpg\" width=\"240px\" height=\"426px\"/\u003e\n\u003cimg src=\"https://github.com/CarGuo/FrescoUtils/blob/master/02.jpg\" width=\"240px\" height=\"426px\"/\u003e\n\u003cp\u003e\u003c/p\u003e\n\n\n### 动态图效果\n\n\n\u003cimg src=\"https://github.com/CarGuo/FrescoUtils/blob/master/01.gif\" width=\"240px\" height=\"426px\"/\u003e\n\u003cimg src=\"https://github.com/CarGuo/FrescoUtils/blob/master/02.gif\" width=\"240px\" height=\"426px\"/\u003e\n\u003cp\u003e\u003c/p\u003e\n\n### 记得记得在Application里初始化\n\n```\nImagePipelineConfig config = ImagePipelineConfig.newBuilder(this)\n        .setDownsampleEnabled(true)\n        .build();\nFresco.initialize(this, config);\n\n```\n\n### FrescoHelper 封装了针对  \u003ca href=\"https://github.com/HomHomLin/FrescoImageView\"\u003eFrescoImageView\u003c/a\u003e 的工具类，直接使用FrescoImageView作为ImageView使用即可。\n\n封装了多种类型，这是最全的一种\n```\n\n/**\n * @param imageView     图片加载控件\n * @param uri           路径或者URL\n * @param defaultImg    默认图片\n * @param cornerRadius  弧形角度\n * @param isCircle      是否为圆\n * @param loadLocalPath 是否本地资源,如果显示R.drawable.xxx,Path可以为null,前提isCircle为true\n * @param isAnima       是否显示GIF动画\n * @param size          是否再编码\n * @param postprocessor 图像显示处理\n */\npublic static void loadFrescoImage(FrescoImageView imageView, String uri, int defaultImg,\n                                   int cornerRadius, boolean isCircle, boolean loadLocalPath, boolean isAnima,\n                                   Point size, Postprocessor postprocessor) {\n    init(imageView, cornerRadius, isCircle, isAnima, size, postprocessor);\n    if (loadLocalPath) {\n        imageView.loadLocalImage(uri, defaultImg);\n    } else {\n        imageView.loadView(uri, defaultImg);\n    }\n}\n\n···\n\nFrescoHelper.loadFrescoImage(frescoImageView, recyclerDataModel.getUrl(), R.mipmap.ic_launcher, 2, false, recyclerDataModel.getSize(), new BlurPostprocessor(context, 10));\n\n\n```\n\n### 带有\u003ca href=\"https://github.com/wasabeef/fresco-processors\"\u003efresco-processors\u003c/a\u003e各种处理特效，高斯，五角形等。\n\n\u003cimg src=\"https://github.com/wasabeef/fresco-processors/raw/master/art/demo.gif\" width=\"240px\" height=\"426px\"/\u003e\n\n\n### 带有\u003ca href=\"https://github.com/davemorrissey/subsampling-scale-image-view\"\u003esubsampling-scale-image-view\u003c/a\u003e实现超高清图片超长图片不模糊显示。\n\n\u003cimg src=\"https://github.com/CarGuo/FrescoUtils/blob/master/01.gif\" width=\"240px\" height=\"426px\"/\u003e\n\n### 带有\u003ca href=\"https://github.com/ongakuer/PhotoDraweeView\"\u003ePhotoDraweeView\u003c/a\u003e 功能与PhotoView一样，支持双击放大，单击返回，手动放大与缩小等。\n\n\u003cimg src=\"https://github.com/ongakuer/PhotoDraweeView/raw/master/screenshot.gif\" width=\"240px\" height=\"426px\"/\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCarGuo%2FFrescoUtils","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FCarGuo%2FFrescoUtils","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FCarGuo%2FFrescoUtils/lists"}