12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667 |
- /**
- * @author mr.doob / http://mrdoob.com/
- * @author alteredq / http://alteredqualia.com/
- * @author szimek / https://github.com/szimek/
- */
- THREE.Texture = function ( image, mapping, wrapS, wrapT, magFilter, minFilter ) {
- this.image = image;
- this.mapping = mapping !== undefined ? mapping : new THREE.UVMapping();
- this.wrapS = wrapS !== undefined ? wrapS : THREE.ClampToEdgeWrapping;
- this.wrapT = wrapT !== undefined ? wrapT : THREE.ClampToEdgeWrapping;
- this.magFilter = magFilter !== undefined ? magFilter : THREE.LinearFilter;
- this.minFilter = minFilter !== undefined ? minFilter : THREE.LinearMipMapLinearFilter;
- this.needsUpdate = false;
- };
- THREE.Texture.prototype = {
- clone: function () {
- return new THREE.Texture( this.image, this.mapping, this.wrapS, this.wrapT, this.magFilter, this.minFilter );
- }
- };
- THREE.MultiplyOperation = 0;
- THREE.MixOperation = 1;
- // Wrapping modes
- THREE.RepeatWrapping = 0;
- THREE.ClampToEdgeWrapping = 1;
- THREE.MirroredRepeatWrapping = 2;
- // Filters
- THREE.NearestFilter = 3;
- THREE.NearestMipMapNearestFilter = 4;
- THREE.NearestMipMapLinearFilter = 5;
- THREE.LinearFilter = 6;
- THREE.LinearMipMapNearestFilter = 7;
- THREE.LinearMipMapLinearFilter = 8;
- // Types
- THREE.ByteType = 9;
- THREE.UnsignedByteType = 10;
- THREE.ShortType = 11;
- THREE.UnsignedShortType = 12;
- THREE.IntType = 13;
- THREE.UnsignedIntType = 14;
- THREE.FloatType = 15;
- // Formats
- THREE.AlphaFormat = 16;
- THREE.RGBFormat = 17;
- THREE.RGBAFormat = 18;
- THREE.LuminanceFormat = 19;
- THREE.LuminanceAlphaFormat = 20;
|