这是 resized.co 的 iOS 客户端,resized.co 是一种实时图像缩放处理服务。
通过 Cocoapods
只需将其添加到您的 Podfile 中:
pod 'Resized'
//Initialize...
ResizedService *resizedService = [ResizedService serviceWithKey:YOUR_RESIZED_CO_SERVICE_KEY
secret:YOUR_RESIZED_CO_SERVICE_SECRET];
//Override host if applicable (optional)
resizedService.host = @"https://img.resized.co";
//Set the default failover image (optional)
resizedService.defaultImageURL = @"http:/www.example.com/no-image.jpg";
//Get URL for resized Image from URL
NSString *resizedImageURL = [resizedService resizeImage:IMAGE_TO_RESIZE_URL
withSize:NEW_SIZE];
MIT 许可证 (MIT)。有关更多信息,请参阅许可文件。