Quantcast
Channel: Pixi.js Latest Topics
Viewing all articles
Browse latest Browse all 3978

User

$
0
0

I've been messing around with Pixi and have wondered if there is a way to convert Sprites back to Textures. Basically, I wanted to create a plain blue texture from PIXI.Texture.WHITE, but found that I couldn't tint Textures directly. I then wanted to convert them to Sprites, tint those, and then convert them back to Textures via  new PIXI.Texture(<tinted Sprite>), but when trying to render the Container, Pixi threw an exception:
image.png.6d8c3a48dd09753cf0a34843285f5dab.png

I just started using Pixi, so I might've missed something obvious. I would be happy to post code snippets if needed. Everything that I found implied that I shouldn't tint the texture itself, but rather tint it when rendering the scene with sprites; would that be the correct/more efficient way to do it?


Viewing all articles
Browse latest Browse all 3978

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>