Add more options
This commit is contained in:
parent
d0b53678e2
commit
2481cfc3e6
14 changed files with 102 additions and 117 deletions
|
|
@ -2,16 +2,14 @@ import { vec2 } from 'gl-matrix';
|
|||
|
||||
export abstract class FrameBuffer {
|
||||
public renderScale = 1;
|
||||
public enableHighDpiRendering = false;
|
||||
|
||||
protected size = vec2.create();
|
||||
|
||||
// null means the default framebuffer
|
||||
protected frameBuffer: WebGLFramebuffer | null = null;
|
||||
|
||||
constructor(
|
||||
protected gl: WebGL2RenderingContext,
|
||||
private enableHighDpiRendering: boolean
|
||||
) {}
|
||||
constructor(protected gl: WebGL2RenderingContext) {}
|
||||
|
||||
public bindAndClear(colorInput?: WebGLTexture) {
|
||||
this.gl.bindFramebuffer(this.gl.FRAMEBUFFER, this.frameBuffer);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue