Author Topic: Version updates!  (Read 177799 times)

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #15 on: April 09, 2010, 05:14:44 pm »
Really happy to see all this updates :)

Offline raft

  • quad
  • ******
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Version updates!
« Reply #16 on: April 09, 2010, 09:44:28 pm »
built-in mesh animations are much faster now, compared to bones. do they make calculations as ints ?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #17 on: April 09, 2010, 09:59:19 pm »
No, nothing has changed in the animation code.

Offline raft

  • quad
  • ******
  • Posts: 1993
    • View Profile
    • http://www.aptalkarga.com
Re: Version updates!
« Reply #18 on: April 09, 2010, 11:53:08 pm »
oops. bones is quite expensive for Android in that case. i've made a test, animated ninja with bones but didnt apply the animation with IVertexController. results are 19, 11, 7 fps for 1,2,3 ninjas on G1. when animation applied fps's were 17, 10, 6

great job for increasing vertex upload performance  ;D

bones definetely need a JIT ::)

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #19 on: April 13, 2010, 11:22:51 pm »
Another update! This one increases performance for lighting and/or more complex scenes with different objects up to 10%. My demo scene runs @31fps instead of 28fps now on my phone. In addition, it contains some minor tweaks for Matrix and SimpleVector math (but nothing to get crazy about...you'll hardly notice it).

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #20 on: April 14, 2010, 12:39:50 pm »
Great, I don't see much difference since I'm working at 30 or 60fps depending if I'm using the camera or not. (With the Nexus One)

But it's always nice to see such improvement.
But it does improve the fps on the Samsung Spica, the latest update made the fps go from 5 to 20~ so it's really great :)

I just wanted to ask if it's possible to next release to add in front of functions that throw any exception
the code
Code: [Select]
throws Exception or Better
Code: [Select]
throws SpecificException .

This really would help to Dev/Debug and avoid exceptions randomly uncaught that make the program FC.
« Last Edit: April 14, 2010, 12:42:02 pm by dl.zerocool »

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #21 on: April 14, 2010, 01:50:25 pm »
Wow...what an improvement on the Spica. How comes that? Must have done something that its renderer really likes...

About the exceptions: There are basically two groups...one that thinks that checked exceptions are a good thing and one that doesn't. I belong to the second, which is why i'm using unchecked exceptions for almost everything. For a brief discussion about pros and cons, just search for Bruce Eckel's view on this.
As far as AE is concerned, wrapping the resource loading and maybe the actual rendering into a try-catch should catch most of the common problems. Things like matrix math and similar doesn't throw any exceptions on its own.
« Last Edit: April 14, 2010, 01:56:19 pm by EgonOlsen »

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #22 on: April 14, 2010, 02:44:31 pm »
This low end phones are definitely built with no standard.

About exception, I'll take a look when I'll have time at what you told me, but at moment I can't.
I understand and respect your point of view, so I'll continue using without throws.

Another question is, are you sure that TextureManager flush works correctly ? Because sometimes I got the error :
Code: [Select]
04-14 14:26:52.923: ERROR/AndroidRuntime(4318): java.lang.RuntimeException: [ Wed Apr 14 14:26:52 Europe/Zurich 2010 ] - ERROR: A texture with the name 'grassy' has been declared twice!
Here is how I do things:
Code: [Select]
gameModels.add(new GameModels(Primitives.getPlane(20, 30), new Texture(
resources.openRawResource(R.raw.planetex))));
textureManager.addTexture("grassy", gameModels.get(0).modelTexture);
gameModels.get(0).model.setTexture("grassy");

Code: [Select]
private class GameModels
{
public GameModels(Object3D model, Texture modelTexture)
{
this.model = model;
this.modelTexture = modelTexture;
}

public Texture modelTexture;
public Object3D model;
}
Is there something wrong ?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #23 on: April 14, 2010, 02:52:05 pm »
I'll look into that TextureManager-thing...

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #24 on: April 14, 2010, 10:35:21 pm »
flush() should work fine. It discards all internal structures of the TextureManager. There's no chance that some texture remains in the manager after calling flush. Maybe you are adding the texture twice without calling flush() in between?

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #25 on: April 14, 2010, 10:44:00 pm »
Another small update with some additional micro optimizations. On my phone, the demo scene increases by 3%, the MD2 animation by 5%.

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #26 on: April 15, 2010, 02:23:27 pm »
Yeah another update :P

About the Textures : Certainly, anyway I'm no more using textures so it's not the problem, thank you for the check :)
I'm using materials instead. It's enough for what I'm doing at moment.
« Last Edit: April 15, 2010, 02:28:19 pm by dl.zerocool »

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #27 on: May 05, 2010, 10:14:43 am »
Hello,

I didn't find a way to check if all the models are build and ready to draw.
Is it possible to implement this feature ? So we will be able to do a loading screen (while the resources are being loaded).

Thank you.

Best Regards

"A returned value would be great for example"

I don't know if you threaded your buildObject that's why I'm asking for it.
« Last Edit: May 05, 2010, 10:47:38 am by dl.zerocool »

Offline EgonOlsen

  • Administrator
  • quad
  • *****
  • Posts: 12295
    • View Profile
    • http://www.jpct.net
Re: Version updates!
« Reply #28 on: May 06, 2010, 05:24:25 pm »
I'm not sure how this should work. The only that knows if all resources have been loaded is the application that loads them, isn't it?

Offline dl.zerocool

  • long
  • ***
  • Posts: 104
    • View Profile
Re: Version updates!
« Reply #29 on: May 10, 2010, 09:54:24 pm »
So your functions aren't threaded.
That's what I was asking :).

I found a solution so, just start the loading screen before starting loading the models, then after all loads and builds stop it.

;)

I do that in a thread and the animation screen is a thread too.


Thank you.

ps: sorry lately I've not been answering quite fast, but I'm overloaded at school with projects and tests, it's the end of my 2nd year of engineer in 7weeks...
So I've been very busy.