canvasman Posted February 26, 2019 Share Posted February 26, 2019 Is it possible to create PIXI.Text with resolution 2 and cache its texture to use with sprites later? My problem is that when I scale stage (zoom out), texts jitter and become blurry. That doesnt happen when I set renderer resolution to 2 but it slows down older computers. Solution which would work for both canvas and webgl renderer would be perfect. Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted February 26, 2019 Share Posted February 26, 2019 Yep, just updateText() it and store the texture somewhere, use it for a sprite later, or use that text later. You can also set text resolution if you unset "autoResolution" https://github.com/pixijs/pixi.js/blob/dev/packages/text/src/Text.js#L331 https://github.com/pixijs/pixi.js/blob/dev/packages/text/src/Text.js#L128 Quote Link to comment Share on other sites More sharing options...
canvasman Posted February 26, 2019 Author Share Posted February 26, 2019 10 minutes ago, ivan.popelyshev said: Yep, just updateText() it and store the texture somewhere, use it for a sprite later, or use that text later. You can also set text resolution if you unset "autoResolution" https://github.com/pixijs/pixi.js/blob/dev/packages/text/src/Text.js#L331 https://github.com/pixijs/pixi.js/blob/dev/packages/text/src/Text.js#L128 I am using PIXI v4.8.2, I couldn't find that autoResolution there : \ Is the dev branch stable? Quote Link to comment Share on other sites More sharing options...
ivan.popelyshev Posted February 26, 2019 Share Posted February 26, 2019 Its stable enough, I think it will be good for your case. try roundPixels. canvasman 1 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.