Search the Community

Showing results for tags 'lensrenderingpipeline'.

More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


  • HTML5 Game Coding
    • News
    • Game Showcase
    • Facebook Instant Games
    • Web Gaming Platform
    • Coding and Game Design
  • Frameworks
    • Phaser 3
    • Phaser 2
    • Pixi.js
    • Babylon.js
    • Panda 2
    • melonJS
  • General
    • General Talk
  • Business
    • Collaborations (un-paid)
    • Jobs (Hiring and Freelance)
    • Services Offered

Find results in...

Find results that contain...

Date Created

  • Start


Last Updated

  • Start


Filter by number of...


  • Start



Website URL





Found 6 results

  1. I'm trying to leverage the built in Depth of Field effect - when I attach it to my camera I get an error - attachCamerasToRenderPipeline() - >You're trying to reuse a post process not defined as reusable. I can still seem to toggle the effect on an off. I looked at the typescript code and can see that the internal effects of the LensRenderingPipeline class are indeed set to be non-reusable. The effect does seem to be behaving the way it we expect but is there anything I should be concerned about in regards to this error?
  2. Hi, I'm using a plugin Called Babylon3D that allows use the Babylon.JS on C2. Unfortunately, the plugin developer dropped the support for it and i'm trying to figure how add or enable some stuff. The plugin is based on Babylon v2.67 if i remember well. Already edited the Babylon.custom.js to get NearestSampling mode as default for 3D games in PixelArt to avoid the blur textures,etc... so if i'm going to do a 3DHD game use one and if is Pixel3D style then use the other Babylon.custom.js . Since i don't know javascript or the C2 SDk is the only way i found to add or modify the parameters i need for my game, no luck finding any C2 developer to continue with the Babylon.js plugin for C2. So, i saw the PostProcess effects like Deep Of field and others and tried to enable by default and attach to a camera editing the Babylon.custom.js without luck. What i need to add/edit to have the postprocess activated by default, or attached by default to the camera?. This is all the lensRenderingPipeline code inside Babylon.custom.js: Here is theBabylon.js version the C2 plugin uses: Any idea? thanks! EDIT: Things i tried are were here: // Finish scene.postProcessRenderPipelineManager.addPipeline(_this); if (cameras) { scene.postProcessRenderPipelineManager.attachCamerasToRenderPipeline(name, cameras); } return _this; And obviously setting numbers in the effect like _this._chromaticAberration = parameters.chromatic_aberration ? parameters.chromatic_aberration : 5; The max i achieved is see the chromatic aberration working but only one frame and then the render is frozen. Using this code after some FreeCamera parameters. var lensEffect = new BABYLON.LensRenderingPipeline('lens', {chromatic_aberration: 5.0, }, scene, 1.0, camera);
  3. Hi all ! Here's a little tweaked version of the LensRenderingPipeline demo : I've raised the grain amount, I really like what it does ! But the noise/grain is static : how would you make the noise more dynamic/moving ? I'd like the result to be more "video" than "photo". Anyone knows how to do this while keeping it simple ? Thanks !
  4. I have been trying to figure out a way to animate the focus distance of the depth of field post process but have come up empty handed. I have setup a click event that runs a set of animations changing the (arc) camera's alpha, beta, radius, position, and target. I would like to animate the dof_focus_distance to match that of the camera radius so that the selected object keeps focus. my click event: scene.onPointerDown = function(e, pickResult) { if (pickResult.hit ) { ArcAnimation(0, camera.upperBetaLimit, camera.lowerRadiusLimit, pickResult.pickedMesh.position, pickResult.pickedMesh, true); currentobj = pickResult.pickedMesh; } }; I set up the depth of field with the following: (this came for the docs at var params = { edge_blur: 1, chromatic_aberration: 0, distortion: 0, dof_focus_distance: 4000, dof_aperture: 200, grain_amount: 0 }; var lensEffect = new BABYLON.LensRenderingPipeline('lensEffects', params, scene, 1.0, camera); My animation function: var ArcAnimation = function (toAlpha, toBeta, toRadius, toPosition, obj, arc) { var keysAlpha = [], keysBeta = [], keysRadius = [], keysPosition = []; var easingFunction = new BABYLON.CubicEase(); easingFunction.setEasingMode(BABYLON.EasingFunction.EASINGMODE_EASEINOUT); var animCamAlpha = new BABYLON.Animation("animCam", "alpha", 30, BABYLON.Animation.ANIMATIONTYPE_FLOAT, BABYLON.Animation.ANIMATIONLOOPMODE_CONSTANT ); keysAlpha.push({frame: 0, value: camera.alpha}); keysAlpha.push({frame: 300, value: toAlpha}); var animCamBeta = new BABYLON.Animation("animCam", "beta", 30, BABYLON.Animation.ANIMATIONTYPE_FLOAT, BABYLON.Animation.ANIMATIONLOOPMODE_CONSTANT ); keysBeta.push({frame: 0, value: camera.beta}); if (arc) { keysBeta.push({frame: 150, value: toBeta*0.2}); } keysBeta.push({frame: 300, value: toBeta}); var animCamRadius = new BABYLON.Animation("animCam", "radius", 30, BABYLON.Animation.ANIMATIONTYPE_FLOAT, BABYLON.Animation.ANIMATIONLOOPMODE_CONSTANT ); keysRadius.push({frame: 0, value: camera.radius }); keysRadius.push({frame: 300, value: toRadius }); var animCamPosition = new BABYLON.Animation("animCam", "target", 30, BABYLON.Animation.ANIMATIONTYPE_VECTOR3 , BABYLON.Animation.ANIMATIONLOOPMODE_CONSTANT ); keysPosition.push({frame: 0, value: }); if (arc) { keysPosition.push({frame: 150, value: obj.position.add( new BABYLON.Vector3(0,obj.position.y + obj.position.y*0.5 ,0) )}); } keysPosition.push({frame: 300, value: obj.position }); animCamAlpha.setKeys(keysAlpha); animCamBeta.setKeys(keysBeta); animCamRadius.setKeys(keysRadius); animCamPosition.setKeys(keysPosition); animCamAlpha.setEasingFunction(easingFunction); animCamBeta.setEasingFunction(easingFunction); animCamRadius.setEasingFunction(easingFunction); animCamPosition.setEasingFunction(easingFunction); camera.animations.push(animCamAlpha); camera.animations.push(animCamBeta); camera.animations.push(animCamRadius); camera.animations.push(animCamPosition); scene.beginAnimation(camera, 0, 300, false, 2, function () { }); }; I attempted to animate the DOF the same but it seems that cannot be done, or I am doing it wrong. I tried like this, among other ways but this was my last attempt before wanting to rage flip my desk: var keysDofFocusDistance = [], keysDofApeture = []; var animDof = new BABYLON.Animation("animDof", 'setFocusDepth', 30, BABYLON.Animation.ANIMATIONTYPE_FLOAT, BABYLON.Animation.ANIMATIONLOOPMODE_CONSTANT); keysDofFocusDistance.push({frame: 0, value: 4000}); keysDofFocusDistance.push({frame: 100, value: toRadius}); animDof.setKeys(keysDofFocusDistance); animDof.setEasingFunction(easingFunction); lensEffect.animations.push(animDof); scene.beginAnimation(lensEffect.setFocusDepth, 0, 100, false, 2, function () { console.log("animated DOF"); }); SO, is it possible to animate the depth of field focus (or any properties) at all? Why not allow it to use an object as a focal point? I'm new to babylon so maybe I am just missing something simple. I can modify the value using lensEffect.setFocusDistance(toRadius); but I would really like to get it animated some how. thanks, Charles EDIT: here is a playground
  5. Hi, again ! Who know - where disappeared constructor? Or, may be right way for use this... Theoretically it must be...
  6. Hi gang! Sorry, but I need a little survey data. When I browse the playground for our LensRenderingPipeline with my Firefox 30, I get Firefox lock-up/crash. (playground url seen in the docs) When in IE, boggy by ok. My buddy bob... good browse in FF. So, would you like to take a survey? Browse the url with any version of Firefox, and report here if it kills your browser. No need to report successes... but if you must, please do. Thanks! Edit: Here's a skull-less alternative... still crashes my FF just fine.