Jump to content

sallf

Members
  • Content Count

    2
  • Joined

  • Last visited

  1. @ivan.popelyshevthanks for sharing some thoughts! I had seen a few instances where people used url params to beat Pixi returning a cached version, and I think was talking more about "network" caching. The below code works fine, but I think it makes 2 requests to the server for the same asset. Obviously this is not Pixi related, except that I might have expected to be able to pass an `id` or other argument to return a different texture from the same URL. const texture1 = PIXI.Texture.fromURL('./some.svg?width=10&height=10', { resourceOptions: { width: 10, he
  2. I'm trying to create multiple textures, with different resourceOptions, based on a single svg. Here's what I've tried so far: 1. Using `fromUrl` (& `from`) const texture1 = PIXI.Texture.fromURL('./some.svg', { resourceOptions: { width: 10, height: 10, }, }); const texture2 = PIXI.Texture.fromURL('./some.svg', { resourceOptions: { width: 100, height: 100, }, }); In this case, texture2 just returns the texture1 from TextureCache. 2. Using the loader let resources; loader .add('texture
×
×
  • Create New...