EffekseerForWebGL icon indicating copy to clipboard operation
EffekseerForWebGL copied to clipboard

Oncomplete event for effects

Open MossFrog opened this issue 3 years ago • 7 comments

Is there an onComplete() event for effekseer effects? This could be useful since performance on Android devices is very bad even when no effects are being rendered within the scene (The update loop causes performance issues)

MossFrog avatar Sep 09 '21 12:09 MossFrog

Which version did you use? I have improved a performance on the android recently.

should onComplete be called after rendered?

durswd avatar Sep 09 '21 13:09 durswd

Yes after the effect has completed its render is it possible to obtain an event in order to trigger further code? I will try a more recent version for the performance issues! Thank you

MossFrog avatar Sep 09 '21 14:09 MossFrog

If it is still slow, please tell me your environment in a detail.

durswd avatar Sep 10 '21 12:09 durswd

I have not tested performance on the newer versions yet. I was asking if i can create an event callback function for the effekseer effects, such as effect.onComplete() => function() {console.log("EFFECT IS FINISHED"}; ?

MossFrog avatar Sep 10 '21 13:09 MossFrog

It seem that it cannot implement it and it makes no sense because JavaScript and WebGL runs on a single thread.

durswd avatar Sep 10 '21 17:09 durswd

I see, then would it be possible to set an an effect to loop? Such as effect.setLoop(true); so that the effect can keep looping after completion?

MossFrog avatar Sep 16 '21 08:09 MossFrog

I don't have a plan to implement setLoop, because you can implement it with EffekseerHandle.exists()

durswd avatar Oct 07 '21 03:10 durswd