With the first one I can change the Priority and test itwith the third one.With the second I know, that my BufferedImage buffer is not accelerated....But I don´t know how to change this, the priority is worth sh... for this matterbecause it doesn´t help me at all to have 400 PS in my car when there´sno accelerator

I know you know how to do this,please help me.It´s really important to accelerate tile-images for a tile-based game , I guess

I believe the main idea is that you have to use GraphicsConfiguration.createCompatibleImage to make the image actually get accelerated. I guess the image's data has to match the screen resolution, color depth, etc.

It's sort of silly that it matters which methods you use to load the BufferedImages, but that's the way it is. It should create "compatible" images unless told otherwise, but it only creates them when you use a method like GraphicsConfiguration.createCompatibleImage.

HiThanks for your help which I really appreciate I've been thinking a lot about this matter and thisis not the first game where I thought:Let's do it better this time But I wonder why it still isn´t accelerated...I used the

1

createCompatibleImage()

method and it´s still the same, not even one accelerated BufferedImage.It´s the same with BufferedImages created by the program.I use 3*3 BufferedImages for the ground in my RPG´s world,so I can easily scroll through the world.I already don´t draw the ground every frame because of the FPS dropping.I hoped accelerating would change this a bit.In general I wouldn't mind not redrawing the tiles at all because once they are onthe BufferedImage I just need to put that on the screen.But what to do if there´s animation in the groundtiles, f.e. with water ?Is it maybe something with my Java (jre1.6.0_07), or Windows XP thatdoesn´t allow this ?Or should I use some other Image like VolatileImage?Although I must admit that I didn't really get the advantages of it If you need more data, please say so.I also checked my memory and Java says there's ~255 MB of accelerated memory available...

Maybe you have too many images? It only accelerates the images that are used the most.

How big is the frame? You have to take into account that the entire screen has to be stored on the graphics card. If your frame is some huge high-resolution thing, it might take up alot of MB on its own.

Are you using BufferStrategy for rendering? If you're doing something weird for drawing to the screen, it might screw everything up.

Honestly, I don't know what the problem is, but I'm surprised you haven't gotten a ton of responses. This is a common problem.

I just have 9 images to be acceleratedwith the same size as the screensize which is 1280*1024.But I think there has to be enough memory available.I start the game with a .bat-file containing the entry:

1

-mx1024M

And 1,5 GB RAM and a 8600 GTS should do the job.I already used the Fullscreen-mode with BufferStrategy as you mentionedwhich in fact gives me more FPS.But this has nothing to do with my BufferedImages because they are, as said above, offscreen-buffer.I use them to draw tiles onto and put the buffer on the screen using BufferStrategyas suggested in the Sun tutorial.

It still has no acceleration.If you´d say these images are to much for my memory I must saythat I print the capabilities for everey single image and it´s always the same:false and 0.5At least the first one should have enough memory to use.

If this is a common problem then why can´t Sun solve this ? Maybe when Java 1.7 is released...

I am not sure, but isn't it true that Java 2D learns what to accelerate and what not? So if you check at the very beginning of the runtime of your app, it could well be that everything is still unaccelerated, but while your game is running and the images are being drawn, in the background they are being optimized by keeping them in videomemory?

Hi you are permitted to be sure I just tried again in my render-loop and it turns out now all buffer are accelerated after some time.But still after initializing them they aren´t accelerated at all.When having done some rendering it happens,what a surprise.I guess another Java mystery has been solved Thanks for thatand welcome to JGO (as it was your first post here).

I would suggest to reduce the number of operations you doto BufferedImages. If you use some temp. buffered imagesfor rendering, consider changing them to translucentvolatile images (assuming you don't need access to pixels).This will not affect performance when these are notaccelerated but will help when they are.

I'm not sure why BufferedImages can't just be wrappers for VolatileImages and do all the checking automagically, I though that was how it worked in older java versions, oh well...

Hi you are permitted to be sure I just tried again in my render-loop and it turns out now all buffer are accelerated after some time.But still after initializing them they aren´t accelerated at all.When having done some rendering it happens,what a surprise.I guess another Java mystery has been solved Thanks for thatand welcome to JGO (as it was your first post here).

Thanks. I've been reading the forum for a while now, but I usually hang around in the forums at java.sun.com More hostile environment than it needs to be, but it makes me laugh.

Just to note, I find this wiki page to be very helpful in my own research into these matters:

It seems, especially with the excellent forum post that CommanderKeith linked to, that game developers should always use VolatileImage just in case hardware acceleration is available. But I must say it is a murky subject to understand properly.

Thanks again,that are both really helpful links.I've been into this topic of Volatile Images for some timebut it has always bothered me that they so easilylose there content.Then again that goes for the BufferStrategy, too,which I'm using already, somaybe after reading that new tutorial in fullI will also use them for my issues.

I changed my backbuffer also to VolatileImagebut the effect was really bad:The FPS dropped a bit and for the worst partwhen scrolling through the map and redrawing one of the buffersit needs two seconds to do it.

For N=7, yes.As written above I have jre1.6.0_07 working on my Pc.I think the images painted to the screen aremy tiles and that´s a lot:3*3 buffers with size 1280*1024 and a tilesize of 128*64makes 1440 images at first.When scrolling to a side there is also drawing of 480 images to do.Tell me if I'm wrong here, but that has to be normal for every tilebased RPG.Or not ?Is there any way to do this with 3D, too ?Of course I would prefer that if it is faster.

Seems like TRANSLUCENT BufferedImages are drawn through the software pipeline only, which is godawfully slow. When you switched to the VolatileImage however, they are now drawn through the D3D pipeline, which is a whole lot faster. That certainly explains the dramatic increase.

Seems like TRANSLUCENT BufferedImages are drawn through the software pipeline only, which is godawfully slow. When you switched to the VolatileImage however, they are now drawn through the D3D pipeline, which is a whole lot faster. That certainly explains the dramatic increase.

When I use VolatileImages for my tiles, which have as all isometric tiles have, four transparent parts, will it also be drawn trough 3D?I think this would help a lot,I´ll do so tommorow...oh wait, it's already today

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