1 line
6.2 KiB
JSON
1 line
6.2 KiB
JSON
{"information_for_contributors":["This file has been converted from https://github.com/tgjones/shaders-tmLanguage/blob/master/grammars/shaderlab.json","If you want to provide a fix or improvement, please create a pull request against the original repository.","Once accepted there, we are happy to receive an update request."],"version":"https://github.com/tgjones/shaders-tmLanguage/commit/c72c8b39380ba5a86c58ceed053b5d965ebf38b3","name":"ShaderLab","scopeName":"source.shaderlab","patterns":[{"name":"comment.line.double-slash.shaderlab","begin":"//","end":"$"},{"name":"support.type.basic.shaderlab","match":"\\b(?i:Range|Float|Int|Color|Vector|2D|3D|Cube|Any)\\b"},{"include":"#numbers"},{"name":"storage.type.structure.shaderlab","match":"\\b(?i:Shader|Properties|SubShader|Pass|Category)\\b"},{"name":"support.type.propertyname.shaderlab","match":"\\b(?i:Name|Tags|Fallback|CustomEditor|Cull|ZWrite|ZTest|Offset|Blend|BlendOp|ColorMask|AlphaToMask|LOD|Lighting|Stencil|Ref|ReadMask|WriteMask|Comp|CompBack|CompFront|Fail|ZFail|UsePass|GrabPass|Dependency|Material|Diffuse|Ambient|Shininess|Specular|Emission|Fog|Mode|Density|SeparateSpecular|SetTexture|Combine|ConstantColor|Matrix|AlphaTest|ColorMaterial|BindChannels|Bind)\\b"},{"name":"support.constant.property-value.shaderlab","match":"\\b(?i:Back|Front|On|Off|[RGBA]{1,3}|AmbientAndDiffuse|Emission)\\b"},{"name":"support.constant.property-value.comparisonfunction.shaderlab","match":"\\b(?i:Less|Greater|LEqual|GEqual|Equal|NotEqual|Always|Never)\\b"},{"name":"support.constant.property-value.stenciloperation.shaderlab","match":"\\b(?i:Keep|Zero|Replace|IncrSat|DecrSat|Invert|IncrWrap|DecrWrap)\\b"},{"name":"support.constant.property-value.texturecombiners.shaderlab","match":"\\b(?i:Previous|Primary|Texture|Constant|Lerp|Double|Quad|Alpha)\\b"},{"name":"support.constant.property-value.fog.shaderlab","match":"\\b(?i:Global|Linear|Exp2|Exp)\\b"},{"name":"support.constant.property-value.bindchannels.shaderlab","match":"\\b(?i:Vertex|Normal|Tangent|TexCoord0|TexCoord1)\\b"},{"name":"support.constant.property-value.blendoperations.shaderlab","match":"\\b(?i:Add|Sub|RevSub|Min|Max|LogicalClear|LogicalSet|LogicalCopyInverted|LogicalCopy|LogicalNoop|LogicalInvert|LogicalAnd|LogicalNand|LogicalOr|LogicalNor|LogicalXor|LogicalEquiv|LogicalAndReverse|LogicalAndInverted|LogicalOrReverse|LogicalOrInverted)\\b"},{"name":"support.constant.property-value.blendfactors.shaderlab","match":"\\b(?i:One|Zero|SrcColor|SrcAlpha|DstColor|DstAlpha|OneMinusSrcColor|OneMinusSrcAlpha|OneMinusDstColor|OneMinusDstAlpha)\\b"},{"name":"support.variable.reference.shaderlab","match":"\\[([a-zA-Z_][a-zA-Z0-9_]*)\\](?!\\s*[a-zA-Z_][a-zA-Z0-9_]*\\s*\\(\")"},{"name":"meta.attribute.shaderlab","begin":"(\\[)","end":"(\\])","patterns":[{"name":"support.type.attributename.shaderlab","match":"\\G([a-zA-Z]+)\\b"},{"include":"#numbers"}]},{"name":"support.variable.declaration.shaderlab","match":"\\b([a-zA-Z_][a-zA-Z0-9_]*)\\s*\\("},{"name":"meta.cgblock","begin":"\\b(CGPROGRAM|CGINCLUDE)\\b","beginCaptures":{"1":{"name":"keyword.other"}},"end":"\\b(ENDCG)\\b","endCaptures":{"1":{"name":"keyword.other"}},"patterns":[{"include":"#hlsl-embedded"}]},{"name":"meta.hlslblock","begin":"\\b(HLSLPROGRAM|HLSLINCLUDE)\\b","beginCaptures":{"1":{"name":"keyword.other"}},"end":"\\b(ENDHLSL)\\b","endCaptures":{"1":{"name":"keyword.other"}},"patterns":[{"include":"#hlsl-embedded"}]},{"name":"string.quoted.double.shaderlab","begin":"\"","end":"\""}],"repository":{"numbers":{"patterns":[{"name":"constant.numeric.shaderlab","match":"\\b([0-9]+\\.?[0-9]*)\\b"}]},"hlsl-embedded":{"patterns":[{"include":"source.hlsl"},{"name":"storage.type.basic.shaderlab","match":"\\b(fixed([1-4](x[1-4])?)?)\\b"},{"name":"support.variable.transformations.shaderlab","match":"\\b(UNITY_MATRIX_MVP|UNITY_MATRIX_MV|UNITY_MATRIX_M|UNITY_MATRIX_V|UNITY_MATRIX_P|UNITY_MATRIX_VP|UNITY_MATRIX_T_MV|UNITY_MATRIX_I_V|UNITY_MATRIX_IT_MV|_Object2World|_World2Object|unity_ObjectToWorld|unity_WorldToObject)\\b"},{"name":"support.variable.camera.shaderlab","match":"\\b(_WorldSpace
|