小编Coo*_*Cat的帖子

如何使用数组镜像图像

我需要镜像图像并像这样显示它:

在此输入图像描述

要像这样显示:

在此输入图像描述

这是我到目前为止的代码,我没有运气:

int Height = TransformedPic.GetLength(0);
int Width = TransformedPic.GetLength(1);

for (int i = 0; i < Height; i++)//loop rows
{
    for (int j = 0; j < Width; j++)//loop columns
    {
        TransformedPic[i, j] = TransformedPic[i, ((2 * Width) - (j + 1))];
    }
}
Run Code Online (Sandbox Code Playgroud)

c#

3
推荐指数
1
解决办法
613
查看次数

标签 统计

c# ×1