Skip to content

适用于微信小程序一款图片主色取色器,返回rgba值。做了模块化封装,提供了简单的实例。灵感来源于 Ele-Peng/miniprogram-pallet 项目。

Notifications You must be signed in to change notification settings

JackChanel/getMainColor.js

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

getMainColor.js

  • getMainColor.js 基于 easyColor.js 封装,灵感来源于 GitHub 上 Ele-Peng/miniprogram-pallet 项目。
  • 适配于微信小程序,用于取图片主色调的工具。
  • 更新仓库地址:https://github.com/Labraff/getMainColor.js.git
  • 基本参数
  • @imgPath 图片路径
  • @res canvas上下文
  • 使用方法
  • promise回调
  • mainGetColor(res,imgPath).then((res) =>{ // do anything })

About

适用于微信小程序一款图片主色取色器,返回rgba值。做了模块化封装,提供了简单的实例。灵感来源于 Ele-Peng/miniprogram-pallet 项目。

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published