[name]
包含纹理实用函数的类。
方法
[method:Texture contain]( [param:Texture texture], [param:Number aspect] )
在不裁剪或拉伸纹理的情况下,将纹理在其表面内缩放到尽可能大。该方法保留了纹理的原始纵横比。类似于 CSS 中的 `object-fit: contain`。
[method:Texture cover]( [param:Texture texture], [param:Number aspect] )
将纹理缩放到尽可能小的尺寸以填充表面,不留空白。该方法保留了纹理的原始纵横比。类似于 CSS 中的 `object-fit: cover`。
[method:Texture fill]( [param:Texture texture] )
将纹理配置为默认转换。类似于 CSS 中的 `object-fit: fill`。
[method:Number getByteLength]( [param:Number width], [param:Number height], [param:Number format], [param:Number type] )
给定纹理的宽度、高度、格式和类型。确定必须使用多少个字节来表示纹理。
源代码
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]