Package com.jme3.post

Examples of com.jme3.post.FilterPostProcessor


 
  public void update(float tpf) {
    if (!isFinished()) {
      updateTimer(tpf);
      float p = getProgress();
      Vector3f tar = target.getLocalTranslation();
      Vector3f route = tar.subtract(start);
      route.multLocal(p);
      Vector3f newPos = start.add(route);
      position.setLocalTranslation(newPos);
    }
  }
View Full Code Here


        // init Camera --------------------------------
       
        cam = new Camera(settings.getWidth(), settings.getHeight());

        cam.setFrustumPerspective(45f, (float)cam.getWidth() / cam.getHeight(), 1f, 1000f);
        cam.setLocation(new Vector3f(0f, 0f, 10f));
        cam.lookAt(new Vector3f(0f, 0f, 0f), Vector3f.UNIT_Y);
       

        renderManager = new RenderManager(renderer);
        //Remy - 09/14/2010 setted the timer in the renderManager
        renderManager.setTimer(timer);
View Full Code Here

  }
 
  public void initialize(AppStateManager stateManager, Application app) {
    super.initialize(stateManager, app);
   
    test = new Planet(app.getAssetManager(), "Earth", "Textures/Planets/Earth/Earth.jpg", "Textures/Planets/Clouds/Cloud1.jpg", 60, new Vector3f(600, 0, 0), true, null);
    mapNode.attachChild(test);
   
    Planet test2 = new Planet(app.getAssetManager(), "Uriel", "Textures/Planets/Uriel/Uriel.jpg", null, 60, new Vector3f(0, 0, 600), false, null);
    mapNode.attachChild(test2);
   
    Planet test3 = new Planet(app.getAssetManager(), "Dominion", "Textures/Planets/Dominion/Dominion.jpg", null, 60, new Vector3f(-600, 0, 0), true, new Vector3f(0.4f, 0.6f, 0.7f));
    mapNode.attachChild(test3);
   
   
    /*
    Planet perun = new Planet("Perun", "perun2.jpg", 60);
View Full Code Here

              // clean destroy audio environemt
              ar.cleanup();
                stop();
            } else if (name.equals("SIMPLEAPP_CameraPos")) {
                if (cam != null) {
                    Vector3f loc = cam.getLocation();
                    Quaternion rot = cam.getRotation();
                    System.out.println("Camera Position: ("
                            + loc.x + ", " + loc.y + ", " + loc.z + ")");
                    System.out.println("Camera Rotation: " + rot);
                    System.out.println("Camera Direction: " + cam.getDirection());
View Full Code Here

  public void addBloomFilter() {
    this.enqueue(new Callable<Integer>(){

      public Integer call() throws Exception {
        if (bloomFilter == null) {
          bloomFilter = new FilterPostProcessor(assetManager);
          BloomFilter bf = new BloomFilter(BloomFilter.GlowMode.Objects);
          bf.setBloomIntensity(2.0f);
          bf.setExposurePower(1.3f);
          bloomFilter.addFilter(bf);
          @SuppressWarnings("unused")
View Full Code Here

        mainScene.attachChild(sky);

        water = new WaterFilter(rootNode, lightDir);

        FilterPostProcessor fpp = new FilterPostProcessor(assetManager);

        fpp.addFilter(water);
        BloomFilter bloom = new BloomFilter();

        bloom.setExposurePower(55);
        bloom.setBloomIntensity(1.0f);

        fpp.addFilter(bloom);
        LightScatteringFilter lsf = new LightScatteringFilter(lightDir.mult(-300));
        lsf.setLightDensity(1.0f);
        fpp.addFilter(lsf);

        DepthOfFieldFilter dof = new DepthOfFieldFilter();
        dof.setFocusDistance(0);
        dof.setFocusRange(100);
        fpp.addFilter(dof);

        fade = new FadeFilter();
        fpp.addFilter(fade);

        water.setWaveScale(0.003f);
        water.setMaxAmplitude(1f);
        water.setFoamExistence(new Vector3f(1f, 4, 0.5f));
        water.setFoamTexture((Texture2D) assetManager.loadTexture("Common/MatDefs/Water/Textures/foam2.jpg"));
View Full Code Here

    @Override
    public void simpleInitApp() {
        thisApp = this;

        fpp = new FilterPostProcessor(assetManager);

        // == Move a lot of these into the "initialise once" level === //
        bulletAppState = new BulletAppState();
        stateManager.attach(bulletAppState);
View Full Code Here

       
        mainScene.attachChild(sky);
       
        water = new WaterFilter(rootNode, lightDir);
       
        FilterPostProcessor fpp = myApp.getFpp();
       
        fpp.addFilter(water);
        BloomFilter bloom = new BloomFilter();
       
        bloom.setExposurePower(55);
        bloom.setBloomIntensity(1.0f);
       
        fpp.addFilter(bloom);
        LightScatteringFilter lsf = new LightScatteringFilter(lightDir.mult(-300));
        lsf.setLightDensity(1.0f);
        fpp.addFilter(lsf);
       
        DepthOfFieldFilter dof = new DepthOfFieldFilter();
        dof.setFocusDistance(0);
        dof.setFocusRange(100);
        fpp.addFilter(dof);
       
        water.setWaveScale(0.003f);
        water.setMaxAmplitude(1f);
        water.setFoamExistence(new Vector3f(1f, 4, 0.5f));
        water.setFoamTexture((Texture2D) assetManager.loadTexture("Common/MatDefs/Water/Textures/foam2.jpg"));
View Full Code Here

 
  public void simpleInitApp() {
   
   

    FilterPostProcessor fpp = new FilterPostProcessor(assetManager);
    SSAOFilter ssaoFilter = new SSAOFilter(12.940201f, 43.928635f,
        0.32999992f, 0.6059958f);
    fpp.addFilter(ssaoFilter);
    SSAOUI ui = new SSAOUI(inputManager, ssaoFilter);
    viewPort.addProcessor(fpp);
   
    Spatial n = assetManager
        .loadModel("scenes/create/create.j3o");
View Full Code Here

        dlsf.setLight(skyLight);
        dlsf.setLambda(0.65f);
        dlsf.setShadowIntensity(0.8f);
        dlsf.setEdgeFilteringMode(EdgeFilteringMode.Dither);
        dlsf.setEnabled(true);
        FilterPostProcessor fpp = new FilterPostProcessor(assetManager);
        fpp.addFilter(dlsf);
    Singleton.get().getSceneManager().changePostProcessor(fpp, Action.ADD);
   
//        DirectionalLightShadowRenderer dlsf = new DirectionalLightShadowRenderer(assetManager, 2048, 3);
//        dlsf.setLight(dl);
//        dlsf.setLambda(0.65f);
View Full Code Here

TOP

Related Classes of com.jme3.post.FilterPostProcessor

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.