three 基础库
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

23 lines
363 B

import AttributeNode from '../core/AttributeNode.js';
class UVNode extends AttributeNode {
constructor( index = 0 ) {
super( null, 'vec2' );
this.index = index;
Object.defineProperty( this, 'isUVNode', { value: true } );
}
getAttributeName( /*builder*/ ) {
return 'uv' + ( this.index > 0 ? this.index + 1 : '' );
}
}
export default UVNode;