Popular Content

Showing content with the highest reputation on 07/25/19 in all areas

  1. 1 point

    Pixi Legacy v5.1 and Mask issue

    Ok it definitively works! Great support, thanks again!
  2. 1 point
    i used the second option refactoring all containers an resizing stage. it fit perfectly on every browser thanks guy
  3. 1 point

    Pixi Legacy v5.1 and Mask issue

    I've tried with CanvasTinter.tintMethod and it seems to works! I take this afternoon for trying better and after I notice you!
  4. 1 point
    Solved all, thanks guy
  5. 1 point
    Awesome, I will look into it
  6. 1 point
    With that said, is there an easy way to clone and edit a Graphics element? For example if I have the following: let roundedRectangle = new PIXI.Graphics(); roundedRectangle.lineStyle(1, 0xFF00FF, 1); roundedRectangle.name = 'roundedRectangle'; roundedRectangle.selectable = true; roundedRectangle.angle = 0; roundedRectangle.drawRoundedRect(0, 0, 100, 100, 16); this.setPivotToCenter(roundedRectangle); roundedRectangle.position.set(700 + roundedRectangle.pivot.x, 500 + roundedRectangle.pivot.y); roundedRectangle.hitArea = roundedRectangle.getLocalBounds(); this.viewport.addChild(roundedRectangle); Now when I scale it, I would like to clear, refill and keep all of the styles, but I want to resize the shape and keep the lineStyle width at 1px. I am looking for something built-in, if it does not exist, I will create my own.
  7. 1 point
    > but the processes within don't take very long then its on GPU side. You need better profiling tool. I remember that when I last time used chrome profiler, I saw bars of JS rows and then bar on GPU row, and RAF started immidiately after las GPU bar ended
  8. 1 point
    Oh, I did not know that thanks for clarifying it, actually clearing and refilling could work for us since it's fast enough to look seamless to the user. Shapes are just a small part of our app, we mostly deal with images, for which pixijs is the best possible solution out there, I tried almost all of them, none worked better than pixijs. I just hope the support for vectors and shapes become better for pixijs in future (I mean the things that are possible of course) I should extend the classes perhaps. I will share them if I achieved anything useful Thanks for the help and clarifications.
  9. 1 point
    i don't know why you use canvas app for zooming with pixijs but did you have --enable-gpu-rasterization Am really not sure if this can help but you can maybe experiment with result. From what i know, it should affect DOM painting and scaling elements. https://www.chromium.org/developers/design-documents/chromium-graphics/how-to-get-gpu-rasterization
  10. 1 point
    No need to do this at least: anim has an attribute currentFrame. So you can simply do: if (this.anim.currentFrame === 4){ //currentFrame will start from 0-size of animation. // dosomething } I took a look, and we really don't seem to have the textureFrame==46 style.. It's convenient, but if you're going to hard-code a number in there, I much prefer just hard coding to the 0,1,2,3 convention. Think of this: You know you're animation framing is going to be 0=first frame, 1=second frame. Now: If you update your spritesheet.png, and suddenly If you hard-code in =46, and then the image changes, then both the image, and your code has to change. Does that make sense?