public override void Render(IGraphicDevice device, float x, float y) { BoundingBox box = child.BoundingBox; Color oldColor = device.Color; device.Color = color; device.DrawFilledRectangle(y - box.Height, x, x + box.Width, y + box.Depth); device.Color = oldColor; child.Render(device, x, y); }
public override void Render(IGraphicDevice device, float x, float y) { BoundingBox box = child.BoundingBox; Color oldColor = device.Color; device.Color = color; device.DrawFilledRectangle(y - box.Height, x, x + box.Width, y + box.Depth); device.Color = oldColor; child.Render(device, x, y); }
/** * render a filled rectangle with the current color that fills * the area of the child node. Note, the context is given with * coordinates at the origin of the bounding box, so we need to * calculate the extent of that rectangle here. */ public override void Render(IGraphicDevice device, float x, float y) { BoundingBox box = child.BoundingBox; device.DrawFilledRectangle(y - box.Height, x, x + box.Width, y + box.Depth); }
/** * render a filled rectangle with the current color that fills * the area of the child node. Note, the context is given with * coordinates at the origin of the bounding box, so we need to * calculate the extent of that rectangle here. */ public override void Render(IGraphicDevice device, float x, float y) { BoundingBox box = child.BoundingBox; device.DrawFilledRectangle(y - box.Height, x, x + box.Width, y + box.Depth); }