Sign in to follow this  
Extasy88

XNA better than Managed DX?

Recommended Posts

Hi, I try to write this in english now (German is my motherlanguage) at the moment I try to learn DirectX in combination to C#. But sometimes when I'm looking around for new tutroials, I read that the most of the experienced users say it's recommend to learn XNA as beginner because Managed Direct X has no future. What are you thinking about this "problem"? I don't want to programm for the XBOX 360. Are there more possibillities in XNA, than in MDX (also in reference to performance) Thx for help

Share this post


Link to post
Share on other sites
MDX is dead. The reason you shouldn't use it isn't because you should use XNA Game Studio; it's because MDX hasn't been updated in quite some time, never will be updated again, and may contain bugs/issues that will never be fixed.

If you don't want to use XNA Game Studio for creating managed games (which works great even if you are just sticking with PC), there is SlimDX, the community-made wrapper for DirectX. It wraps DirectX 9 and 10 so you get all the new goodies while being able to write in C#.

I do want to point out that it's hardly worth disregarding XNA Game Studio solely because you don't want to make Xbox 360 games. The API is wonderful and I know of plenty of people using it solely for Windows development. Sure this means there are things in there you may not need, but on Windows it's just another .NET application; feel free to incorporate any other library or perform native interop if you find yourself missing something. But the notion that XNA Game Studio is worthless as a Windows API is simply an exaggeration, if not an out and out lie. I would recommend you at least give it a shot. You may find yourself pleasantly surprised with the framework.

Share this post


Link to post
Share on other sites
Quote:
Original post by Extasy88
I don't want to programm for the XBOX 360.


Nick is right, MDX is basically dead. I've written tutorials using XNA and just finished a game in XNA and I don't even own a 360! I solely target the Windows platform with my XNA projects (many people do).

As for performance I'm very unfamiliar with Managed DirectX, but I believe XNA has a different style of content pipeline (for art assets) and has a Garbage Collector that makes running XNA quite clean (again, compared to MDX I can't be certain).

Share this post


Link to post
Share on other sites
We've run some tests while developing SlimDX, and found that generally XNA is slightly slower than MDX. This is mostly due to the insane amount of validation and checking that goes on behind each XNA routine. Since you don't have the debug runtime going on the XBox360, all the potential errors need to be caught and thrown before XNA makes the call into unmanaged code.

Share this post


Link to post
Share on other sites
Microsoft seems to be investing alot in XNA so unless you have a reason to use MDX go with XNA.

Well I used to program with MDX and then tried XNA and it does some stuff for you than you had to manually do with MDX so in that way it is better. It saves you a bit of time and since XNA is really MDX 2.0 in disguise alot of the bugs that were around in MDX have been fixed or cleaned up.
If you are using F# or something like IronPython you will probably want to stick with out of date MDX though.

[Edited by - daviangel on August 14, 2008 5:11:25 PM]

Share this post


Link to post
Share on other sites
Quote:
Original post by daviangel
If you are using F# or something like IronPython you will have to stick with out of date MDX though.


Wrong, you can use either SlimDX or XNA. For XNA you just import the assemblies like you would a normal .NET library, but you won't have access to the content pipeline(not important on Windows) or the fancy GUI that comes with Game Studio.

Share this post


Link to post
Share on other sites
Quote:
Original post by Scet
Quote:
Original post by daviangel
If you are using F# or something like IronPython you will have to stick with out of date MDX though.


Wrong, you can use either SlimDX or XNA. For XNA you just import the assemblies like you would a normal .NET library, but you won't have access to the content pipeline(not important on Windows) or the fancy GUI that comes with Game Studio.

Okay-- should've known by now that you can't speak in absolutes around here without being corrected so I should've said "officially" supported by MS.
Technically, yeah you can use whatever you want just about with XNA per the official FAQ but you don't get some stuff like you did with MDX so that's probably why even recent video's from Microsoft show developers using F# with MDX not XNA
Maybe it's because even though MDX is deprecated i.e. "dead" now(no new updates,bug fixes,etc) it's still officially supported since some companies actually shipped commercial games using it?
Managed DirectX
Official support is in the DirectX forums. The GameDev.net DirectX forums may also be of help. This technology is still supported since its part of the DirectX 9 SDK - however there has been no active development on the API since 2005 and we do not recommend you use it for new projects unless you have no choice. Either switch to XNA Game Studio, write your own managed wrappers or use one of the community wrappers SlimDX or MD3D10. Note that these community wrappers are the only DirectX10 path available. Microsoft has no announced plans for DirectX10 managed wrappers.
:

Can I use Game Studio with VB.Net (or other languages)
Reply Quote

Short Answer:

NO - Microsoft won't give you any official support.

GS2.0 has been confirmed to work on all Visual Studio SKUs Microsoft have stated that only c# will be officially supported and only C# within VS will have the IDE enhancements for XNA GS.

GS3.0 - nothing has been announced about other language support at this time see GS3.0 FAQ

Medium Answer:

Not fully - see the Visual Studio FAQ for more details http://forums.xna.com/7263/ShowThread.aspx#7263. You can reference the libraries but you won't get starter kits, content pipeline or Xbox deployment and debugging.

Long Answer... aka if you really must try and you understand the above restrictions:

* C++/CLI
Works as long as you compile using the /safe flag (/pure is not enough)
* Visual Basic.Net
emachine has a VB.Net template for XNA 2.0
Alan Phipps is using XNA with Visual Basic 2005 - check out his blog http://www.alanphipps.com/VisualBasicdotNET-XNA.html.
See this thread for GS 2.0 templates and even content building from emachine
Visual Basic has several libraries that will not work on the Xbox e.g. the My namespace.
Chris Williams has a blog on using GS 2.0 with VB The VB XNA project
* F#
There are several people working with F# http://www.google.com/search?q=XNA+F%23
* Chrome (Pascal)
Somersault is working with a Pascal derivative called Chrome from http://www.RemObjects.com. Some information here
* LUA - see the XNUA page
* IronPython won't work on the 360 because it relies on Reflection.Emit which is not available. (This article implies otherwise but we have no evidence to understand how)

Deploying to the xbox can be performed using the .ccgame packaging command line tools which require a GS install to obtain.

Building content can be done using a C# project just for content or using command line MSBuild both of which require a GS install and cannot be done using the XNA redist.

360 potential issues

Other languages may or may not work on the 360 depending on how they compile things. The compact framework does not support all of the IL instructions that the full framework does (see http://forums.xna.com/thread/13402.aspx) so your particular compiler may produce code that will not run. Some parts of System.Reflection (reflection.emit for example) are not available on the 360 either which rules out any languages that rely on those. In addition some languages such as VB.Net come with additional libraries (e.g. the My. namespace). Since these libraries don't exist on the compact framework apps that rely on them will not run on the 360.

But this is probably why any tutorials you do see are all bias towards using C#/XNA since as you can see above that's what Microsoft is officially supporting and trying to get people to use.

[Edited by - daviangel on August 14, 2008 5:53:11 PM]

Share this post


Link to post
Share on other sites
gsa 3.0 works on visual studio (not express), so it should be language independent there. but i'll have to test that, and i can't be bothered. c# is a pretty nice language, and so i'll continue to use that anyways :)

then again, gsa 3.0 is not yet finalised.

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this