Warning, /frameworks/syntax-highlighting/autotests/folding/highlight.glsl.fold is written in an unsupported language. File is not indexed.

0001 // This is a test file for the Katepart GLSL Syntax Highlighting.
0002 
0003 normal text
0004 // this is a single-line comment
0005 normal text
0006 <beginfold id='1'>/*</beginfold id='1'> this
0007 is a multi-line 
0008 comment <endfold id='1'>*/</endfold id='1'>
0009 normal text
0010 
0011 some_symbol.some_member;
0012 some_symbol.some_member_function();
0013 some_function();
0014 
0015 // this is a function
0016 void main()
0017 <beginfold id='2'>{</beginfold id='2'>
0018         float f = 1.4e3; // decimal float literal
0019         int i1 = 2884;   // decimal int literal
0020         int i2 = 0x44;   // hex int literal
0021         int i3 = 0456;   // octal int literal
0022 <endfold id='2'>}</endfold id='2'>
0023 
0024 // this is a structure
0025 struct some_struct
0026 <beginfold id='2'>{</beginfold id='2'>
0027         vec3 some_member_vector;
0028 <endfold id='2'>}</endfold id='2'>;
0029 
0030 # this is 
0031 #preprocessor code
0032 
0033 // all keywords
0034 break continue do for while
0035 if else
0036 true false
0037 discard return
0038 struct
0039 
0040 // all basic types
0041 float int void bool
0042 mat2 mat3 mat4
0043 vec2 vec3 vec4
0044 ivec2 ivec3 ivec4
0045 bvec2 bvec3 bvec4
0046 sampler1D sampler2D sampler3D
0047 samplerCube sampler1DShadow sampler1DShadow
0048 
0049 // all type qualifiers
0050 attribute const uniform varying
0051 in out inout
0052 
0053 // attensions:
0054 // FIXME
0055 // TODO
0056 // BUG
0057 
0058 // some of the std functions
0059 radians degrees sin cos tan asin acos atan
0060 
0061 // some of the std variables
0062 gl_Position gl_PointSize gl_ClipVertex
0063 
0064 #version 330 core
0065 
0066 // single line comment
0067 
0068 <beginfold id='1'>/*</beginfold id='1'> single line commonet <endfold id='1'>*/</endfold id='1'>
0069 
0070 <beginfold id='1'>/*</beginfold id='1'>
0071  multi line comment
0072  <endfold id='1'>*/</endfold id='1'>
0073 
0074 in ColorFormat <beginfold id='2'>{</beginfold id='2'>
0075     vec3 color;
0076 <endfold id='2'>}</endfold id='2'> fs_in;
0077 
0078 out vec4 fragColor;
0079 
0080 vec3 fun(const in vec3 foo) <beginfold id='2'>{</beginfold id='2'>
0081     foo[2] = foo.x;
0082 
0083     return foo;
0084 <endfold id='2'>}</endfold id='2'>
0085 
0086 void main()
0087 <beginfold id='2'>{</beginfold id='2'>
0088     fragColor = vec4( fs_in.color, 1.0 );
0089 <endfold id='2'>}</endfold id='2'>