dmko Posted August 9, 2016 Share Posted August 9, 2016 Last time I tried PIXI for a demo was like a year ago, but I dusted off some of the code and I'm hoping to give it a go again I tried to simply use my art assets but with the "Drag" functionality in example 8 at http://www.goodboydigital.com/pixijs/examples/8/ Unfortunately, two weird things happened: The line "var newPosition = this.data.getLocalPosition(this.parent);" didn't work for me, couldn't find the function- rather I had to add an extra ".data" (var newPosition = this.data.data.getLocalPosition(this.parent);) In terms of user experience- holding the object (The music sign in the top-left) and dragging it around, letting go, dragging again, etc. slows things down incredibly... as though it's stacking function calls or something. After a while (10-30 seconds of that) it becomes unusable I'm hoping I just did some simple thing wrong in the setup... I'd like to keep the modular JS style, I guess that's one difference but I can't imagine how that'd be a showstopper... here's the relevant bits in this test: Live demo: http://storage.googleapis.com/tjandpals-webdata/seekandfind/dev/index-dev.html JS Code: http://storage.googleapis.com/tjandpals-webdata/seekandfind/dev/js/seekandfind/Init.js (note - I'm not maintaining a different build tree just for the forum post, so those links might go away or update as I try solutions, build further, etc.) Quote Link to comment Share on other sites More sharing options...
dmko Posted August 9, 2016 Author Share Posted August 9, 2016 Whoa - just noticed the same happens on the official example too! Must be a PIXI bug.. maybe listening for both touch and mouse causes some issue? Quote Link to comment Share on other sites More sharing options...
dmko Posted August 10, 2016 Author Share Posted August 10, 2016 OK, strangely - I tried on a different computer today and it seems fine... but the .data.data seems super weird, and there was definitely a performance bottleneck last night! Are there any tooling options to pinpoint where that bottleneck might be? I.e. even to know what is actually happen with each frame update? If there is some recursive stack building somehow - it would be great to be able to see that Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted August 10, 2016 Share Posted August 10, 2016 Browser plugins? Kaspersky something-something? They can screw with accessability sometimes. Quote Link to comment Share on other sites More sharing options...
dmko Posted August 10, 2016 Author Share Posted August 10, 2016 Don't have ipad on me at the moment - but it was happening there too :\ Quote Link to comment Share on other sites More sharing options...
dmko Posted August 11, 2016 Author Share Posted August 11, 2016 Well, problem seemed to disappear, maybe I was hallucinating Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.