src/viewport.js
function(pixel, current) {
        var bounds = this.getBoundsNoRotate(current);
        return pixel.minus(
            new $.Point(this._margins.left, this._margins.top)
        ).divide(
            this._containerInnerSize.x / bounds.width
        ).plus(
            bounds.getTopLeft()
        );
    }
function(pixel, current) {
        var bounds = this.getBoundsNoRotate(current);
        return pixel.minus(
            new $.Point(this._margins.left, this._margins.top)
        ).divide(
            this._containerInnerSize.x / bounds.width
        ).plus(
            bounds.getTopLeft()
        );
    }
function ( pixel , current ) { var bounds = this . getBoundsNoRotate ( current ) ; return pixel . minus ( new $ . Point ( this . _margins . left , this . _margins . top ) ) . divide ( this . _containerInnerSize . x / bounds . width ) . plus ( bounds . getTopLeft ( ) ) ; }
Convert pixel coordinates to viewport coordinates.
This method does not take rotation into account.
Consider using pointFromPixel if you need to account for rotation.
@param {OpenSeadragon.Point} pixel Pixel coordinates
@param {Boolean} [current=false] - Pass true for the current location;
defaults to false (target location).
@returns {OpenSeadragon.Point}
Convert pixel coordinates to viewport coordinates . This method does not take rotation into account . Consider using pointFromPixel if you need to account for rotation .