Criparra Posted April 19, 2020 Share Posted April 19, 2020 Hello! I have a problem, to which I have looked for a solution, but I have not found anything. I have many polygons drawn on a canvas, using Pixi.graphics. Each of these polygons make up a mesh (between two polygons they share only one segment, there is no more overlapping). Each polygon has a pointer over and pointer out event. My question is: How can I make that when passing over the pointer, more than one polygon is called with the pointer over event? My solution was to try to change the size of the pointer hitbox, but I haven't accomplished anything. Thanks in advance! Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted April 19, 2020 Share Posted April 19, 2020 Only with manual hitTest called in interactionManager: renderer.plugins.interaction.hitTest(...) https://github.com/pixijs/pixi.js/blob/a967f4843e0c8dbd172c11e09a8253519de75fc6/packages/interaction/src/InteractionManager.js#L705 You can also override several methods to allow multiple objects selected, but i think that'll be more difficult. Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted April 19, 2020 Share Posted April 19, 2020 Maybe i didnt understand your question, so please clarify with a demo Welcome to the forums! 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.