mirror of
https://git.roussel.pro/public-website/singapore_rain_radar.git
synced 2026-02-09 02:20:17 +01:00
22 lines
572 B
JavaScript
22 lines
572 B
JavaScript
import { initImages, updateImages } from './downloader.mjs';
|
|
import { createVideo } from './video.mjs';
|
|
|
|
const IMAGE_COUNT = 12;
|
|
|
|
initImages(IMAGE_COUNT).then(() => {
|
|
console.log('Downloaded initial images successfully');
|
|
createVideo().then(() => {
|
|
console.log('Generated video successfully');
|
|
});
|
|
|
|
});
|
|
|
|
setInterval(() => {
|
|
updateImages(IMAGE_COUNT).then(() => {
|
|
console.log('Updated images successfully');
|
|
createVideo().then(() => {
|
|
console.log('Regenerated video successfully');
|
|
});
|
|
});
|
|
}, 5 * 60 * 1000);
|