Mask and crop an image

Masking an image enables a developer to create images with irregular shapes dynamically. Masking is often used to create a user interface that is more compelling and less boring.

Take for example the following example …



Following code is copy/paste into your “viewcontroller.h” file

Following Code copy/paste into “viewcontroller.m” file

  • Following method is use for the mask the image.
  • Following method is use for Cropping the image for a perticular size.
  • Calling the method of maskimage.

  • Calling the method of cropping the image.



Grab the source code here.

Leave a Reply

Your email address will not be published. Required fields are marked *

5 × = thirty five


You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code class="" title="" data-url=""> <del datetime=""> <em> <i> <q cite=""> <s> <strike> <strong> <pre class="" title="" data-url=""> <span class="" title="" data-url="">