UIImageView_FaceAwareFill for iOS

This category applies Aspect Fill content mode to an image and if faces are detected it centers them instead of centring the image just by its geometrical center.

INSTALLATION: FaceAwareFill is available through CocoaPods, to install it simply add the following line to your Podfile: pod "FaceAwareFill"

USAGE: Import the category to your .m file or to your "prefix" file.

#import "UIImageView+UIImageView_FaceAwareFill.h"

Then AFTER setting the image property of a UIImageView do:

[imageView faceAwareFill];

That's all.

Sponsored with ❤️ by Instabug
Instabug: Understand how your app is doing with real-time contextual insights from your users
Instabug

Get all the logs you need and fix bugs, crashes, and other issues in minutes instead of days. With Instabug you will automatically receive device data, network logs, and reproduction steps with every bug and crash report. It only takes a line of code to integrate and is perfect for teams that are now working remotely. See more detailed features comparison and try Instabug for free here.