smrendererv3/SMCode/SM.Base/Drawing/DrawingBasis.cs
Michel Fedde 2aa12f8d25 27.09.2020
~ Moved Default-Shader to 2D to provied 2D-specific feature
~ Fixed UVs in Polygon
2020-09-27 11:58:14 +02:00

30 lines
No EOL
796 B
C#

using SM.Base.Contexts;
using SM.Base.Objects.Static;
using SM.OGL.Mesh;
namespace SM.Base.Scene
{
public abstract class DrawingBasis : IShowItem
{
protected Material _material = new Material();
protected GenericMesh _mesh = Defaults.DefaultMesh;
public virtual void Update(UpdateContext context)
{
}
public virtual void Draw(DrawContext context)
{ }
protected void ApplyContext(ref DrawContext context)
{
context.Material = _material;
context.Mesh = _mesh;
}
}
public abstract class DrawingBasis<TTransformation> : DrawingBasis
where TTransformation : GenericTransformation, new()
{
public TTransformation Transform = new TTransformation();
}
}