Properly set the number of samples in some of the

tests to find other filters that worked and didn't
work in the presence of AA.  (CrossHatch is broken
similarly to the way DoF was broken.)


git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@10865 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
experimental
PSp..om 11 years ago
parent 6469c739c5
commit b8071a2f50
  1. 5
      engine/src/test/jme3test/post/TestBloom.java
  2. 4
      engine/src/test/jme3test/post/TestCartoonEdge.java
  3. 6
      engine/src/test/jme3test/post/TestCrossHatch.java
  4. 4
      engine/src/test/jme3test/post/TestDepthOfField.java
  5. 4
      engine/src/test/jme3test/post/TestFog.java

@ -119,6 +119,11 @@ public class TestBloom extends SimpleApplication {
fpp=new FilterPostProcessor(assetManager); fpp=new FilterPostProcessor(assetManager);
// fpp.setNumSamples(4); // fpp.setNumSamples(4);
int numSamples = getContext().getSettings().getSamples();
if( numSamples > 0 ) {
fpp.setNumSamples(numSamples);
}
BloomFilter bloom=new BloomFilter(); BloomFilter bloom=new BloomFilter();
bloom.setDownSamplingFactor(2); bloom.setDownSamplingFactor(2);
bloom.setBlurScale(1.37f); bloom.setBlurScale(1.37f);

@ -61,6 +61,10 @@ public class TestCartoonEdge extends SimpleApplication {
if (renderer.getCaps().contains(Caps.GLSL100)){ if (renderer.getCaps().contains(Caps.GLSL100)){
fpp=new FilterPostProcessor(assetManager); fpp=new FilterPostProcessor(assetManager);
//fpp.setNumSamples(4); //fpp.setNumSamples(4);
int numSamples = getContext().getSettings().getSamples();
if( numSamples > 0 ) {
fpp.setNumSamples(numSamples);
}
CartoonEdgeFilter toon=new CartoonEdgeFilter(); CartoonEdgeFilter toon=new CartoonEdgeFilter();
toon.setEdgeColor(ColorRGBA.Yellow); toon.setEdgeColor(ColorRGBA.Yellow);
fpp.addFilter(toon); fpp.addFilter(toon);

@ -118,6 +118,12 @@ public class TestCrossHatch extends SimpleApplication {
rootNode.attachChild(sky); rootNode.attachChild(sky);
fpp=new FilterPostProcessor(assetManager); fpp=new FilterPostProcessor(assetManager);
int numSamples = getContext().getSettings().getSamples();
if( numSamples > 0 ) {
fpp.setNumSamples(numSamples);
}
CrossHatchFilter chf=new CrossHatchFilter(); CrossHatchFilter chf=new CrossHatchFilter();

@ -73,6 +73,10 @@ public class TestDepthOfField extends SimpleApplication {
fpp = new FilterPostProcessor(assetManager); fpp = new FilterPostProcessor(assetManager);
// fpp.setNumSamples(4); // fpp.setNumSamples(4);
int numSamples = getContext().getSettings().getSamples();
if( numSamples > 0 ) {
fpp.setNumSamples(numSamples);
}
dofFilter = new DepthOfFieldFilter(); dofFilter = new DepthOfFieldFilter();
dofFilter.setFocusDistance(0); dofFilter.setFocusDistance(0);

@ -98,6 +98,10 @@ public class TestFog extends SimpleApplication {
fpp=new FilterPostProcessor(assetManager); fpp=new FilterPostProcessor(assetManager);
//fpp.setNumSamples(4); //fpp.setNumSamples(4);
int numSamples = getContext().getSettings().getSamples();
if( numSamples > 0 ) {
fpp.setNumSamples(numSamples);
}
fog=new FogFilter(); fog=new FogFilter();
fog.setFogColor(new ColorRGBA(0.9f, 0.9f, 0.9f, 1.0f)); fog.setFogColor(new ColorRGBA(0.9f, 0.9f, 0.9f, 1.0f));
fog.setFogDistance(155); fog.setFogDistance(155);

Loading…
Cancel
Save