Sign in to follow this  

2D Graphics: DirectDraw or Graphics g?

This topic is 4746 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm working on a 2D isometric tile-based turn-based game in java. This is a big step for me since my last project was Pong. I have noticed that the TBS game calls for a lot more animation. I don't know if I will be able to do things like the movement of characters, the animating of attacks, and the smooth movement of menu pointers with just Graphics g. Should I instead learn DirectDraw and use that, or perhaps some other 2D API? Or should Graphics g be enough to do what I want? Thanks!

Share this post


Link to post
Share on other sites
My experiance with java has been strictly with with command prompt and GUI programes(i.e non games) but if DirecDraw is as easy peasy with java as it is with C# go DirectDraw.... ok its no longer supported(every ones doing 2D in 3D now) but with the right book or web guide you'll have sprites dancing round on screen within an hour.

Share this post


Link to post
Share on other sites
DirectDraw, all the way. Its fast, its easy, and it leads into 3D

BTW, when the previous poster says "not supported", it just means microsoft wont be updating it (like it needs it anyway). It will ALWAYS still work, because microsoft have to support backwards compatability.

Plus, if you ever want to become a professional, id use the directX way.

Share this post


Link to post
Share on other sites
I would not reccomend DirectDraw, if you want to find out what it is just go ahead, but DirectDraw is very limited to the amount of work it could do - drawimages for example, if you wan't to draw a line you have to make this function yourself, direct3d would be the best way. But most of all it depends on what you want to achieve.

Share this post


Link to post
Share on other sites
Quote:
Original post by DMINATOR
I would not reccomend DirectDraw, if you want to find out what it is just go ahead, but DirectDraw is very limited to the amount of work it could do - drawimages for example, if you wan't to draw a line you have to make this function yourself, direct3d would be the best way. But most of all it depends on what you want to achieve.


Not to seam offensive, but while DD is more complex, alot of that stuff (such as line drawing), is actually not that hard to do, and besides, direct3D is damn hard without some knowlege of DD.

Share this post


Link to post
Share on other sites
I wouldnt say D3D is hard without DD knowledge i started off doing D3D months before i decided to pick up DD.
I chose DD because i wanted a simple 2D tile engine and mucking around with all the extra bumf in D3D to do it was like using a sledge hammer to crack a nut.
DD is simple & your end users wont need 3D capable hardware to use it.
DD is not without its merrits i think its ignorant to dismiss it just because microsoft say it defunct when it still does the job it was intended for as good as it ever did.

DD also gives you an insight of how some 2D work is done accross platforms. I did a little program for the GP32 a while back and it used the draw to a back buffer and flip it to the primary style drawing that is no longer used doing things the D3D way so the more basic some thing is the more you can learn from it i find.

With the D3D way you have cameras, vector3's (you actualy have a 3rd dimension to your graphics even if you never use it), textures, etc. with D'Draw once you have set up the surface you whish to draw to(the screen) and draw from (your sprite graphics) you just tell it to draw at the poisiton on screen from the poition on your sprite graphics its easy peasy with no extra gumph you just dont need....

Though if your learning to do this in a professional capacity then learn both use DDraw 1st and make your graphics class as self contained as possible then as you learn D3D, if you like... as a learning experiance, swap out your graphics class for a D3D one.

Share this post


Link to post
Share on other sites
Quote:
Original post by JDUK
My experiance with java has been strictly with with command prompt and GUI programes(i.e non games) but if DirecDraw is as easy peasy with java as it is with C# go DirectDraw.... ok its no longer supported(every ones doing 2D in 3D now) but with the right book or web guide you'll have sprites dancing round on screen within an hour.

I believe he is refering to the GDI+ System.Drawing.Graphics object of C#, not the Java java.awt.Graphics object (which should be substituted with Graphics2D).

as for the deprecated status of DirectDraw:
Quote:

Microsoft® DirectDraw® has been deprecated. Deprecated components of Microsoft DirectX® 9.0 for Managed Code are considered obsolete. While these components are still supported in this release of DirectX 9.0 for Managed Code, they may be removed in the future. When writing new applications, you should avoid using these deprecated components. When modifying existing applications, you are strongly encouraged to remove any dependency on these components.

Backwards compatibility is not guaranteed.

Share this post


Link to post
Share on other sites

This topic is 4746 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

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