TR-i

Members
  • Content Count

    6
  • Joined

  • Last visited

  1. TR-i

    BeginTextureFill

    The Result: TextureFill.mov
  2. TR-i

    BeginTextureFill

    I'm using Livecode, descendent of Hypercard. Great for interfaces and asset management, terrible for display. Produces executables for OSX-iOS-WIN-ANDoid and though I'm not targetting it, Linux. It even has a very clunky pure HTML5 target. Additionally, the kernal is open source.
  3. TR-i

    BeginTextureFill

    My project is not a game or website, it's a content delivery and social media platform with built-in authoring. It is metaphorically similar to television in that emphasis is on a kinetic environment that is more presentational than interactive. Since contributors can define their own space, I can't make assumptions about what they might want to design and have to offer the broadest range of possibilities and still keep the process simple and codeless. I chose PIXI after hammering all the best supported libraries because, unlike something like p5, screen entities are true objects that can be interacted with. Further, the implementation is non-conventional and does not run in a browser per se. It uses a standard app (OSX, iOS, Windows, Android) with a browser instance inside it. Code is invisible to the user. The app starts up in an empty HTML5 environment and all objects are created, managed and destroyed in real time. The PIXI library (as well as others) is embedded in the app so that authoring can be done offline. That's probably TMI but thought I should describe the big picture.
  4. TR-i

    BeginTextureFill

    Thanks for your help, Ivan. I've finally wrangled my textures into conformance: (me is a graphic sprite, txtr is a pre-created texture) me.txtr = txtr; // ratio between sprite size and texture size let xr = me.w / me.txtr.canvas.width; let yr = me.h / me.txtr.canvas.height; let m = new PIXI.Matrix(); m.scale(xr,yr); m.translate(-(me.w/2),-(me.h/2)); me.beginTextureFill({texture:me.txtr.canvas, matrix: m});
  5. TR-i

    BeginTextureFill

    Haven't programmed much Actionscript. I'm creating textures as separate objects that could be applied to a number of sprites. Many of them are procedurally created on canvasses provided by Pixi and some are animated. I'd like to understand what beginTextureFill assumes about the texture and its placement within the drawing boundaries. Also, would it be best practice to create all textures at something like 512x512 and how does this affect scaling in sprites that use them?
  6. TR-i

    BeginTextureFill

    Since graphic sprites have no anchors, the only way to position a texture used with BeginTextureFill is the defaultAnchor of the texture. However, changing the defaultAnchor seems to have no effect. I've tried every combination of anchoring and positioning and this is the consistent result (below). Both texture and sprite are the same dimensions (400 x 400).