Ambiera ForumDiscussions, Help and Support. |
|
|
|||||
|
I've stumbled across the neat plugin "Motion Blur" from GlitchedVelocity(hope I remember correct). Not sure if this question is related; but could the "Motion Blur" plugin be rewritten to be used as DOF effect instead? Also this might end up not usable depending of how resource hungry it is. Thanks for your input(s) and thoughts |
||||
|
Hi @Chris, negative, sorry - despite I also wish myself we could use real depth of field effect in CopperCube to enhance graphics. My motion blur extension on neophyte.cf uses the CopperCube Pro scene blur effect which is implemented like kind of a flat screen overlay effect eighter blurring none of everything on screen. For real DOF you would need z dimension (depth) properties of your scene objects, which may only be obtained and processed by digging into CopperCube's source code plus by including some multi-pass shader programming (one pass to check for depth values, second to apply blur to fragments according to depth values) from my point of view. |
||||
|
@hadoken thanks for the note ;/ ...also it gets so slow; so it's not really usable for WebGL |
||||
|
Learn Three.js https://threejs.org/examples/webgl_postprocessing_dof2.html |
||||
|
@Guest: Not helpful |
||||
|
Is it possible to port a threejs shader in coppercube? |
||||
|
A simple method is to use two different LODs for your textures. You can then just use "On proximity enter/leave" to "change the texture".Then create 2 versions of each texture - one at (for example) 512x512px and the other at 64x64px. The close objects will have 512x512 textures, so they will look sharp - the further objects will have 64x64 and will look blurred. This will give a cheap (but effective) depth of field effect. If you want a variable depth of field which focuses where you;re looking and blurs everything outside the field of vision, do the same thing but instead of using "on proximity" to the camera, use "shoot at the camera target every 30ms" and then move a node to the last bullet position. Place the on proximity LOD events on this node instead. So now, wherever you look, it fires a node, if the node hits something, it will change the LOD to sharp, when you look away, it will change it back to blurry. |
|