-
Notifications
You must be signed in to change notification settings - Fork 52
Description
I have been trying to use aladin.setOverlayImageLayer which, to my (probably very poor) understanding, should be more or less equivalent to aladin.displayJPG when used with a suitable call to A.image. However, it seems to me that setOverlayImageLayer is producing wrongly scaled images in v3.73-beta. This is illustrated by the following example
A.init.then(() => {
var aladin = A.aladin('#aladin-lite-div',
{
target: '35.24280106706162 -38.55069574272001',
fov: 0.012554299836471508,
cooFrame: 'ICRSd',
projection: 'TAN',
showReticle: false,
showGotoControl: true,
showFullscreenControl: true,
showSimbadPointerControl: true,
showShareControl: false,
realFullscreen: true,
showCooGridControl: true,
showContextMenu: true,
showSettingsControl: true,
samp: true
});
aladin.setBaseImageLayer('P/Mellinger/color');
aladin.displayJPG('https://cdn.esahubble.org/archives/images/screen/potw2050a.jpg', {
label: 'potw2050a.jpg'
}, (ra, dec, fov) => {});
aladin.setOverlayImageLayer(A.image('https://cdn.esahubble.org/archives/images/screen/potw2050a.jpg', {
name: 'potw2050a.jpg_bis',
successCallback: (ra, dec, fov, image) => {}
}));
which produces an image like this one (note the replicated, scaled down image to the bottom right):
Is this expected and I am doing something wrong, or is that a bug? Note that the image has a correct AVM astrometry.
Also, I take this opportunity to ask if aladin.displayJPG is really approximately equivalent to aladin.setOverlayImageLayer (but apparently with fewer options; for example no way to set the WCS). If so, why are there two functions to do apparently the same thing?