How to use the pixi.js.Point function in pixi

To help you get started, we’ve selected a few pixi examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github ild-games / duckling-legacy / src / duckling / canvas / canvas.component.ts View on Github external
canvasCoordsFromStageCoords(stageCoords: Vector): Vector {
        if (!this.entitySystemDisplayObject) {
            return stageCoords;
        }

        return this.entitySystemDisplayObject.toGlobal(
            new Point(stageCoords.x, stageCoords.y)
        );
    }
github eranimo / terranova / src / interface / worldview / ChunkRenderer.ts View on Github external
private renderChunkMapMode(chunkX: number, chunkY: number) {
    const mapMode = this.mapModes[this.viewOptions.mapMode];
    const chunkCells = this.getCellsInChunk(chunkX, chunkY);
    const { cellWidth, cellHeight, chunkWidth, chunkHeight } = this.options;
    const chunkPosition = new Point(
      chunkX * chunkWidth * cellWidth,
      chunkY * chunkHeight * cellHeight,
    );
    mapMode.updateChunk(
      chunkX, chunkY,
      chunkCells,
      chunkPosition,
    );
  }

pixi

Super fast 2D rendering engine for browserify, that uses WebGL with a context 2d fallback.

MIT
Latest version published 9 years ago

Package Health Score

45 / 100
Full package analysis