soonspacejs
Version:
soonspacejs 2.x
27 lines (26 loc) • 829 B
TypeScript
import { MeshStandardMaterial } from 'three';
/**
* 贴图是否 png 格式
* @param textureUrl
* @returns
*/
export declare const isPNG: (textureUrl?: string) => boolean;
export declare const getTextureName: (dataView: DataView, texnamelen: number, offset: number) => string;
/**
* 获取材质贴图路径
* @param modelUrl 模型资源路径
* @param name 贴图名称
*/
export declare const getTextureUrl: (url: string, path: string) => string;
/**
* 生成 sbm 纹理
* @param url
*/
export declare const generateSbmTexture: (material: MeshStandardMaterial, textureUrl: string) => void;
/**
* 生成 sbm 材质
* @param materialId
* @param arr
* @param png
*/
export declare const generateSbmMaterial: (materialId: string, arr: number[], png: boolean) => MeshStandardMaterial;