This class represents a screen coordinate, in x and y coordinates
ALKMaps. | This class represents a screen coordinate, in x and y coordinates |
Properties | |
x | {Number} The x coordinate |
y | {Number} The y coordinate |
Constructor | |
ALKMaps. | Create a new ALKMaps.Pixel instance |
Functions | |
toString | Cast this object into a string |
clone | Return a clone of this pixel object |
equals | Determine whether one pixel is equivalent to another |
distanceTo | Returns the distance to the pixel point passed in as a parameter. |
add | |
offset | Parameters px - {<ALKMaps.Pixel>|Object} An ALKMaps.Pixel or an object with a ‘x’ and ‘y’ properties. |
distanceTo:function( px )
Returns the distance to the pixel point passed in as a parameter.
px | {ALKMaps.Pixel} |
{Float} The pixel point passed in as parameter to calculate the distance to.
add:function( x, y )
x | {Integer} |
y | {Integer} |
{ALKMaps.Pixel} A new Pixel with this pixel’s x&y augmented by the values passed in.
offset:function( px )
Parameters px - {<ALKMaps.Pixel>|Object} An ALKMaps.Pixel or an object with a ‘x’ and ‘y’ properties.
{ALKMaps.Pixel} A new Pixel with this pixel’s x&y augmented by the x&y values of the pixel passed in.
Cast this object into a string
toString:function()
Return a clone of this pixel object
clone:function()
Determine whether one pixel is equivalent to another
equals:function( px )
Returns the distance to the pixel point passed in as a parameter.
distanceTo:function( px )
add:function( x, y )
Parameters px - {<ALKMaps.Pixel>|Object} An ALKMaps.Pixel or an object with a ‘x’ and ‘y’ properties.
offset:function( px )