1 Star 0 Fork 2

zh_eng / cordova-plugin-ImagePicker

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
克隆/下载
贡献代码
同步代码
取消
提示: 由于 Git 不支持空文件夾,创建文件夹后会生成空的 .keep 文件
Loading...
README
MIT

#cordova-plugin-ImagePicker Cordova图片多选插件

cordova-plugin-ImagePicker

非常感谢南尘banchichen 提供的源码支持 多点star✨开源不宜,谢谢。扣扣群:240255635

一个支持多选,相册实现了拍照、预览、(Android 图片压缩)等功能

功能

  • 相册目录
  • 多选图
  • 相册内部拍照
  • 预览选中的图片
  • 图片压缩(Android)

##安装要求

  • Cordova Version >=5.0
  • Cordova-Android >=4.0
  • Cordova-iOS >=6.0

##ios Requirements 要求

OS 6 or later. Requires ARC iOS6及以上系统可使用. ARC环境.

When system version is iOS6 or iOS7, Using AssetsLibrary. When system version is iOS8 or later, Using PhotoKit. 如果运行在iOS6或7系统上,用的是AssetsLibrary库获取照片资源。 如果运行在iOS8及以上系统上,用的是PhotoKit库获取照片资源。

##安装

  1. 命令行运行 cordova plugin add https://git.oschina.net/leanit/cordova-plugin-ImagePicker.git
  2. 命令行运行 cordova build --device

##android注意事项 add插件到项目以后先不要直接build,执行下面的步骤

  • 全局搜索插件android目录,将 com.your.package.name 全部替换成自己创建项目时的包名。
  • build

Android视频演示

点击查看视频(mp4格式)
点击查看视频(优酷)

ios视频演示

点击查看视频(mp4格式)
点击查看视频(优酷)

Android效果图

ios效果图

使用方式

ImagePicker.getPictures(function(result) {
    alert(result);
}, function(err) {
    alert(err);
}, { maximumImagesCount : 9, width : 720, height : 960, quality : 100 });

参数含义

配置参数 参数含义
maximumImagesCount 多选限制数量,默认为9
width 设置图片的width,默认为720
height 设置图片的height,默认为960
quality 图片质量 默认100

License

The MIT License (MIT)

MIT License Copyright (c) 2017 giantss Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

简介

Cordova图片多选插件 展开 收起
MIT
取消

发行版

暂无发行版

贡献者

全部

近期动态

加载更多
不能加载更多了
1
https://gitee.com/meepo11th/cordova-plugin-ImagePicker.git
git@gitee.com:meepo11th/cordova-plugin-ImagePicker.git
meepo11th
cordova-plugin-ImagePicker
cordova-plugin-ImagePicker
master

搜索帮助