Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Akujin13

[java] Graphic programming in Java

This topic is 5677 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 attempting to create a fire applet, without much luck, and i can''t seem to find any good tutorials online and the local bookstores don''t carry anything that goes over the topic. I have some background in DirectX8 programming, so i understand the basics of the technique, but i don''t understand how to apply it to a Java applet. Can anyone help me out with this, or at least point me to a good tutorial? -Akujin

Share this post


Link to post
Share on other sites
Advertisement
I''m going to assume you need something a little more advanced than just "how do I make an applet?", so here''s a link to the Java 2D Programmers guide, which documents just about everything about programming graphics in Java. If you can''t find it in here, I don''t know where you''ll find it. =)

http://java.sun.com/products/jdk/1.2/docs/guide/2d/spec/j2d-bookTOC.doc.html

This isn''''t life in the fast lane, it''''s life in the oncoming traffic.
-- Terry Pratchett

Share this post


Link to post
Share on other sites
Indeed, I''m no amature when it comes to Java, so I don''t need to know how to make applets, i just need to know how to apply the special effects techniques for things like 2D water and fire.

I''ll take a look through that guide and see if it gives me what I need. Thanks.

-Akujin

Share this post


Link to post
Share on other sites
You said in your e-mail you were looking for direct pixel manipulation. Well, there is a class called WritableRaster. It represents a rectangular set of pixels that can be written to. As stated in the Java 2D tutorials I''ve seen, you can create an empty BufferedImage, and it contains a Raster and a ColorModel... from the Raster, there''s a method to create a WritableRaster.......

Perhaps this is what you''ve been looking for?

This isn''''t life in the fast lane, it''''s life in the oncoming traffic.
-- Terry Pratchett

Share this post


Link to post
Share on other sites
I took the time to read through the raster page a while ago actually, and it''s really not what i''m looking for. I simply want to be able to store the data in an array and call from that (rasters don''t provide much support for keeping track of rows of data, which you need for special effects)

I know for fact it can be done without using bufferedimages (besides, i simply want to use a MemoryImageSource to create the image)

-Akujin

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!