Hello !
First of all, thanks for porting jPCT to AE.
I'm studying software engineer at the moment in Switzerland, and I would like to use jPCT-AE inside a school project.
But at moment I'm quite annoyed, I tried by many ways to run the demo (compiled from source) in my nexus one
but I only get a black screen. I tried with a friend spica samsung who's based on 1.5 and I did not success either.
So I decided to rewrite it a little bit to understand how things work and I got stuck in the same place... A black screen at start.
(It does work inside the emulator)
I attached my modified version of your demo.
ps: I know that your demo is just a simple example.
And what you can do with jPCT is really awesome, I take a look at all the lib and it's quite impressive.
It's a pleasure to see JavaDoc use etc.
So thank you !
I'm not saying that you don't know it or something like that, I hope you don't take it bad (I don't explain myself very well in English, excuse me).
But what I would like to say is that all member of a class are set to null if they are pointers to object,
0 if they are primitive types like int,float etc. and all booleans are set to false.
If you do it by yourself, the vm will do twice the work settings all the members to your settings.
exemple private boolean abool = false;
will be set 2 times, a default to false then false again forced by the =.
I saw that you use floats and arrays in your demo.
I'm not an expert but what I read is that float operations are not well managed by this kind of devices.
->
http://developer.android.com/guide/practices/design/performance.html#avoidfloatI saw that you are having trouble with animations (low framerate)
I don't know how you register/store all the informations but perhaps hashmaps,
arraylist or linkedlist.
Do a better work than simple arrays, for example to search something in an array if you have not the exact position
you can have a search algorithm in O(nē) which is not great hashmaps will find the information in O(n) or very close too which is really faster.
Here is some tips from android to improve performance :
http://developer.android.com/guide/practices/design/performance.htmlOf course I'm not saying that you don't know this things, perhaps it will help someone else
I was so happy when I found that jPCT was ported !
But well I think I'm doing something wrong so It cannot be displayed on phone.
If someone have a little time to spare in this, thanks in advance !
Best regards.
Here is the DDMS LogCat
03-17 23:05:58.742: ERROR/AndroidRuntime(1125): ERROR: thread attach failed
03-17 23:05:58.932: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:58.943: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:58.962: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:58.983: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:58.993: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:59.082: INFO/jPCT-AE(1065): Loading Texture...
03-17 23:05:59.162: INFO/jPCT-AE(1065): Adding Lightsource: 0
03-17 23:05:59.162: INFO/jPCT-AE(1065): OpenGL vendor: Qualcomm
03-17 23:05:59.162: INFO/jPCT-AE(1065): OpenGL renderer: Adreno
03-17 23:05:59.162: INFO/jPCT-AE(1065): OpenGL version: OpenGL ES-CM 1.1
03-17 23:05:59.162: INFO/jPCT-AE(1065): OpenGL renderer initialized (using 2 texture stages)
03-17 23:05:59.243: INFO/jPCT-AE(1065): Subobject of object 7/plane compiled using 2400 vertices in 50ms!
03-17 23:05:59.243: INFO/jPCT-AE(1065): Object 7/plane compiled to 1 subobjects in 73ms!
03-17 23:05:59.263: INFO/jPCT-AE(1065): Subobject of object 9/tree1 compiled using 690 vertices in 15ms!
03-17 23:05:59.263: INFO/jPCT-AE(1065): Object 9/tree1 compiled to 1 subobjects in 21ms!
03-17 23:05:59.282: INFO/jPCT-AE(1065): Subobject of object 10/tree2 compiled using 690 vertices in 14ms!
03-17 23:05:59.282: INFO/jPCT-AE(1065): Object 10/tree2 compiled to 1 subobjects in 21ms!
03-17 23:05:59.292: INFO/jPCT-AE(1065): Subobject of object 11/grass compiled using 264 vertices in 7ms!
03-17 23:05:59.292: INFO/jPCT-AE(1065): Object 11/grass compiled to 1 subobjects in 10ms!
03-17 23:05:59.302: INFO/jPCT-AE(1065): Subobject of object 8/rock compiled using 84 vertices in 2ms!
03-17 23:05:59.302: INFO/jPCT-AE(1065): Object 8/rock compiled to 1 subobjects in 3ms!
03-17 23:05:59.602: INFO/ActivityManager(113): Displayed activity com.demo.jpctae/.jpctae: 885 ms (total 885 ms)
03-17 23:06:10.182: INFO/jPCT-AE(1065): Visibility lists disposed!
[attachment deleted by admin]