Are 2D games dead?

Discussion in 'Game Development (Technical)' started by sofakng, Feb 5, 2009.

  1. vjvj

    Indie Author

    Joined:
    Sep 25, 2004
    Messages:
    1,732
    Likes Received:
    0
    Well, "trashing" may be an exaggeration but misinformation certainly isn't. In fact I think any argument that tries to compare 2D dev vs. 3D dev on a single axis scale of "difficulty" is going to run right into that problem. As I hinted at before, the difficulty curves are almost inverses of each other. So it's a bit ludicrous to declare one as being globally more difficult than the other; especially when some appear to have only taken a cursory glance at one side (it's easy to tell when someone is flat out wrong, hehehe). It's a matter of choice like you said; we all pick our poison.

    Totally agreed about what these boards are about. That's what happens when you get a bunch of old, grumpy, rebellious vets together, and I wouldn't have it any other way :) I do feel in some ways that I'm evolving into a member of the 3D police here, but until I pump out some more titles I'm afraid that graphics programming is the best way for me to contribute. Maybe that's why it's such a personal thing for me to want to see more constructive 3D discussion instead of the usual 3D sucks/shaders are hard/3D doesn't run on anything yawnfest.

    2D and 3D aren't enemies, guys. Tools in the toolbox, yadda yadda yadda. All I ask is that if 3D isn't your field of expertise, instead of regurgitating stuff you've heard, why not defer to someone who has that experience? So that guys like me don't feel useless? :D
     
  2. Andrej Vojtas

    Andrej Vojtas New Member

    Joined:
    Jan 9, 2009
    Messages:
    354
    Likes Received:
    2
    This has been an insightful topic.

    I have one very basic question. I don't come with arms I just have a desire to learn.

    How would I use shaders in a sprite based game? Let's say a game like posted in this thread, The Daemon Blade: http://www.youtube.com/watch?v=woRLv3dqaBY
     
  3. hippocoder

    Indie Author

    Joined:
    Mar 18, 2008
    Messages:
    591
    Likes Received:
    0
    It's not a sprite based game.

    Its a 3D game, using 3D hardware, presented as 2D. The "sprites" are in fact, texture mapped quads.
     
  4. Andrej Vojtas

    Andrej Vojtas New Member

    Joined:
    Jan 9, 2009
    Messages:
    354
    Likes Received:
    2
    @hippocoder: In my book what you describe is a 2D sprite based game with hardware acceleration using a graphics card. A 3D game uses three dimensional models.

    Let's say I have a full blown 3D engine and would want to make a similar game, using pre-rendered images for characters and background objects. How could I use the shaders?
    - add glow to one of the background layers?
    - water surface simulation, as the character walks knee deep in water?
    - transparent ice with refraction?
    - full screen underwater effect (animated refraction)?

    What shader generation would be required for these effects?
     
  5. Applewood

    Moderator Original Member Indie Author

    Joined:
    Jul 29, 2004
    Messages:
    3,859
    Likes Received:
    2
    It's all totally doable. If your sprites are actually just 2D quads, then for a lot of those effects you'll need some sort of height/bumpmap texture for them, but that's no biggy. The math to recreate the bumpmap normals in the shader can get a bit hairy but its documented in lots of places.

    You could probably do all those effects without using shaders tbh, but my point has always been why would you want to?. Shaders make all this stuff damned easy to code.

    Specifics for those listed effects are beyond the scope of this thread, but there's a shedload of stuff available on the web. Quite a bit of good stuff can be found in the developer sections at ATI and nVidia's main sites - samples galore.

    I tried to watch the video, but instead hit the back button after about the 9th logo came up with no content yet.
     
  6. Andrej Vojtas

    Andrej Vojtas New Member

    Joined:
    Jan 9, 2009
    Messages:
    354
    Likes Received:
    2
    @ applewood: Thank you for your answer. Yes the logos in the video at start are annoying.

    Any other ideas how to use shaders in a sprite based game?
     
  7. Applewood

    Moderator Original Member Indie Author

    Joined:
    Jul 29, 2004
    Messages:
    3,859
    Likes Received:
    2
    That's left as an exercise for the reader ;)

    Really, you can do practically anything you want, including generating their appearance procedurally from practically nothing. When I first got involved learning and writing shaders it was like a whole new vista of possibility opened up before me, and that's not melodrama - it really was like that.
     
  8. hippocoder

    Indie Author

    Joined:
    Mar 18, 2008
    Messages:
    591
    Likes Received:
    0
    It is technically impossible to use shaders with sprites. You need to use quads/3D hardware.
     
  9. Applewood

    Moderator Original Member Indie Author

    Joined:
    Jul 29, 2004
    Messages:
    3,859
    Likes Received:
    2
    Actually, it's technically impossible to use sprites on a PC at all.

    "Sprite" is a term coined by Atari for the block of memory that was rasterised onto the screen without even touching vram on their 400 and 800 8-bit models. (Wikipedia just said Atari were actually second to a machine that nobody ever bought, so I'll stand)

    It's caught on as a general word since then, so it's totally bogus to say it is or isn't a sprite based on how you're drawing it.
     
  10. PoV

    PoV
    Indie Author

    Joined:
    Jul 27, 2004
    Messages:
    2,132
    Likes Received:
    0
    Yeah, that's what've I've found myself too. I don't use shaders on the Windows/Linux port, but the software OpenGL vertex pipeline is more than fast enough... which is why I brought up the NetBook. I run the Linux port of my iPhone game on one, and I easily get 120fps when I only need 60. And everywhere I read, they say the Linux GMA 950 OpenGL drivers are noticeably slower than the XP drivers (at least the ones shipping with a stock Acer Aspire One).

    It's like people have forgotten Quake 3 runs on computers worse than the general public has had for nearly 10 years now.
     
    #90 PoV, Feb 10, 2009
    Last edited: Feb 10, 2009
  11. JGOware

    Indie Author

    Joined:
    Aug 22, 2007
    Messages:
    1,578
    Likes Received:
    0
    I ran some blitzmax (2d sprite via quads) stuff on a 300.00'ish netbook a while back and what ran at 60 on my dell laptop, 30 on my 82845G intel, was running at 12-15 on the netbook. Granted I was throwing alot of overdraw at it, but it did not seem like it was a performance demon by any means.
     
  12. hippocoder

    Indie Author

    Joined:
    Mar 18, 2008
    Messages:
    591
    Likes Received:
    0
    @ Apple: sure I know this (I'm an old timer myself) however I kinda figured he was talking about drawing to the screen using 2D hardware or the CPU (ie blitting).
     
  13. Andrej Vojtas

    Andrej Vojtas New Member

    Joined:
    Jan 9, 2009
    Messages:
    354
    Likes Received:
    2
    Ignore this.
     
    #93 Andrej Vojtas, Feb 10, 2009
    Last edited: Feb 10, 2009
  14. vjvj

    Indie Author

    Joined:
    Sep 25, 2004
    Messages:
    1,732
    Likes Received:
    0
    Like the others are saying, you can do pretty much anything you want. 99% of the time a game is rendering "accelerated sprites", the sprites are just two 3D triangles. If Muramasa is anything like their previous titles (Odin Sphere, GrimGrimoire or heck, even Princess Crown), then those sprites are most certainly accelerated triangles.

    Fun example: Distance mapping shader. Think normal mapped + parallax mapped but with correct distance calculations and occlusion. Those high-detail bricks and vent vanes and embossed text are being rendered on a sprite. If you download the demo and switch to wireframe mode, you'll see that all that detail is being rendered on two triangles:

    http://http.developer.nvidia.com/GPUGems2/gpugems2_chapter08.html
     
  15. Andrej Vojtas

    Andrej Vojtas New Member

    Joined:
    Jan 9, 2009
    Messages:
    354
    Likes Received:
    2
    @vjvj: Thanks for the tip.
     
  16. dima

    Original Member

    Joined:
    Feb 7, 2005
    Messages:
    345
    Likes Received:
    0
    Actually a "Sprite" is a type of natural lightning phenomenon which occurs in the upper atmosphere, way above normal lightning altitudes. Transient Luminous Events is proper terminology, and the red ones are referred to as Sprites - way before Atari even existed. They resemble a static picture, which comes, and fades unlike regular lightning which appears to have much more motion. Computer graphics Sprites are derived from this. Get your facts straight.

    Also I would like to throw in that 2D is easier than 3D, and always will be. To me 3D is real time meshes with lighting and texturing, 2D is a sprite or a quad with a sprite. I don't care if you use shaders and 3D pipeline, if all you do is throw textured quads around, the game is 2D. (my opinion)

    Pixel art can be harder than 3D pre-rendered, but it can be the other way too. What I would like to point out though; for real time meshes you are extremely limited by polygon counts, but for pre-rendered images can have virtually unlimited detail and complexity. It extremely hard to design 3D assets that would look as good or better than the best of 2D. I can pre-render some sprites by throwing massive amounts of detail in a 3D program, but it would take much more work and care to make the same design for real time 3D.

    Programming 3D engines is also much harder than 2D - I really don't get it when people say that 2D is harder than 3D, it CAN be, but for the same type of quality project, 2D will always be easier, from assets to programming.

    Cheers,
    Dima
     
  17. Applewood

    Moderator Original Member Indie Author

    Joined:
    Jul 29, 2004
    Messages:
    3,859
    Likes Received:
    2
    Another popular misdirection. You're not comparing apples with apples.

    Comparing something that just blits quads onto a 2D surface isn't a fair comparison with a full 3D engine. If you want me to write you an engine from scratch that only rendered .X files with one texture, no lighting and no effects, then I reckon I could do either that or a 2D library for you in a similar amount of time.

    3D isn't harder, it's just wider.

    Right now, literally, I'm taking a break from writing an arbitrary quad rotate blit for my 2D engine. I have S/T pixel centring issues that I can't seem to fix and I've been stuck on it for hours. This is moot in 3D - it's all done for me. I could've written a transform pipeline in 3D by now though.

    But, you do have a point. If someone is n00b enough to not be able to write even a basic 3D engine, I'd never recommend them to try. There's plenty of free libs out there that do it all reasonably well already, same as for 2D only with more scope.

    Only if you don't know what you're doing.
     
  18. 320x240

    320x240 New Member

    Joined:
    Sep 16, 2008
    Messages:
    165
    Likes Received:
    0
    Actually, 'sprite' is derived from the older 'spright' which is closely related to the word 'spirit', allthough 'spirit' has taken on a certain abstract meaning today, like in 'the human spirit', whereas 'sprite/spright' is also used as a collective term for supernatural beings, not unlike the German 'geist' and the Norwegian 'ånd'.
     
  19. dima

    Original Member

    Joined:
    Feb 7, 2005
    Messages:
    345
    Likes Received:
    0
    Yeah, but Sprite for computer graphics was named after the TLE lightning phenomenon, I don't know where it came from before that. And regarding Spirit, I drank some last week, 45% alcohol distilled from sugar and grain. :p

    In the end it's really about style, but from personal experience, I've had much harder time making real time 3D assets because of geometry constraints and UV mapping, where as in pre-renders I can get away with throwing more geometry for detail.

    Maybe fractal geometry will be the evolution of 3D meshes...

    But 2D vs 3D isn't apple-apple comparison to begin with. I can say that eating an apple is easier than an orange, because you don't HAVE to peel an apple, but they both have excess waste, only in oranges you waste the skin first, but with apples you throw away what's not edible in the end.
     
    #99 dima, Feb 12, 2009
    Last edited: Feb 12, 2009
  20. vjvj

    Indie Author

    Joined:
    Sep 25, 2004
    Messages:
    1,732
    Likes Received:
    0
    Come on, Man. You could have at least read *some* of the thread before responding. You're about a week behind with this "2D is indisputably easier than 3D" argument.

    2D and 3D have different difficulty curves. 2D is easier up front, but becomes a big pain in the ass as the game gets more complicated. 3D has eek-scary math and code to write up front (which is always easier than it seems to the uninitiated), but everything becomes much, much easier as the game becomes more complicated.

    Redoing the 2D characters in Meridian was one of the most complicated, fucked up problems I've had to tackle in my career. Not because Meridian's code was a mess, but because trying to solve a complex problem (character sprites with multiple swappable sprite sets for each subsection of the body) is harder to do in 2D than it is in 3D. Wanna know something else? The characters being 2D is also why we didn't upgrade the sprite art; it'd take too much time and cost too much money.

    There is no single axis to evaluate the difficulty of 2D vs. 3D on. I agree that for "graphically simple" games (for lack of a better phrase) 2D is easier, but there exists a point where resisting 3D begins to makes your life miserable. And that point is earlier than a lot of people think.

    And I'm not going to even get into this "it's hard to make 3D look as good as 2D" argument because "look good" and "hard" are totally subjective.
     

Share This Page

  • About Indie Gamer

    When the original Dexterity Forums closed in 2004, Indie Gamer was born and a diverse community has grown out of a passion for creating great games. Here you will find over 10 years of in-depth discussion on game design, the business of game development, and marketing/sales. Indie Gamer also provides a friendly place to meet up with other Developers, Artists, Composers and Writers.
  • Buy us a beer!

    Indie Gamer is delicately held together by a single poor bastard who thankfully gets help from various community volunteers. If you frequent this site or have found value in something you've learned here, help keep the site running by donating a few dollars (for beer of course)!

    Sure, I'll Buy You a Beer