Class: X3DShaderNode

X3D: 3.3
Component: Shaders

.nodeTypes. X3DShaderNode

This abstract node type is the base type for all node types that specify a programmable shader.

HTML Encoding and Default Values

<X3DShaderNode language='""' metadata='X3DMetadataObject' ></X3DShaderNode>




Constructor for X3DShaderNode

Name Type Argument Default Description
ctx Object <optional>
null context object, containing initial settings like namespace


These are the X3D / X3DOM fields of this node. Values should usually be received / set as strings via DOM functions (i.e., using setAttribute("myFieldName", "myFieldValue") and getAttribute("myFieldName")).
Name Type Default Value Range Inheritance Standard Description
language SFString "" ["Cg"|"GLSL"|"HLSL"|...] The language field is used to indicate to the browser which shading language is used for the source file(s). This field may be used as a hint for the browser if the shading language is not immediately determinable from the source (e.g., a generic MIME type of text/plain is returned). A browser may use this field for determining which node instance will be selected and to ignore languages that it is not capable of supporting. Three basic language types are defined for this specification and others may be optionally supported by a browser.
metadata SFNode X3DMetadataObject X3DNode Field to add metadata information