This commit is contained in:
luboslenco
2024-02-05 20:57:20 +01:00
parent 632e4e905a
commit ae67dc52ec
125 changed files with 4659 additions and 4691 deletions
+3 -3
View File
@@ -14,7 +14,7 @@ class ImportTexture {
if (a.file == path) {
// Set as envmap
if (hdrAsEnvmap && path.toLowerCase().endsWith(".hdr")) {
Data.getImage(path, (image: ImageRaw) => {
Data.getImage(path, (image: image_t) => {
Base.notifyOnNextFrame(() => { // Make sure file browser process did finish
ImportEnvmap.run(path, image);
});
@@ -30,7 +30,7 @@ class ImportTexture {
let cached = Data.cachedImages.get(path) != null; // Already loaded or pink texture for missing file
if (importer == null || cached) importer = ImportTexture.defaultImporter;
importer(path, (image: ImageRaw) => {
importer(path, (image: image_t) => {
Data.cachedImages.set(path, image);
let ar = path.split(Path.sep);
let name = ar[ar.length - 1];
@@ -51,7 +51,7 @@ class ImportTexture {
});
}
static defaultImporter = (path: string, done: (img: ImageRaw)=>void) => {
static defaultImporter = (path: string, done: (img: image_t)=>void) => {
Data.getImage(path, done);
}
}