What & How & Why

差别

这里会显示出您选择的修订版和当前版本之间的差别。

到此差别页面的链接

两侧同时换到之前的修订记录前一修订版
后一修订版
前一修订版
other:server:apache:rewirte [2016/09/25 15:05] haregyother:server:apache:rewirte [2018/09/24 15:30] (当前版本) – 外部编辑 127.0.0.1
行 1: 行 1:
 ====rewrite ==== ====rewrite ====
 +
 +<pre><samp>You are in an open field west of a big white house with a boarded
 +front door.
 +There is a small mailbox here.
 +
 +></samp> <kbd>open mailbox</kbd>
 +
 +<samp>Opening the mailbox reveals:
 +A leaflet.
 +
 +></samp></pre>
 +
  
 <sxh apache round 11-15> <sxh apache round 11-15>
行 39: 行 51:
 } }
 </sxh> </sxh>
-<sxh php; first-line: 89; highlight: [106,107]; title: New title attribute in action>+<sxh php>
     /**     /**
      * Render xhtml output or metadata      * Render xhtml output or metadata
行 66: 行 78:
         return true;         return true;
     }     }
 +</sxh>
 +<sxh glsl>
 +varying vec3 normal;
 +varying vec3 vertex_to_light_vector;
 + 
 +void main()
 +{
 +    // Defining The Material Colors
 +    const vec4 AmbientColor = vec4(0.1, 0.0, 0.0, 1.0);
 +    const vec4 DiffuseColor = vec4(1.0, 0.0, 0.0, 1.0);
 + 
 +    // Scaling The Input Vector To Length 1
 +    vec3 normalized_normal = normalize(normal);
 +    vec3 normalized_vertex_to_light_vector = normalize(vertex_to_light_vector);
 + 
 +    // Calculating The Diffuse Term And Clamping It To [0;1]
 +    float DiffuseTerm = clamp(dot(normal, vertex_to_light_vector), 0.0, 1.0);
 + 
 +    // Calculating The Final Color
 +    gl_FragColor = AmbientColor + DiffuseColor * DiffuseTerm;
 +}
 +</sxh>
 +<sxh bash>
 +#!/bin/bash
 +
 +echo "hello bash"
 +
 +exit 0
 </sxh> </sxh>