You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It appear that pdSend methods takes a lot of time. When rainstick is idle, there are just 3 calls. When I disable them, frame rate get to normal.
I pushed some benchmark tests for both android and desktop and it appear that issue is in engine itself. For instance the sendFloat method take 10 times when calling "kit-freq" than "kit-mixa-dry".
note I benchmarked gdx-pd as well (without audio engine) and time spent in send methods are reasonable, there is some issues with sendList/sendMessage though, see mgsx-dev/gdx-pd#10
Another observation is that Box2D takes lot of time as well specially with polygon shapes, circles give better results.
Global observations, it appear that frame rate issue seams to be caused by a global load :
high pd message frequency
lot of box2d dynamic bodies and lot of jni calls to box2D
lot of blending
the audio engine might be part of it (25 + 10 + 1 = 35 stereo polyphonic voices)
What I can do to quickly improve things is to avoid jni calls and pd message processing as much as possible :
avoid calls to pd if values doesn't changed (mix and formants)
caching some box2D information (mass, position at each frame).
about 30 to 45 Fps on all rainsticks except "Big grains" on my Asus tablet.
Have to investigate where are the bottlenecks :
The text was updated successfully, but these errors were encountered: