开发者

XNA: Dynamic content loading without Game Studio installed?

I'd like to enable my game to load content (such as a model, a jpg file, etc.) during run-time and display them.

I looked at the sample on XNA website (http://creators.xna.com/en-US/sample/winforms_series2), however this method requires Game Studio (which means Visual Studio too) installed on the client computer.

What are the approaches to loading content during run-time without VS+GS? Do I have to to avoid XNA Content Pipeline completely? If so do I have to write my own graphic import library or are there any suit开发者_开发知识库able ones for this task?

Thanks in advance!


For loading a texture you can use Texture2D.FromFile method.

As for models I don't think there is a way to load them. If you just want to load vertex and index data then loading that from a file into buffers is fairly simple. If, however, you actually want a model instance then I know of no way (other than using the content pipeline)


Doing this would require alot of tweeks, and looking into the target files, changing them, and breaking some of the rules in the EULA for XNA Gamestudio 3.1 and below. Your best bet would be to create Vertex and Index buffers, and loading your own custom file type for models.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜