<Shader>
	<VertexShader>
		<Code>
			#version 120
			uniform mat4 Jen_ModelViewProjectionMatrix;
			uniform vec3 Jen_ViewPos;
			uniform float Jen_Time;
			
			attribute vec4 PosTimeTexAttr;
			attribute vec3 AxisAttr;
			attribute vec3 GlobalPosAttr;
			
			varying float Alpha;
			varying float TexCoord;
			
			void main( void )
			{
				vec3 vCameraForward = normalize(Jen_ViewPos - GlobalPosAttr);
				vec3 vUp = normalize(AxisAttr);
				vec3 vRight = normalize(cross(vUp, vCameraForward));
			//	vec3 vForward = cross(vRight, vUp);
				mat3 TransfMatrix = mat3(vRight,vUp,vec3(0.0,0.0,0.0));
				
			    Alpha = min((PosTimeTexAttr.z - Jen_Time)*1.5,1.0);
				TexCoord = PosTimeTexAttr.w;
				
				gl_Position = Jen_ModelViewProjectionMatrix * vec4(TransfMatrix*vec3(PosTimeTexAttr.x*(5.0-Alpha*4.0), PosTimeTexAttr.y,0.0) + GlobalPosAttr, 1.0);
			}
		</Code>
	</VertexShader>
	
	<FragmentShader>
		<Code>
			#version 120
			
			varying float Alpha;
			varying float TexCoord;
			uniform sampler2D DiffMap;
			
			void main( void )
			{
				vec4 Color = texture2D(DiffMap, vec2(TexCoord,0.5));
				gl_FragColor = vec4(Color.rgb,Color.w*Alpha);
			}
		</Code> 
	</FragmentShader>
</Shader>
