I'm learning Java and starting on my first lesson/project. In this project, the tutor's pixel moves across the screen and a steady clip and completes it's journey across the screen in a matter of a few seconds. Mine takes several minutes, moving only 1 pixel every 5 seconds. I would have thought a MacBook Pro would handle Java graphics better than that. To see if it was my code or the unit, I rebuilt the project from scratch while booted in Windows, the performance was noticeably improved. There, the cursor moves 1-2 pixels a second; still not as good as the instructors, but better than OSX handles it. I'm wondering if this is normal or expected? Does OSX just have a crappy time with handling Java graphics? I've linked my code if it helps to answer this question, as well as a video of the slow moving pixel and abysmal frame rate in OSX. Fraps shows I'm getting an average 650 fps in Windows, the code output on the OSX side shows it is more around 40-60 depending on whether or not I have other video processes going. In the video it is around 45, but that is because the screen capture slows it down from the average 60 fps.
example of framerate in OSX: https://www.youtube.com/watch?v=PQ0-L4slgP4
Code for Screen class: http://pastebin.com/3ETKsY8r
Code for Game class: http://pastebin.com/NDreVB60
I'm using Eclipse Juno under 10.7.5 on the Apple side, and Windows 7 on the Bootcamp side. The MacBook has 4GB of memory and a 2.53 Ghz Intel Core 2 Duo.