• Content Count

  • Joined

  • Last visited

About gonzalle

  • Rank

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. Thanks to all. I keep studying solutions. @botmaster : there should be an easier way to define area with a color map. (a hit map with unique color for each area as index) : example : https://codepen.io/lavrton/pen/OWKYMr?editors=0010
  2. I will try to keep them 2048 x 2048 max... and I will have something like 8 of them. I am considering now to create a script on server to build an Atlas for all SVG elements... keep track of all positions in a Json file, then repbuild the maps within pixi from the sprites... It could be something like 5000 sprites.... But I would rather to create sprites on the fly. As a user will certainly not use all the sprites... 15% sounds to be a maximum. I don't know where to go.
  3. Thanks Ivan, I'm considering Pixi because i'm impressed by how effectively it handles sprites. I need SVG only to define the shape of the mask for a sprite... So I might narrow my questions : I know that I can create a sprite from a SVG with Pixi (PIXI.Texture.fromImage('data:image/svg+xml;charset=utf8',...))... But... Q1 : Can I create sprites from big bitmaps with a SVG path as masks, (at a specified bbox) ? What would be the Method to use ? Q2 : The way I understand Pixi, is that it "crops" the relevant portion of the src bitmap without having to handle the full bitmap in memory. Am I right ? (I can't do that with a SVG mask). And of course. If I decide to use pixi and I can't achieve what I want, I will curse you for eternity... As always. ;)... (to avoid that, I always do some serious Proof Of Concept before... If I mess up... It will be my own responsibility) Thanks again.
  4. I'm in an early phase of a new project and I'm considering using Pixi for it. I think it's a good idea to ask the community before going further.. Basically, I have multi-layered maps with many different models (up to 12) the top layer is interactive, and when I click on a zone I can choose what map model to display for this zone. Heres an image of what I have in mind : https://i.imgur.com/UafKavW.jpg The solution I'm thinking of : Outside Pixi : 1 - I choose one of the available map model to display. 2 - I click on an element of a transparent SVG that is placed above the canvas. 3 - I Get back informations about this element (path description, bbox, etc...) In Pixi 1 - I ask pixi to create and display a sprite with the chosen map model and the SVG element as a mask. 2 - I can, eventually, choose to apply a filter to this element. Do you think that pixi.js can handle something like this ? Is it a good idea to use pixi for this ? Does using pixie will help with the speed over a vanilla DOM/SVG solution ? Thanks in advance to the experts !;)