Skip to content

Commit

Permalink
add more constructors to UnlitMaterial
Browse files Browse the repository at this point in the history
  • Loading branch information
LeNitrous committed Jul 15, 2023
1 parent 94f201d commit 3313c7a
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions source/Vignette/Graphics/UnlitMaterial.cs
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,19 @@ public UnlitMaterial()
{
}

public UnlitMaterial(Texture texture)
: this(false)
{
Texture = texture;
}

public UnlitMaterial(Texture texture, Sampler sampler)
: this(false)
{
Texture = texture;
Sampler = sampler;
}

private UnlitMaterial(bool isDefault)
{
effect = Effect.From(shader, out layout, out properties);
Expand Down

0 comments on commit 3313c7a

Please sign in to comment.