_createFrameBuffer() {
        this._frameBuffer = this.gl.createFramebuffer();

        // cancel clear on init
        this.renderer.bindFrameBuffer(this, true);

        // if textures array is not empty it means we're restoring the context
        if(this.textures.length) {
            this.textures[0]._parent = this;
            this.textures[0]._restoreContext();
        }
        else {
            // create a texture
            const texture = new Texture(this.renderer, this._texturesOptions);

            // adds the render target as parent and adds the texture to our textures array as well
            texture.addParent(this);
        }

        // attach the texture as the first color attachment
        // this.textures[0]._sampler.texture contains our WebGLTexture object
        this.gl.framebufferTexture2D(this.gl.FRAMEBUFFER, this.gl.COLOR_ATTACHMENT0, this.gl.TEXTURE_2D, this.textures[0]._sampler.texture, 0);

        // create a depth renderbuffer
        if(this._depth) {
            this._depthBuffer = this.gl.createRenderbuffer();
            this._bindDepthBuffer();
        }

        this.renderer.bindFrameBuffer(null);
    }
Here we create our frame buffer object
     We're also adding a render buffer object to handle depth if needed
*