如何创建png图像的镜像? [英] How to Create a png image's mirror?
本文介绍了如何创建png图像的镜像?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如您所知,png可以透明显示.我想像自己一样在mirror.vertical或水平显示png.
有些身体可以帮助我吗? TKS:)
As you know,the png can display with the transparent.I want to display a png like itself in mirror.vertical or horizontal.
some body can help me? TKS :)
推荐答案
您可以尝试执行以下步骤:):
-获取图像的位图位指针
-获取位图的高度和宽度
-获取位图的每像素位(BPP)值
-在行或列上对称交换像素(sizeof(pixel)= BPP/8)
-保存修改后的图像
您可以访问CImage
类吗? :)
You could try to perform the following steps :) :
- Get the bitmap bits pointer of the image
- Get the height and width of the bitmap
- Get the bits-per-pixel ( BPP ) value of the bitmap
- Swap the pixels ( sizeof(pixel)=BPP/8 ) symmetrically on the lines or the columns
- Save the modified image
Do you have an access to theCImage
class ? :)
这篇关于如何创建png图像的镜像?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文