UNPKG

@woosh/meep-engine

Version:

Pure JavaScript game engine. Fully featured and production ready.

22 lines (18 loc) 648 B
import { buildCubeURLs } from "./texture/cubemap/buildCubeURLs.js"; import { load_environment_map } from "./texture/cubemap/load_environment_map.js"; /** * * @param {GraphicsEngine} graphics * @param {string} folder_path * @param {string} file_extension */ export async function load_and_set_cubemap_v0(graphics, folder_path, file_extension) { const paths = buildCubeURLs(folder_path, file_extension); const { filtered } = await load_environment_map({ path: paths, renderer: graphics.renderer, original: false, filtered: true }); graphics.scene.environment = filtered; }