Hi,
decided to give PulpCore a try and installed it today using Eclipse.
I'm new to Eclipse too, and the "how to" for Eclipse at
http://code.google.com/p/pulpcore/wiki/Eclipse obviously refers to an
older version of Eclipse, but I'm moderately confident I could follow
it nonetheless. The renamed BubbleMark compiles and runs. But very
slow.
When I started it in browser from the pulp core web pages, 60 fps was
no problem. When I managed to switch off "Cap Frame Rate" (did not
work for Firefox, but worked in IE and Chrome) 250 fps was no problem.
When I start it from Eclipse I get < 30 fps. So about 1/10th of the
performance.
When I start it in debugger, it is another 10 times slower: about 1
frame per second. (But in-game display still claims to run at ~30
fps???).
I've been searching for the problem for hours.
Using debug or release version of PulpCore didn't seem to make any
difference.
Using default player instead of PulpCore Player made no difference.
Another interesting observation: when I turn on View/"Dirty
Rectangles" in the player started from Eclipse, it runs much faster,
60 fps no problem. But when launched with debugger attached, no speed
difference is visible; both ways it runs with about one visible update
per second.
When run in debugger, and I press break, the active call stack is
almost always something like:
CompositeSrcOver(Composite).getPixelBilinearTranslucent(int[], int,
int, int, int, int, int) line: 250
CompositeSrcOver.blend(int[], int, boolean, int, int, int, int, int,
int, int, int, int, boolean, boolean, int, int[], int, int, int, int)
line: 313
CoreGraphics.internalDrawScaledImage(CoreImage, int, int, int, int,
int, int, int, int) line: 1169
CoreGraphics.internalDrawScaledImage(CoreImage, int, int, int, int)
line: 1078
CoreGraphics.drawImage(CoreImage, int, int, int, int) line: 807
CoreGraphics.drawImage(CoreImage) line: 786
BubbleMark$BallSprite(ImageSprite).drawSprite(CoreGraphics) line: 274
In other words: it looks like the program is busy drawing sprites
pixel by pixel. At first I suspected this to be the problem, but the
FAQ says this is normal and "the software renderer has consistent
performance across platforms and JREs". In this case it looks like it
does not? But why?
Finally I found an older post here complaining about the same problem,
but without solution;
http://groups.google.com/group/pulpcore/browse_thread/thread/26a60e00efd1f1eb/374f30a8ee4f0b34?lnk=gst&q=performance#374f30a8ee4f0b34
"PulpCorePlayer performance vs in browser performance"
Also I wonder if this post is related to my problem
http://groups.google.com/group/pulpcore/browse_thread/thread/ebaab17271323e02/bb98ba1e3f5d65e6?lnk=gst&q=performance#bb98ba1e3f5d65e6
PulpCore looks like a cool piece of smart software, worth using very
much. But not being able to run it from the IDE with debugger (at a
realistic speed) is quite a show stopper. And programming with the
constant threat of unexplainable severe performance degradation is
something I'd rather like to avoid... :-(
Anyone any idea what I might do wrong? Or what I could do better?
Axel