Package jsky.coords

Examples of jsky.coords.WorldCoords.format()


        RowCoordinates rowCoordinates = _entry.getRowCoordinates();
        String equinoxStr = (String) queryArgs.getParamValue(SkycatConfigEntry.EQUINOX);
        double equinox = _getEquinox(queryArgs);
        if (rowCoordinates.isWCS()) {
            WorldCoords pos = (WorldCoords) coords;
            String[] radec = pos.format(equinox);
            queryArgs.setParamValue(SkycatConfigEntry.RA, radec[0]);
            queryArgs.setParamValue(SkycatConfigEntry.DEC, radec[1]);
            queryArgs.setParamValue(SkycatConfigEntry.EQUINOX, equinoxStr);
            queryArgs.setParamValue(SkycatConfigEntry.MIN_RADIUS, region.getMinRadius());
            queryArgs.setParamValue(SkycatConfigEntry.MAX_RADIUS, region.getMaxRadius());
View Full Code Here


     * @param region    (in) describes the query region (center and radius range)
     */
    public void setRegionArgs(QueryArgs queryArgs, CoordinateRadius region) {
        Coordinates coords = region.getCenterPosition();
        WorldCoords pos = (WorldCoords) coords;
        String[] radec = pos.format();
        queryArgs.setParamValue(SkycatConfigEntry.RA, radec[0]);
        queryArgs.setParamValue(SkycatConfigEntry.DEC, radec[1]);
        String equinoxStr = (String) queryArgs.getParamValue(SkycatConfigEntry.EQUINOX);
        queryArgs.setParamValue(SkycatConfigEntry.EQUINOX, equinoxStr);
        queryArgs.setParamValue(SkycatConfigEntry.MAX_RADIUS, region.getMaxRadius());
View Full Code Here

                double equinox = imageDisplay.getWCS().getEquinox();
                WorldCoords wcs = new WorldCoords(p.getX(), p.getY(), equinox);

//                worldCoordsTextField.setText(wcs.toString()); // Displays always in J2000
                // display the coordinates in the equinox of the image
                String[] ar = wcs.format(equinox);
                String equinoxStr;
                if (equinox == 2000.) {
                    equinoxStr = "J2000";
                } else if (equinox == 1950.) {
                    equinoxStr = "B1950";
View Full Code Here

            // world coords
            if (imageDisplay.isWCS()) {
                imageDisplay.getCoordinateConverter().imageToWorldCoords(p, false);
                double equinox = imageDisplay.getWCS().getEquinox();
                WorldCoords wcs = new WorldCoords(p.getX(), p.getY(), equinox);
                String[] ar = wcs.format(equinox);
                raValue.setText(ar[0]);
                decValue.setText(ar[1]);
            } else {
                raValue.setText("");
                decValue.setText("");
View Full Code Here

    public void setRegionArgs(QueryArgs queryArgs, CoordinateRadius region) {
        Coordinates coords = region.getCenterPosition();
        String equinoxStr = (String) queryArgs.getParamValue(EQUINOX);
        double equinox = _getEquinox(queryArgs);
        WorldCoords pos = (WorldCoords) coords;
        String[] radec = pos.format(equinox);
        queryArgs.setParamValue(RA, radec[0]);
        queryArgs.setParamValue(DEC, radec[1]);
        queryArgs.setParamValue(EQUINOX, equinoxStr);
        queryArgs.setParamValue(RADIUS, region.getMaxRadius());
        queryArgs.setParamValue(MIN_RADIUS, region.getMinRadius());
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.