tex.setNeedsRefresh(true);
tex.setNeedsFilterRefresh(true);
    public void render(Spatial spat, Texture tex) {        spat.setIsRoot(true);        try {            if (pbuffer.isBufferLost()) {                LoggingSystem.getLogger().log(Level.WARNING, "PBuffer contents lost - will recreate the buffer");                deactivate();                pbuffer.destroy();                initPbuffer();            }            if (useDirectRender) {                GL11.glBindTexture(GL11.GL_TEXTURE_2D, tex.getTextureId());                pbuffer.releaseTexImage(Pbuffer.FRONT_LEFT_BUFFER);                activate();                parentRenderer.clearBuffers();                spat.onDraw(parentRenderer);                deactivate();                pbuffer.bindTexImage(Pbuffer.FRONT_LEFT_BUFFER);            } else {                activate();                parentRenderer.clearBuffers();                spat.onDraw(parentRenderer);                GL11.glBindTexture(GL11.GL_TEXTURE_2D, tex.getTextureId());                GL11.glCopyTexSubImage2D(GL11.GL_TEXTURE_2D, 0, 0, 0, 0, 0, PBUFFER_WIDTH, PBUFFER_HEIGHT);                deactivate();            }            tex.setNeedsRefresh(true);        } catch (Exception e) {            LoggingSystem.getLogger().throwing(this.getClass().toString(), "render(Spatial, Texture)", e);        }        spat.setIsRoot(false);    }