Fix cameraProj def in compositor

This commit is contained in:
luboslenco 2018-09-01 18:35:32 +02:00
parent d5682233da
commit 8bb14e766a
3 changed files with 4 additions and 8 deletions

View file

@ -47,13 +47,7 @@ uniform float time;
uniform float dynamicScale;
#endif
#ifdef _CFog
uniform vec2 cameraProj;
#endif
#ifdef _CDOF
uniform vec2 cameraProj;
#endif
#ifdef _CGlare
#ifdef _CCameraProj
uniform vec2 cameraProj;
#endif

View file

@ -70,7 +70,7 @@
{
"name": "cameraProj",
"link": "_cameraPlaneProj",
"ifdef": ["_CFog", "_CDOF", "_CGlare"]
"ifdef": ["_CCameraProj"]
},
{
"name": "lutTexture",

View file

@ -208,6 +208,8 @@ def build():
assets.add_embedded_data('luttexture.jpg')
if '_CDOF' in wrd.compo_defs or '_CFXAA' in wrd.compo_defs or '_CSharpen' in wrd.compo_defs:
wrd.compo_defs += '_CTexStep'
if '_CDOF' in wrd.compo_defs or '_CFog' in wrd.compo_defs or '_CGlare' in wrd.compo_defs:
wrd.compo_defs += '_CCameraProj'
assets.add_shader_pass('compositor_pass')
assets.add_khafile_def('rp_antialiasing={0}'.format(rpdat.rp_antialiasing))