Files
aladin-lite/examples/al-cat-custom-shape.html

32 lines
871 B
HTML

<!doctype html>
<html>
<head>
<!--<link rel="stylesheet" href="./layers.css" />-->
</head>
<body>
<div id="aladin-lite-div" style="width: 1024px; height: 768px"></div>
<script type="module">
import A from '../src/js/A.js';
let aladin;
A.init.then(() => {
aladin = A.aladin('#aladin-lite-div', {survey: 'P/DSS2/red', target: 'M50', fov: 0.3});
var customImg = new Image();
customImg.onload = function() {
var cat = A.catalog({shape: customImg});
aladin.addCatalog(cat);
cat.addSources(A.source(105.69239256, -8.45235969));
cat.addSources(A.source(105.70779763, -8.31350997));
cat.addSources(A.source(105.74242906, -8.34776709));
};
customImg.src = 'https://aladin.u-strasbg.fr/AladinLite/doc/API/examples/img/star.png';
});
</script>
</body>
</html>