2024-07-26 20:49:10 +05:00

24 lines
602 B
C#

namespace SoulstormReplayReader.Core.Models;
/// <summary>
/// Native dow rgd image consists of bgra pixels
/// </summary>
public sealed class ReplayImage
{
public string Name { get; set; }
public int Width { get; private set; }
public int Height { get; private set; }
public ReplayColor[] Bitmap { get; private set; }
public void Init(int width, int height)
{
Width = width;
Height = height;
Bitmap = new ReplayColor[height * width];
}
public void SetPixel(int x, int y, ReplayColor color)
{
Bitmap[y * Width + x] = color;
}
}