🚨 Shai-Hulud Strikes Again:834 Packages Compromised.Technical Analysis →
Socket
Book a DemoInstallSign in
Socket

tiled-geometry

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tiled-geometry

2d tiled geometry utilities

latest
Source
npmnpm
Version
1.0.0
Version published
Maintainers
1
Created
Source

Tiled Geometry

Dependencies Node.js CI License

Utilities for 2-D tiled geometry

This library contains several useful functions and classes for dealing with 2-D tiled geometry.

Installation

npm install tiled-geometry

API

Constants and utlities for 2-D tiled coordinate spaces:

  • Direction - constants for eight compass directions
  • Turn - constants for rotation among eight compass directions
  • CardinalDirection - constants for four cardinal directions
  • CardinalTurn - constants for rotation among four cardinal directions
  • CardinalDirectionFlags - bitmask constants for four cardinal directions
  • Flip - constants for mirroring the coordinate space
  • CardinalOrientation - constants combining CardinalDirection and Flip
  • Axis - constants for the two major axes

Classes for coordinates, shapes, masks, and more:

  • Offset - a location or relative offset
  • Size - a two-dimensional extent
  • Rectangle - a rectangle (with offset and size)
  • Mask - a rectangular area with boolean values for each cell
  • MaskRectangle - a mask with an offset
  • RasterMask - a mask encoded as "raster lines"
  • CardinalPath - a path on the grid, moving only in the four cardinal directions
  • TransformRectangle - maps a rectangular area onto a grid with transformations

Keywords

2d

FAQs

Package last updated on 24 Jan 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts