Howto:Shader programming in FlightGear: Difference between revisions

Jump to navigation Jump to search
no edit summary
No edit summary
No edit summary
Line 350: Line 350:
[[File:als secondary light.png|640px|thumbnail|Proof of Concept]]
[[File:als secondary light.png|640px|thumbnail|Proof of Concept]]
The ALS Landing Lights/Spotlight is a good example for showing how to incorporate a shader effect into [[Flightgear]] as it touches many parts of the visuals we see and many parts of the coding pipeline.
The ALS Landing Lights/Spotlight is a good example for showing how to incorporate a shader effect into [[Flightgear]] as it touches many parts of the visuals we see and many parts of the coding pipeline.


----------------------
----------------------
add pipeline flow here
add pipeline flow here
----------------------
----------------------


Files that are directly touched to add this effect (in alphabetical order) include
Files that are directly touched to add this effect (in alphabetical order) include
Line 359: Line 361:
airfield.eff
airfield.eff
   inherits properties from terrain-default
   inherits properties from terrain-default
   technique n="2"
   adds program shaders (technique 2)
     adds program shaders
     fragment airfield-ALS.frag & secondary_lights.frag
      fragment airfield-ALS.frag & secondary_lights.frag
  adds uniforms (technique 2)
    adds uniforms
building.eff
building.eff
   inherits properties from model-combined-deferred << model-combined
   inherits properties from model-combined-deferred << model-combined
   technique n="4"
   adds program shaders (technique 4)
     adds program shaders
     fragment model-ALS-ultra.frag & secondary_lights.frag
      fragment model-ALS-ultra.frag & secondary_lights.frag
  inherits uniforms from model-combined-deferred << model-combined
    inherits uniforms from model-combined-deferred << model-combined
model-combined.eff
model-combined.eff
   inherits properties from model-default
   inherits properties from model-default
   technique n="4"
   adds program shaders (technique 4)
    adds program shaders
    fragment model-ALS-ultra.frag & secondary_lights.frag
      fragment model-ALS-ultra.frag & secondary_lights.frag
  adds uniforms (technique 4)
    adds uniforms
model-default.eff
model-default.eff
   adds properties
   adds properties
   technique n="5"
   adds program shaders (technique 5)
     adds program shaders
     fragment model-ALS-base.frag & secondary_lights.frag
      fragment model-ALS-base.frag & secondary_lights.frag
  adds uniforms (technique 5)
    adds uniforms
runway.eff
runway.eff
   inherits properties from terrain-default
   inherits properties from terrain-default
   technique n="2"
   adds program shaders (technique 2)
     adds program shaders
     fragment runway-ALS.frag & secondary_lights.frag
      fragment runway-ALS.frag & secondary_lights.frag
  adds uniforms (technique 2)
    adds uniforms
terrain-default.eff
  adds properties
  adds program shaders (technique 3)
    fragment terrain-ALS-ultra.frag & secondary_lights.frag
  adds uniforms (technique 3)
tree.eff
adds properties
adds program shaders (technique 4 and 5)
  fragment tree-ALS.frag & secondary_lights.frag
adds uniforms (technique 4 and 5)




330

edits

Navigation menu