1
0
Fork 0
management/front/dkha-web-sz-main/node_modules/highlight.js/lib/languages/rsl.js

50 lines
1.6 KiB
JavaScript
Raw Normal View History

2024-01-16 21:26:16 +08:00
/*
Language: RenderMan RSL
Author: Konstantin Evdokimenko <qewerty@gmail.com>
Contributors: Shuen-Huei Guan <drake.guan@gmail.com>
Website: https://renderman.pixar.com/resources/RenderMan_20/shadingLanguage.html
Category: graphics
*/
function rsl(hljs) {
2023-12-18 13:12:25 +08:00
return {
2024-01-16 21:26:16 +08:00
name: 'RenderMan RSL',
2023-12-18 13:12:25 +08:00
keywords: {
keyword:
'float color point normal vector matrix while for if do return else break extern continue',
built_in:
'abs acos ambient area asin atan atmosphere attribute calculatenormal ceil cellnoise ' +
'clamp comp concat cos degrees depth Deriv diffuse distance Du Dv environment exp ' +
'faceforward filterstep floor format fresnel incident length lightsource log match ' +
'max min mod noise normalize ntransform opposite option phong pnoise pow printf ' +
'ptlined radians random reflect refract renderinfo round setcomp setxcomp setycomp ' +
'setzcomp shadow sign sin smoothstep specular specularbrdf spline sqrt step tan ' +
'texture textureinfo trace transform vtransform xcomp ycomp zcomp'
},
illegal: '</',
contains: [
hljs.C_LINE_COMMENT_MODE,
hljs.C_BLOCK_COMMENT_MODE,
hljs.QUOTE_STRING_MODE,
hljs.APOS_STRING_MODE,
hljs.C_NUMBER_MODE,
{
className: 'meta',
2024-01-16 21:26:16 +08:00
begin: '#',
end: '$'
2023-12-18 13:12:25 +08:00
},
{
className: 'class',
2024-01-16 21:26:16 +08:00
beginKeywords: 'surface displacement light volume imager',
end: '\\('
2023-12-18 13:12:25 +08:00
},
{
2024-01-16 21:26:16 +08:00
beginKeywords: 'illuminate illuminance gather',
end: '\\('
2023-12-18 13:12:25 +08:00
}
]
};
2024-01-16 21:26:16 +08:00
}
module.exports = rsl;