Files
stgsharp/源代码/StgSharpDebug/Graphics/TextureImage.cs
T
2024-06-10 15:12:08 +08:00

33 lines
614 B
C#

using StgSharp.Math;
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
using System.Text;
namespace StgSharp.Graphics
{
public class TextureImage : IImageProvider
{
private Image _tex;
private vec2d[] _texCoord;
Image IImageProvider.ProvideImage()
{
return _tex;
}
public TextureImage(Image image, vec2d[] coord)
{
_tex = image;
_texCoord = coord;
}
public ref vec2d this[int index]
{
get => ref _texCoord[index];
}
}
}