繁体   English   中英

在C#中镜像Picturebox图像

[英]Mirroring Picturebox Image in C#

我有这样的问题。 我想得到这个结果 在此输入图像描述

我在左侧有图像,我想得到右侧所示的结果。 我有一个Picturebox ,我的问题是如何将镜像旋转到右边?
我在这个网站上看到了这个答案:

capturebox.BackgroundImage.RotateFlip(RotateFlipType.Rotate180FlipY);

但这不是正确的解决方案。 感谢帮助

您需要在PictureBox外部使用Image进行操作

 private void button1_Click(object sender, EventArgs e)
    {
        Image img = pictureBox1.Image;
        img.RotateFlip(RotateFlipType.Rotate90FlipNone);
        pictureBox1.Image = img;
    }

你在这里有一个例子

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM