Jump to content

Some enhencement ideas for the posteffect system


klepto2
 Share

Recommended Posts

I have some suggestions to the posteffectsystem:

These ideas for function might make the managing of posteffects much easier:

  • RemovePostEffect(camera,index)
  • GetPostEffect(camera,index)
  • GetPostEffects(camera)
  • SetPostEffectOrder(camera,index,newindex)
  • Enable-/Disable- PostEffect(camera,index)

The editor currently lacks access to configuration of posteffects, while some already define uniforms, they currently can only be changed by code, not in the editor. As a start, i would suggest something like this:

{
    "posteffect":
    {
		"uniforms":
		[
			{
				"intensity": { "label": "Intensity", "type": "float", "default": 1.0 },
				"color": { "label": "Effect Color", "type": "vec3", "default": "1.0,0.0,1.0" }
			}
		],
        "textures":
        [
            {
                "size": [0.25, 0.25],
                "format": 37
            }
        ],
        "subpasses":
        [
            {    
                "samplers": ["PREVPASS"],
                "colorattachments": [0],
                "shader":
                {
                    "float32":
                    {
                        "fragment": "Shaders/PostEffects/GodRays.frag"
                    }
                }
            },
            {
                "samplers": ["PREVPASS", 0],
                "shader":
                {
                    "float32":
                    {
                        "fragment": "Shaders/PostEffects/GodRaysResolve.frag"
                    }
                }
            }
        ]
    }
}

This way the uniforms can be parsed by the editor and a ui can be generated. Maybe with an optional groupname to make it more clear.

  • Like 1
  • Windows 10 Pro 64-Bit-Version
  • NVIDIA Geforce 1080 TI
Link to comment
Share on other sites

  • klepto2 changed the title to Some enhencement ideas for the posteffect system

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...