Spaces:
Running
Running
File size: 826 Bytes
2b7aae2 | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | import { WebGLRenderTarget } from './WebGLRenderTarget.js';
class WebGLMultisampleRenderTarget extends WebGLRenderTarget {
constructor(width, height, options = {}) {
super(width, height, options);
this.samples = 4;
this.ignoreDepthForMultisampleCopy = options.ignoreDepth !== undefined ? options.ignoreDepth : true;
this.useRenderToTexture = options.useRenderToTexture !== undefined ? options.useRenderToTexture : false;
this.useRenderbuffer = this.useRenderToTexture === false;
}
copy(source) {
super.copy.call(this, source);
this.samples = source.samples;
this.useRenderToTexture = source.useRenderToTexture;
this.useRenderbuffer = source.useRenderbuffer;
return this;
}
}
WebGLMultisampleRenderTarget.prototype.isWebGLMultisampleRenderTarget = true;
export { WebGLMultisampleRenderTarget };
|