SpoonTheMan Posted April 19, 2013 Share Posted April 19, 2013 What code do I put in for any shader to make it toggleable? Thanks. Link to comment
SpoonTheMan Posted April 20, 2013 Author Share Posted April 20, 2013 Oh... Well, it's a lot, but here's the list anyway: fx-shader shader_car_paint_reflect shader_car_paint_reflect_lite sahder_depth_of_field shader_dynamic_sky shader_radial_blur Also, I'd like to know if there's a way to fix the antialiasing that the shader_panel resource disables. Sorry if this is a bit much, but whatever someone can help with, thanks for doing so. Edit: If someone can help me fix the antialiasing problem caused by the shader_panel, and help me get the dynamic sky (maybe the fx_shader, but I don't care for it too much) togglable, that's all I need. Thanks. Link to comment
Ren_712 Posted April 20, 2013 Share Posted April 20, 2013 The shader effects are compiled when the shader_panel starts. There are 2 effects that require readable depthbuffer - water_refract2 and depth_of_field (dBlurV.fx ,dBlurH.fx, water_ref.fx). At this point the antialiasing is turned off. The fastest solution would be to replace all the lines (in that 3 effects) with this: // Fallback technique fallback { pass P0 { // Just draw normally } } It's not a cleanest solution, but right now i don't have much time do update the resource. also in the settings xml That should disable the depth effects. The detail and radial_blur are toggable: just look in c_switch.lua for details They can also handled by shader panel. The easiest way to disable the dynamic sky would be to: removeEventHandler ( "onClientHUDRender", getRootElement (), renderSphere )removeEventHandler ( "onClientHUDRender", getRootElement (), renderTime ) removeEventHandler ( "onClientHUDRender", getRootElement (), renderSun ) destroyElement(skyBoxBoxa) skyboxa=nil When I have some more time I will update the resources. 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