This PR targets: #253, #76 and to some extent, maybe #208
It features:
* api: readPixel on a HiPS object method taking x, y pixel values on the
screen. When no screen coo are given, the one of the center screen is
used.
* api: HiPS.probe a general method using HiPS.readPixel under the hood.
It allow to probe the survey pixel values on a pixel, along a screen line and
along a great circle arc on the sky
* fix: readPixel could throw an exception if the tile has not been
received. If so, now, we return a JS null value
* fix: retrieve pixels on fits HiPS bitpix=-32
* feat: a new aladin mode called TOOL_COLOR_PICKER.
* tool: showColorPickerControl: when clicking on it, enter the
TOOL_COLOR_PICKER mode. The user can move the mouse on a pixel to know
its value. With a click, the pixel value is copied to its clipboard
* fix: restore samp button to connect to a hub
* fix: call redraw when calling gotoRaDec to update instantly the
imageCanvas #208
* a new global readCanvas method on the Aladin object that
will simply read the final image Canvas. User can give a pixel coo, a
line (2 pixel coos), a rect (2 pixel coos for the box)
This method does add:
* reverseLongitude method on aladin object
* add a longitudeReversed flag in AladinOptions, when creating the
aladin view to reverse the longitude axis globally at start.
* BREAKS the HiPS options API by removing the longitudeReversed option
at the HiPS level, replacing it by a global flag on the aladin lite view
* fix: when adding two times the same survey, we could not change its
hips options
This commit also impl #191
Cells are all subdivided at the same level.
One subdivision is added if:
* the cell is on a pole
* the cell is at a frontier of a base cells (and in collignon zona)
* lockNorthUp new Aladin init option. False by default.
* setRotation is still allowed if lockNorthUp=true but when panning, the
view resets its orientation so that the north pole is up
When zooming with a mouse or a trackpad a wheel event is triggered.
Originally the fov of the viewport was changed but it happened setting
the fov is projection dependant therefore leading to big zooming effect
for TAN projection for example.
Now there is a new way of zooming which is done by setting the screen
zoom factor instead of the fov. Zooming with this factor is projection
agnostic.
With that the pr adds:
* an interpolated zooming effect moving the viewport from a start screen
zoom factor to another by following a hermite cubic interpolation
function
* bugfix: originally, multiple wheel events done shortly in time resulted in a
zooming "congestion" bug leading to a zoom effect similar to only one
isolated wheel event. Now triggering several wheel event allow to zoom
more than only one isolated.
* a new listener `wheelTriggered` allowing the user to define its own zooming.
When wheelTriggered is set, the default zooming is not executed
Targets #274
* fix: handleSelect now call selectObjects with not only the list of catalog sources but also with the footprints
* fix: View.closestFootprints: if no lineWidth was given to a footprint then it could happen that this method set it to 1px, erasing its previous undefined value
* Circle and Ellipse now behaves like PolyLine and Vector, if no linewidth is given, the one from its GraphicOverlay is taken.
Targets #274
* fix: handleSelect now call selectObjects with not only the list of catalog sources but also with the footprints
* fix: View.closestFootprints: if no lineWidth was given to a footprint then it could happen that this method set it to 1px, erasing its previous undefined value
* Circle and Ellipse now behaves like PolyLine and Vector, if no linewidth is given, the one from its GraphicOverlay is taken.
This targets #270
* Use js URL object to detect if the user gives an url
* There is important point: a user can give a path pointing towards a local HiPS. For those Aladin Lite will think the path is an ID but it is not. That is why after failing fetching the MocServer for its properties, we simply try to reconsider it as an URL so that a local HiPS can be load afterwards.
* use Utils.copy2Clipboard in contextmenu and shareview
* check for a mousedown before computing distance from the position when the mouse has been clicked
* smartphone 2 fingers pinched rotation between lon pi and 2*pi seems to have been fixed. The bug seem to be there from a long time ago.
Change heuristic for showing up the contextual menu. Before we were waiting 100ms before changing the cuts but this does not work for users doing long timed right click without moving. Now, we look for the mouse offset after rightclicking. If it exceeds an offset of 10px then the contextual menu will not open and the cuts will change instead.