public void Begin(RenderTarget target, Material material, Matrix4x4 viewMatrix, BlendMode blendMode) { if (rendering) { throw new Exception("Must call End() before you can call Begin() again."); } rendering = true; draw.Target = target; modelMatrix = Matrix3x2.Identity; this.viewMatrix = viewMatrix; draw.Blend = true; draw.BlendMode = blendMode; currTexture = defaultTexture; draw.Material = null; SetMaterial(material ?? defaultMaterial); clipIndex = -1; draw.Clip = false; }
public void SetBlendMode(BlendMode blendMode) { Blend = true; BlendMode = blendMode; }