Gamua / Sparrow-Framework

The Open Source Game Engine for iOS
http://www.sparrow-framework.org
Other
294 stars 83 forks source link

benchmark behave weird #28

Closed sunnyawake closed 10 years ago

sunnyawake commented 10 years ago

i run demo on iphone 5 with the latest code from github and found something strange:

  1. start benchmark without playing filters, it stops at 9700+ objects,even reaching 10100.
  2. exit and restart demo, start benchmark after playing filters, it stops at 6200.

i tested serval times and sure it's reproduceable.

PrimaryFeather commented 10 years ago

Hm! "Exit and Restart Demo" means exiting to the iOS menu (via home button) & shutting down the demo completely (double press home button, swipe demo away), or simply entering it again?

Or do you mean that, as soon as you displayed a few filters, the benchmark showed that lower result?

sunnyawake commented 10 years ago

1.exit means shutting down the demo(remove it from running list)

  1. yes. another thing, yesterday i ported the benchmark example to libgdx ,packed using robovm and ran it on the same iphone, it reached 12000. i was expecting the benchmark number would more less than the sparrow's. should i compile sparrow demo in release mode or something?
PrimaryFeather commented 10 years ago

Thanks for the update!

I tried it on an iPhone 4S, and there's a small difference, too — however, by far not that severe (5700 vs 5500 objects). I'll dig a little deeper, perhaps I can find out something.

As for libgdx: I don't have an iPhone 5, so I can't confirm this; however, I just searched through my e-mails and found a note that @racarone reached more than 13k objects on his iPhone 5 a while ago, so there's definitely something fishy here.

PrimaryFeather commented 10 years ago

I just checked again with my 4S; this time I eliminated the fill rate limitations by scaling down the benchmark objects to 25% of their normal size. And this time, the results differed more dramatically: ~6850 vs. ~5550 objects. So there's definitely a problem. I'll update you as soon as I know more!

In any case, thanks a lot for the report! This definitely needs to be fixed.

sunnyawake commented 10 years ago

thanks for the following up. i'm considering if it's possible to make a little java game engine based on libgdx but translating java source code to object c source code based on sparrow for ios part. the reason i choose sparrow is its api is very clean and easy,just like Starling. any suggestions?

sunnyawake commented 10 years ago

Hi Daniel

i've written a small program a while ago converting object c api to java by parsing docset. i've converted cocos2d api successfully. currently sparrow seem no docset in the repo. i tried compiling appledoc on the mac but failed. can sparrow provide the latest docset somewhere?

2014-05-02 16:13 GMT+08:00 Daniel Sperl notifications@github.com:

I just checked again with my 4S; this time I eliminated the fill rate limitations by scaling down the benchmark objects to 25% of their normal size. And this time, the results differed more dramatically: ~6850 vs. ~5550 objects. So there's definitely a problem. I'll update you as soon as I know more!

In any case, thanks a lot for the report! This definitely needs to be fixed.

— Reply to this email directly or view it on GitHubhttps://github.com/Gamua/Sparrow-Framework/issues/28#issuecomment-42001582 .

TTStu commented 10 years ago

Yes please,

want this!

------ Original Message ------ From: "sunnyawake" notifications@github.com To: "Gamua/Sparrow-Framework" Sparrow-Framework@noreply.github.com Sent: 02/05/2014 12:01:56 Subject: Re: [Sparrow-Framework] benchmark behave weird (#28)

thanks for the following up. i'm considering if it's possible to make a little java game engine based on libgdx but translating java source code to object c source code based on sparrow for ios part. the reason i choose sparrow is its api is very clean and easy,just like Starling. any suggestions?

— Reply to this email directly or view it on GitHub.

PrimaryFeather commented 10 years ago

That sounds really interesting, good luck with your efforts! :+1:

The docset of Sparrow is created using "AppleDoc". You'll find a small generate-script in sparrow/sparrow/doc. Just install AppleDoc and run this script, and you'll get the up-to-date docset.

I hope that helps!

PrimaryFeather commented 10 years ago

I could track the problem down, it only appeared after using the DisplacementMapFilter. Though I don't know why that is ...

However, I found out how to fix this; I needed to disable the vertex attribute arrays after the filter. The strange thing is, that I'm not doing that anywhere else, and get away with it. Very odd ...!