Merge two UIImages

后端 未结 2 2078
醉酒成梦
醉酒成梦 2021-02-08 05:48

I have imageA (taken from the users iPhone camera) and imageB, an image with a silly boarder (for eg) with plenty of transparent alpha space.

What I would like to to do

2条回答
  •  忘了有多久
    2021-02-08 06:05

    That code looks correct (though I would recommend converting it to use a created CGBitmapContext for thread-safety), but is imageB supposed to be a JPEG? JPEGs don't support transparency, so, in order for the blending to work, it should really be a PNG.

提交回复
热议问题