Java-Gaming.org Hi !
Featured games (83)
games approved by the League of Dukes
Games in Showcase (513)
Games in Android Showcase (121)
games submitted by our members
Games in WIP (577)
games currently in development
News: Read the Java Gaming Resources, or peek at the official Java tutorials
 
    Home     Help   Search   Login   Register   
Pages: [1]
  ignore  |  Print  
  What's the best method for a Tiled-Image?  (Read 1548 times)
0 Members and 1 Guest are viewing this topic.
Offline nodragem

Senior Newbie





« Posted 2007-08-24 18:51:40 »

 Smiley hi! I'm a french guy...  and I have need to be advised.

I know I'm not the best English Speaker of the World, so I beg to be excued for my  low level in english.

In fact, I have gone in a french forum where someone advised me to go here so as to find the solution of my problem.

My prob is the following:

I would make a java-game and I have to make Sprite, I succeeded in implementation of frame animation in my sprites: I use a big Image where I placed the different sub-image which will be used by the sprite so as to animates itself.

But I have found two, even three solution:

-the method: Graphics.drawImage(Image img, int dstx1, int dsty1, int dstx2, int dsty2, int srcx1*, int srcy1, int srcx2*, int srcy2, ImageObserver observer);

-the method: BufferedImage.getSubImage();

-and the method: CropImageFilter.

I would like know what's the most performant method.

I have realized some test, and it seems that BufferedImage add a time of loading (and lot of lines in the code, hihi!! :p ).
But I don't know if this detail is important...

   

 
Offline broumbroum

Junior Duke





« Reply #1 - Posted 2007-08-24 22:37:01 »

I do use the drawImage meth' for all of the Image operations. That works well with standard configuration. Java Advanced Imaging can bring new plugins and does improve the speed of Image operations through its API, e.g. the RenderedImage class does provide acceleration needed in games.

::::... :..... :::::: ;;;:::™ b23:production 2006 GNU/GPL @ http://b23prodtm.webhop.info
on sf.net: /projects/sf3jswing
Java (1.6u10 plz) Web Start pool
dev' VODcast[/ur
Offline nodragem

Senior Newbie





« Reply #2 - Posted 2007-08-25 08:48:23 »

 Cheesy WaWoouuuhh!! I was understood!!! lol Smiley I'm very happy: my english may be comprehensible!

Thank you BroumBroum. I don't know if I'm going to use Java Advanced Imaging... I'm a beginner in progra...

We can make Sprites easily with JAI's API?

re- thank you!  I'm very happy  Smiley !!
Games published by our own members! Check 'em out!
Legends of Yore - The Casual Retro Roguelike
Offline CommanderKeith
« Reply #3 - Posted 2007-08-25 08:59:58 »

I would make a java-game and I have to make Sprite, I succeeded in implementation of frame animation in my sprites: I use a big Image where I placed the different sub-image which will be used by the sprite so as to animates itself.

But I have found two, even three solution:

-the method: Graphics.drawImage(Image img, int dstx1, int dsty1, int dstx2, int dsty2, int srcx1*, int srcy1, int srcx2*, int srcy2, ImageObserver observer);

-the method: BufferedImage.getSubImage();

-and the method: CropImageFilter.

I would like know what's the most performant method.

I have realized some test, and it seems that BufferedImage add a time of loading (and lot of lines in the code, hihi!! :p ).
But I don't know if this detail is important...
 

The first one is the best and it's very fast.  Smiley

Bienvenue a java-gaming.org mon ami!

Offline nodragem

Senior Newbie





« Reply #4 - Posted 2007-08-25 10:26:39 »

 Cheesy hihi, merci infiniment CommanderKeith!
 In this forum, you seem more friendly than on some French Forum.

I endeavour speak Englisk as well as I could. But, if someone understands French, I can write the French traduction below my English sentences for your own training.

I will use the meth' drawImage() as you advised me, thanks! If you have the time, I have posted a other topic.

For each topic here, I woul like poste a traduction of your solution on this French Forum in order to help the French beginner:
http://www.developpez.net/forums/forumdisplay.php?f=630

I can?
Pages: [1]
  ignore  |  Print  
 
 
You cannot reply to this message, because it is very, very old.

 

Add your game by posting it in the WIP section,
or publish it in Showcase.

The first screenshot will be displayed as a thumbnail.

theagentd (14 views)
2014-10-25 15:46:29

Longarmx (52 views)
2014-10-17 03:59:02

Norakomi (45 views)
2014-10-16 15:22:06

Norakomi (34 views)
2014-10-16 15:20:20

lcass (39 views)
2014-10-15 16:18:58

TehJavaDev (68 views)
2014-10-14 00:39:48

TehJavaDev (68 views)
2014-10-14 00:35:47

TehJavaDev (60 views)
2014-10-14 00:32:37

BurntPizza (74 views)
2014-10-11 23:24:42

BurntPizza (45 views)
2014-10-11 23:10:45
Understanding relations between setOrigin, setScale and setPosition in libGdx
by mbabuskov
2014-10-09 22:35:00

Definite guide to supporting multiple device resolutions on Android (2014)
by mbabuskov
2014-10-02 22:36:02

List of Learning Resources
by Longor1996
2014-08-16 10:40:00

List of Learning Resources
by SilverTiger
2014-08-05 19:33:27

Resources for WIP games
by CogWheelz
2014-08-01 16:20:17

Resources for WIP games
by CogWheelz
2014-08-01 16:19:50

List of Learning Resources
by SilverTiger
2014-07-31 16:29:50

List of Learning Resources
by SilverTiger
2014-07-31 16:26:06
java-gaming.org is not responsible for the content posted by its members, including references to external websites, and other references that may or may not have a relation with our primarily gaming and game production oriented community. inquiries and complaints can be sent via email to the info‑account of the company managing the website of java‑gaming.org
Powered by MySQL Powered by PHP Powered by SMF 1.1.18 | SMF © 2013, Simple Machines | Managed by Enhanced Four Valid XHTML 1.0! Valid CSS!