hunterloftis

Members
  • Content Count

    5
  • Joined

  • Last visited

  • Days Won

    1

hunterloftis last won the day on May 11

hunterloftis had the most liked content!

About hunterloftis

  • Rank
    Newbie
  1. I don't mean, by the way, guarantee 60 fps and high quality - I'm looking for ways to, for example, amortize rendering over multiple frames in order to keep the overall framerate up. I did look into pixi-tilemap, but what I'm rendering is somewhat more specific. Certain tiles need to overlap in certain ways, shadows need to work certain ways, reflections, etc. Plus, the map is fully dynamic and any tile can change at any time, so the "keep state until you hit an edge, then make a new state" strategy requires a lot of bookkeeping and is likely more expensive than the "clear and render each frame" strategy. That may be wrong and I'd be happy to hear why, but the work to implement the bookkeeping would be non-trivial so I'm not keen to test it right now.
  2. I'm using a ParticleContainer to render a very dynamic map of tiles. The player can zoom and pan across a large tile-based world, and the tiles themselves can be animated or replaced at any time. The tiles are drawn with some back-to-front overlap and a few effects (shadows, reflections of the tile above). On a large monitor, a normal number of tiles to draw per frame is about 10,000, and it would be theoretically possible to draw 40,000 on an edge-case map. At some point, every computer is going to hit a rendering limit. Sacrificing rendering fidelity in this application would be better than sacrificing framerate. Does anyone have suggestions for how to essentially "guarantee" 60 fps with PIXI? Previously, using a 2d html canvas, I would draw the tilemap in columns and check between columns on the amount of time I had remaining in the frame. If there wasn't enough time budget, I'd draw subsequent columns later. This added significant complexity but did give me a reliable framerate. I ran across the "ParticleRenderer" that seems quite new - would adding a new canvas and switching to that renderer for all the compatible parts of my image, then layering other PIXI renderers on top of it for non-particles, likely produce much benefit over the standard renderer? Thanks!
  3. That was it - I'm rendering this from a single BaseTexture, which is required by the ParticleContainer. The sprites that tend to have seams are those with textures that border differently-colored textures. I think the textures are being anti-aliased somehow and some of the border pixels from neighboring textures are bleeding in. I've started framing the textures with a 1-pixel padding; other suggestions welcome.
  4. After some experimentation (like shrinking the layout by a few pixels) I think the issue may actually be partially-transparent pixels at the edges of tiles.
  5. I'm building a grid of 64x96 sprites, laying them out at x * 64, y * 96, such that they should theoretically be seamless. However, some artifacts are appearing in the seams between sprites (image attached). My best plan to resolve that at the moment is laying sprites out at x * (63), y * (95). Does anyone know if there's another, accepted approach to this problem? I'm sure I'm not the first person to run into it.