INCepted Posted May 5, 2016 Share Posted May 5, 2016 Good day Dear Forum, I was trying to make a little Shader Menu for my server. Now the menu should give you the option two activate two shaders Contrast and Detail shader. Both work fine, but when I activate them at the same time I get errors. If Detail is activated, contrast wont be able to be activated. What is the problem ? I think the textures of Detail are making the errors, but what should i do, that both work at the same time ? This error repeats till I deactivate Detail Shader: Deactivating Detail, activating Contrast, deactivating and activating Detail again brings this error: And here are the script snippets of the errors: c_contrast.lua:146: myScreenSourceFull = dxCreateScreenSource( scx, scy ) c_contrast.lua:169 - 173: dxDrawImage( 0, 0, scx, scy, current1, 0, 0, 0, tocolor(255,255,255,v.MulBlend*255) ) dxDrawImage( 0, 0, scx, scy, current2, 0, 0, 0, tocolor(255,255,255,v.BloomBlend*255) ) -- Draw border texture dxDrawImage( 0, 0, scx, scy, textureVignette, 0, 0, 0, tocolor(255,255,255,v.Vignette*255) ) c_contrast.lua:234: dxSetShaderValue( modulationShader, "sExtraFrom", ExtraFrom ) I think the problem occurs because contrast needs to read the textures but detail has changed them: -- Load textures detail22Texture = dxCreateTexture(path..'media/detail22.png', "dxt3") detail58Texture = dxCreateTexture(path..'media/detail58.png', "dxt3") detail68Texture = dxCreateTexture(path..'media/detail68.png', "dxt1") detail63Texture = dxCreateTexture(path..'media/detail63.png', "dxt3") dirtyTexture = dxCreateTexture(path..'media/dirty.png', "dxt3") detail04Texture = dxCreateTexture(path..'media/detail04.png', "dxt3") detail29Texture = dxCreateTexture(path..'media/detail29.png', "dxt3") detail55Texture = dxCreateTexture(path..'media/detail55.png', "dxt3") detail35TTexture = dxCreateTexture(path..'media/detail35T.png', "dxt3") Sorry for my bad english. I'd be so thankfull if someone has the solution!! Link to comment
Captain Cody Posted May 5, 2016 Share Posted May 5, 2016 Try to change the variable names. I've noticed a few times multiple resources conflicting some times with variable names. Link to comment
INCepted Posted May 6, 2016 Author Share Posted May 6, 2016 Works perfectly, thank you! Link to comment
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now