Fixed Bloom filter downsampling, broken in change 10750

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10782 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
experimental
rem..om 11 years ago
parent 8ffd1363b5
commit a14b6a3a50
  1. 9
      engine/src/core/com/jme3/post/FilterPostProcessor.java

@ -177,13 +177,18 @@ public class FilterPostProcessor implements SceneProcessor, Savable {
* @param mat * @param mat
*/ */
private void renderProcessing(Renderer r, FrameBuffer buff, Material mat) { private void renderProcessing(Renderer r, FrameBuffer buff, Material mat) {
if (buff == outputBuffer && multiView) { if (buff == outputBuffer) {
viewPort.getCamera().resize(originalWidth, originalHeight, false); viewPort.getCamera().resize(originalWidth, originalHeight, false);
viewPort.getCamera().setViewPort(left, right, bottom, top); viewPort.getCamera().setViewPort(left, right, bottom, top);
viewPort.getCamera().update(); viewPort.getCamera().update();
renderManager.setCamera( viewPort.getCamera(), false); renderManager.setCamera( viewPort.getCamera(), false);
}else{
viewPort.getCamera().resize(buff.getWidth(), buff.getHeight(), false);
viewPort.getCamera().setViewPort(0, 1, 0, 1);
viewPort.getCamera().update();
renderManager.setCamera( viewPort.getCamera(), false);
} }
if (mat.getAdditionalRenderState().isDepthWrite()) { if (mat.getAdditionalRenderState().isDepthWrite()) {
mat.getAdditionalRenderState().setDepthTest(false); mat.getAdditionalRenderState().setDepthTest(false);
mat.getAdditionalRenderState().setDepthWrite(false); mat.getAdditionalRenderState().setDepthWrite(false);

Loading…
Cancel
Save