I didn't make it cause as far as I know posting a link to another website (rival, i think) on a forum is considered as spam...
Type: Posts; User: chri
I didn't make it cause as far as I know posting a link to another website (rival, i think) on a forum is considered as spam...
uhm...yes, but I don't think it's cross posting..I mean it's a different forum I was registered on...I couldn't find my answer here so I tried there..is it a crime?
someone told me to "enable hardware acceleration" to solve this problem...does anyone have any clue on how to do that?
no one is going to do your homework for you, try, then post the code and tell us where are you stuck
sure, the background is just a yellow rectangle
http://i48.tinypic.com/mto5kg.png
and here's the ball
http://i49.tinypic.com/16c27a8.png
I tried on my father's computer, an old toshiba...
ok thank you anyway, I'll try on other computers...
oh dear...should I try to reinstall java or something?
but what for the frame rate? The entire thing won't work at 15 fps cause the ball won't detect the edge of the screen correctly, do you have any clue of what is lagging the animation on my computer?
should I add
long cumTime = System.currentTimeMillis()+1;
after the start of movieloop?
this screw up the entire time thing
maybe the velocity is too high and if you have a smaller screen than the mine it get immediately off the screen...
for me it works...maybe it's cause of the background that is 2560*1440 (my screen's resolution) but the question is why I get this bad frame rate!
edit: how did you get the images?
what is this code supposed to do? I suggest you to post the whole code with some more specific question...
yeah I changed some physics parameter and that screwed the calculation of when the ball should stop, which wasn't already precise, to make it move to the right change the parameters in setPhysics for...
main
import java.awt.DisplayMode;
import java.awt.Graphics2D;
public class mainclass {
long startingTime = System.currentTimeMillis();
long cumTime = startingTime;
O_O does that mean that the problem isn't my code but my computer or something? I play 3d games finely on my computer I don't think an animation like this could create so many problems xD
Fr rate FPS
449 2
118 8
79 12
65 15
68 14
65 15
66 15
61 16
67 14
ok I tried what you said, now I have no objects in the screen class, I load the images only in the Physics class and then I get them through a method but I still have 3 objects in mainclass and I...
I removed the call of mainclass() from screen cause it was useless, I have no clue of why I created it :D, but I don't get it, if I need a method from mainclass how can I not create a new object of...
sorry, is it better now?
I don't understand o_O could you explain it better please?
I removed them
I don't get what you mean, progress bar of what?
post your code and tell us where are you stack at, only then we will be able to help you
Java is to Javascript like Ham is to Hamster
they are two different things, and this is a java forum, I don't think most of us know much about javascript
yes but, I don't know if it's possible, couldn't you at least make that the poster can see his own post, but with some kind of advice that let the poster know that the post is visible only to him...
Hi everyone :D
I have this animation, that consists in a ball moving around the screen following physical parameters as acceleration etc... everything works fine, but I only get a very bad frame...
oh god I feel so stupid, I forgot to write the method getGraphics that is in the screen class -.-
now I don't get any exception anymore, but the images don't show...I only get a gray screen
Now...
The only variable involved there is g, a graphics2d object, I don't see how it could be null...