13,212
edits
(→texture-unit: added example of 3d texture) |
(+-heading cleanup: Sentence case titles) |
||
Line 1: | Line 1: | ||
{{forum|47|Effects & Shaders}} | {{forum|47|Effects & Shaders}} | ||
{{Rendering}} | {{Rendering}} | ||
The effect framework as per version 2020.1 | The '''effect framework''' as per version 2020.1 | ||
Effects describe the graphical appearance of 3D objects and scenery in | Effects describe the graphical appearance of 3D objects and scenery in | ||
Line 23: | Line 23: | ||
FlightGear. | FlightGear. | ||
== Default | == Default effects in terrain materials and models == | ||
Effects for terrain work in this way: for each material type in | Effects for terrain work in this way: for each material type in | ||
materials.xml an effect is created that inherits from a single default | materials.xml an effect is created that inherits from a single default | ||
Line 49: | Line 49: | ||
* texture type, image, filter, wrap-s, wrap-t | * texture type, image, filter, wrap-s, wrap-t | ||
== Specifying | == Specifying custom effects == | ||
You can specify the effects that will be used by FlightGear as the | You can specify the effects that will be used by FlightGear as the | ||
base effect when it creates terrain and model effects. | base effect when it creates terrain and model effects. | ||
Line 101: | Line 101: | ||
To reload the entire effect framework including eff files, go into menu and debug and configure development extensions and reload shaders. This is broken in 2020.1 though, but works in earlier FG versions. | To reload the entire effect framework including eff files, go into menu and debug and configure development extensions and reload shaders. This is broken in 2020.1 though, but works in earlier FG versions. | ||
== The | == The XML tags of an effect == | ||
=== name === | === name === | ||
Line 541: | Line 541: | ||
See this page for more about shaders: [[Howto:Shader programming in FlightGear]] | See this page for more about shaders: [[Howto:Shader programming in FlightGear]] | ||
== Uniforms passed to shaders outside the | == Uniforms passed to shaders outside the XML effect framework == | ||
{| class="wikitable" | {| class="wikitable" |