protected override void LoadContent() { spriteBatch = new SpriteBatch(graphics.GraphicsDevice); drawWrapper = new DrawWrapper(spriteBatch, GraphicsDevice); world.AllAssets.LoadAllModels(); world.DrawWrapper = drawWrapper; drawWrapper.Create(); world.Create(); }
public virtual void DrawDebug(DrawWrapper Drawing, float[,] transform) { foreach (Triangle tri in triangles) { Drawing.DrawLine(vertices[tri.v0], vertices[tri.v1], 2, Color.DarkGray, transform); Drawing.DrawLine(vertices[tri.v0], vertices[tri.v2], 2, Color.DarkGray, transform); Drawing.DrawLine(vertices[tri.v1], vertices[tri.v2], 2, Color.DarkGray, transform); } foreach (Vector3 p in vertices) { Drawing.DrawPoint(p, 2, Color.Black, transform); } }
public virtual void Draw(DrawWrapper Drawing, float[,] transform) { foreach (Triangle tri in triangles) Drawing.DrawTriangle(vertices[tri.v0], vertices[tri.v1], vertices[tri.v2], tri.FrontFaceColor, tri.BackFaceColor, transform); }