Allegro.cc - Online Community

Allegro.cc Forums » Off-Topic Ordeals » which library for a game

This thread is locked; no one can reply to it. rss feed Print
 1   2   3 
which library for a game
clovekx
Member #3,479
April 2003
avatar

What are the pros and cons of different libraries and programming languages for 3D game developement? My idea from what I have found is this:

---

XNA:

pros:
-easy to use
-a lot of thing already done

cons:
-only for windows
-possibly little less powerful
-bloated?

---

DirectX:

pros:
-Compared to OpenGL, a lot of things (loading models, etc.) is already in the library.

cons:
-Only Windows

---

Allegro/SDL+OpenGL:

pros:
-cross platform
-control over the resulting code

cons:
-requires a lot of programming.

---

Which library would you choose for a commercial 3D game? Why? What are other possibilities?

BAF
Member #2,981
December 2002
avatar

XNA. Windows is the only platform that matters for commercial development anyway, and you get the added bonus of being able to put it on the xbox.

blargmob
Member #8,356
February 2007
avatar

XNA. :D

---
"No amount of prayer would have produced the computers you use to spread your nonsense." Arthur Kalliokoski

clovekx
Member #3,479
April 2003
avatar

What about MAC computers? They are also getting popular today.

Can you please write some example of a modern commercial game written in XNA?

Thomas Harte
Member #33
April 2000
avatar

A major pro for OpenGL is the stable API. Beyond that I think you have the pros and cons correctly listed. There are definitely ethical issues with XNA, but do you care?

EDIT: XNA titles cannot be used on Mac computers unless the owner has also installed Windows. Macs account for 20% of US consumer sales nowadays (source).

clovekx
Member #3,479
April 2003
avatar

Quote:

There are definitely ethical issues with XNA, but do you care?

What kind of ethical issues? Probably I wouldn't care, but want to know about them.

BAF
Member #2,981
December 2002
avatar

Mac is only a marginally larger gaming market than Linux.

Thomas Harte
Member #33
April 2000
avatar

Quote:

Mac is only a marginally larger gaming market than Linux.

I disagree. I think the Mac OS has now transcended the techie niche that it picked up by going all UNIX in 2001 and made a non-negligible impact into the consumer mainstream. I think that's partly why companies like EA have recently started publishing Mac games again, the other part being that it's really easy to do now that Macs run on Intel and there are some good commercial Win32 game wrappers that give you a near-instant Mac port.

From a personal point of view, I get many more Mac downloads than Windows downloads. Though that's probably more about size of market versus size of competition. I expect the iPhone projects I'm working on will do even better than anything I've released for a real computer, but I'd obviously be an idiot if I claimed there were more of them than either Macs or Windows PCs.

Quote:

What kind of ethical issues? Probably I wouldn't care, but want to know about them.

Oh, just the usual stuff about supporting proprietary technologies, plus a bit of anti-Microsoft. Prior to the ISO thing, I actually thought Microsoft had reformed, but now I'm quite sure that they are among the worst of the big faceless companies.

That won't bother you if you're making a purely technical decision though. I think the consensus on XNA is that it's really nice and good to see Microsoft making an effort to once again capture the interest of developers, having admitted that they've probably lost at least an entire coding generation.

Looking at it the other way round, Microsoft are the only corporation pouring millions of dollars into a development framework specifically for games which is free for you to download and use. Which surely is something strongly in favour of XNA if you're happy with the slightly restricted theoretical audience.

Kitty Cat
Member #2,815
October 2002
avatar

Quote:

Windows is the only platform that matters for commercial development anyway

Subjective viewpoint is subjective.

Windows may be the largest target for commercial development, but that's a far cry from being the only one that matters. Using open APIs like OpenGL will make it so it's easier to port, if you want to support other systems now or in the future. And even if you don't want to support other systems, using those same APIs will make it easier for people on other systems to run it in something like Wine (ie. more sales).

Do realize that many many people would gladly ditch Windows if the games were (competantly) ported to their OS of choice. They only stick with Windows (usually dual-booting) because people keep developing exclusively for it. It just perpetuates itself.. people use Windows because apps/games aren't being ported, and apps/games aren't being ported because people use Windows. Even if you don't want to port, using more open technologies will help break that cycle.

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

OICW
Member #4,069
November 2003
avatar

I've used XNA to quickly hack a game together. I can tell you that it's pretty easy to do something with it. I would compare it to allegro in the means of what it does for you in 2d. What I would see as a downside is managed code, that can be potentialy slower than unmanaged as far as managed Direct X goes. I've decided that if I'm going to use it, it will be only for prototyping or when I decide to do a game for XBox (which won't probably happen since consoles aren't that popular around here).

I would clearly stay out of Direct X and go fully with OpenGL. It's much easier and portable. John Carmarck said they went with it, because they didn't have to write 600 lines of code just to open up window. If you want to ease up on your programming, you can always use engines like Ogre or Irrlicht. Maybe Torque (it's not for free). But then again, you're not so free over your code.

[My website][CppReference][Pixelate][Allegators worldwide][Who's online]
"Final Fantasy XIV, I feel that anything I could say will be repeating myself, so I'm just gonna express my feelings with a strangled noise from the back of my throat. Graaarghhhh..." - Yahtzee
"Uhm... this is a.cc. Did you honestly think this thread WOULDN'T be derailed and ruined?" - BAF
"You can discuss it, you can dislike it, you can disagree with it, but that's all what you can do with it"

Trezker
Member #1,739
December 2001
avatar

XNA should work in WINE, it's just a question of time.

alethiophile
Member #9,349
December 2007
avatar

You should not write with an only-Windows API. Contrary to what people think, Windows is not the only market that matters; Mac and Linux do have a share of the pie. Supporting only one platform is a Bad Thing, especially when you ensure (by using a one-platform API) that your game can never (or only with much effort) be ported to anything else.

--
Do not meddle in the affairs of dragons, for you are crunchy and taste good with ketchup.
C++: An octopus made by nailing extra legs onto a dog.
I am the Lightning-Struck Penguin of Doom.

BAF
Member #2,981
December 2002
avatar

Quote:

Windows may be the largest target for commercial development, but that's a far cry from being the only one that matters. Using open APIs like OpenGL will make it so it's easier to port, if you want to support other systems now or in the future. And even if you don't want to support other systems, using those same APIs will make it easier for people on other systems to run it in something like Wine (ie. more sales).

Yes, but for example, not using XNA requires you to do more work to get it on xbox if you choose to do so. Most "gamers" out there aren't running Linux, therefore you have to weigh the benefit of selling a few more copies to Linux folk vs. using a framework that allows instant use on Windows and xbox.

Also, XNA is all .NET, and given Mono's success thus far, XNA shouldn't be all that hard to add layered over opengl. So in that regard, its a good choice as well.

Quote:

What I would see as a downside is managed code, that can be potentialy slower than unmanaged as far as managed Direct X goes.

Yes, but when you weigh the benefits you get from it, and the potential speed difference from you reinventing the wheel to layer similar stuff over an unmanaged language, it is beneficial. I've been writing in C++ (most C++ I've done in a while) doing this PSG project. And I do have to admit, I miss a lot of the extra syntax goodies and shortcuts you get in C#.

Quote:

XNA should work in WINE, it's just a question of time.

No it shouldn't. XNA is managed, so it would work under Mono, not Wine. :P

Quote:

Mac and Linux do have a share of the pie.

They do have a share, but is that share large enough to potentially spend extra resources on? If it costs you enough extra money to develop using open APIs that you won't recoup that cost plus an extra profit to make it worth the time, what is the point in doing it?

I'd say there are relatively few gamers on platforms like Linux and OS X, much less than that of Windows. Mac users are stereotypically naive and not afraid to spend money, so you can make some good money porting your games and selling them for a nice profit (look at the Mac ports of a few year old games that still cost $40 or $50, whereas the PC version costs $9 or so). But, how many Linux users do you see going out to buy software of any kind? Most of the time, the Linux user will pull what they want from a software repository. I'm just saying, Linux isn't a platform that is likely to be worth the hassle by the time you deal with the annoyances of distributing binaries (opensourcing your commercial game is not as feasible an option), changing APIs or writing layers so you can still keep your stuff on closed platforms with different API, and such.

Linux isn't ready for mainstream gaming, still having crappy drivers, and hard to gain market share. I don't see very many stereotypical gamers changing over to Linux just cause games are released for it. And most stereotypical Linux users aren't into games.

Johan Halmén
Member #1,550
September 2001

One Allegro pro is there's a good site with a good forum for allegro users.

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Years of thorough research have revealed that the red "x" that closes a window, really isn't red, but white on red background.

Years of thorough research have revealed that what people find beautiful about the Mandelbrot set is not the set itself, but all the rest.

Thomas Harte
Member #33
April 2000
avatar

Support for Mono in XNA has not advanced since July 2007. That's 15 months ago.

Matt Smith
Member #783
November 2000

Quote:

Windows may be the largest target for commercial development

But actually, it's all Wii, PS2, PS3 and Xbox 360. oh and DS & PSP

The PC game exists mainly as a tech demo, and as an afterthought. The local shop only has Windows games on the PC shelf tho.

Mac market? IAMRICH.exe

Thomas Harte
Member #33
April 2000
avatar

Quote:

The local shop only has Windows games on the PC shelf tho.

How closely have you looked at the boxes? EA will reputedly ship as many games as possible on dual format PC/Mac discs from now on. Though so far, I'm only aware of one (ignoring all the Sims expansion packs).

Kitty Cat
Member #2,815
October 2002
avatar

Quote:

Most "gamers" out there aren't running Linux

I said:

[A number of people] only stick with Windows (usually dual-booting) because people keep developing exclusively for it. It just perpetuates itself.. people use Windows because apps/games aren't being ported, and apps/games aren't being ported because people use Windows.

:P

Quote:

Also, XNA is all .NET, and given Mono's success thus far, XNA shouldn't be all that hard to add layered over opengl.

Come back with that argument when it works well and is nearly caught up. :P Mono just got .NET 2.0 compatibility (and AFAIK, .NET 3.0 or 3.5 has been available for a while).

Quote:

I'd say there are relatively few gamers on platforms like Linux and OS X, much less than that of Windows.

More than you'd imagine. And I can't count how many times I've heard someone say "I'd switch away from Windows if games were available."

Quote:

And most stereotypical Linux users aren't into games.

Emphasis mine. :P

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

Thomas Harte
Member #33
April 2000
avatar

Quote:

Quote:

And most stereotypical Linux users aren't into games.

Emphasis mine.

To be fair, I think most users of Linux and Windows aren't into games. I think most users of Linux are interested in web serving 24 hours a day, and most users of Windows are interested in using Outlook and Office between about 9 in the morning and about 5.30 in the evening.

I don't think anyone will dispute that, irrespective of whether that makes it relevant to someone producing games, Mac OS is the OS for with the highest proportion of users are people that personally own the machine and use it for home-based desktop activities.

If you were planning to sell your game, it may be relevant that while the Mac accounts for just 20% of US consumer sales by volume, it makes up 35% of dollar value.

ixilom
Member #7,167
April 2006
avatar

Kitty Cat said:

More than you'd imagine. And I can't count how many times I've heard someone say "I'd switch away from Windows if games were available."

Are you saying thats not a valid argument?
If said exactly as you wrote it, then yes it full of shit. There are games, heaps of them for Linux.

OTOH,
"I'd switch away from Windows if XYZ were available" (Substitute XYZ with a Windows only game/application.)
It is fairly common reason, I say that quite often.

To be honest, I haven't heard anyone say it the way you wrote. Perhaps it's just my friends who are smarter than that :P

___________________________________________
Democracy in Sweden? Not since 2008-Jun-18.
<someone> The lesbians next door bought me a rolex for my birthday.
<someone> I think they misunderstood when I said I wanna watch...

Kitty Cat
Member #2,815
October 2002
avatar

Most gamers don't consider open source games to be "real games".. they're more novelty time-wasters, if that. Sure, there are some gems (eg. Nexuiz), and there are some good commercial games (eg. UT2k4, Doom3, NWN), but it's nowhere near the level it is on Windows.

PS. And when I say "games", I mean shiney new AAA titles with omgprettygraphicsandphysics. Something gamers get hyped about and look forward to.

EDIT:
For example, can Linux users look forward to FarCry 2? What about Legendary? Or how about Diablo 3? Starcraft 2? Fallout 3?

--
"Do not meddle in the affairs of cats, for they are subtle and will pee on your computer." -- Bruce Graham

Thomas Harte
Member #33
April 2000
avatar

Quote:

EDIT:
For example, can Linux users look forward to FarCry 2? What about Legendary? Or how about Diablo 3? Starcraft 2? Fallout 3?

Continuing the little OS X side discussion that I'm enjoy with myself, quick checks reveal that Diablo 3 & Starcraft 2 have been announced for OS X, the others haven't.

montdidier
Member #10,238
September 2008

I've spent very little time looking into XNA but there is a lot about it that seems easy to use and attractive, epecially for the indie games market. It certainly lowers the cost of entry for first timers and indies, but it does lock you in somewhat.

With that caveat, what stops me from using it:

  • I'm primarily a C++ programmer and despite the benefits that C# offers am not yet motivated to learn it beyond trivial uses so far. A good engine/library I know gives me all the head start I need. I'm not convinced after the initial boost in productivity that when one gets into the nitty gritty of a complex title that XNA is going to provide that much benefit.


  • Limited to Microsoft Platform. I'm writing commercial games that can be targetted to the console, and have not yet decided I want to be microsoft specific. XNA limits me to Windows and Xbox 360, I'd quite like to be open to PSP, PS3, DS, Wii, Pandora or whatever at this point, and the business side of things will effect my decision. (All those other systems tend to be very linux like in the way they do things, if not actually based on linux, many linux based tools etc)


  • A game written with XNA will most likely lead you down the XNA publishing path which has lower royalities than a self published title going through the normal publishing route. I'm not 100% up to date with this though but it certainly used to be true. There is going to be a lot of competition in the XNA arena too, as I've already stated there is a lower barrier to entry.

Elverion
Member #6,239
September 2005
avatar

Do not use DirectX/XNA. Or else!*

*Or else you will continue to force people to stick to an OS that they do not want to use, but must, in order to do the things they like. There is absolutely no reason for it when there are great, free, well supported and open alternatives out there.

Just look at America's Army. It used to be playable on Mac, Linux, and Windows. Then they decided to use DirectX only, instead of allow the option of OpenGL. Many users hated this choice for several reasons: They could no longer play under Linux and Mac, the rendering speed slowed down dramatically, and had several new rendering bugs. And OpenGL looked FAR better (at least to me, and all of my friends to had played). They lost a huge number of players because of this.

If your reasoning for not wanting to use Allegro & OpenGL is that you have to write a lot more code, then use a library that fits exactly what you're trying to do. Irrlicht is great for 3D. It's easy to use and goes far beyond just the rendering. And Irrlicht lets you choose between DirectX (several versions) and OpenGL (as well as a few different software modes, but who actually uses those?).
http://irrlicht.sourceforge.net/features.html

--
SolarStrike Software - MicroMacro home - Automation software.

BAF
Member #2,981
December 2002
avatar

Quote:

There is absolutely no reason for it when there are great, free, well supported and open alternatives out there.

For the hobbyist game writer, maybe. But commercial game developers don't care if it is free or open, they are willing to pay. And by well supported, they don't consider web forums good support.

 1   2   3 


Go to: