在 XNA 中绘制简单的圆圈 [英] Draw simple circle in XNA

查看:41
本文介绍了在 XNA 中绘制简单的圆圈的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想画一个 2d 的填充圆.我四处寻找,似乎找不到任何可以远程帮助我画圆圈的东西.我只想在画布上指定高度、宽度和位置.

I want to draw a 2d, filled, circle. I've looked everywhere and cannot seem to find anything that will even remotely help me draw a circle. I simply want to specify a height and width and location on my canvas.

有人知道怎么做吗?

谢谢!

推荐答案

XNA 通常不知道可以在其上绘画的画布.相反,您可以在您最喜欢的绘画程序中创建一个圆并将其渲染为精灵,或者在 3D 网格中创建一系列顶点来近似一个圆并进行渲染.

XNA doesn't normally have an idea of a canvas you can paint on. Instead you can either create a circle in your favorite paint program and render it as a sprite or create a series vertexes in a 3D mesh to approximate a circle and render that.

这篇关于在 XNA 中绘制简单的圆圈的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆