SpotLight

Element Information

Model

Attributes

QName Type Fixed Default Use Inheritable Annotation
DEF xs:ID optional
USE xs:IDREF optional
ambientIntensity intensityType 0 optional
attenuation SFVec3f 1 0 0 optional
beamWidth restriction of SFFloat 0.7854 optional
class xs:NMTOKENS optional
color SFColor 1 1 1 optional
containerField xs:NMTOKEN children optional
cutOffAngle restriction of SFFloat 1.570796 optional
direction SFVec3f 0 0 -1 optional
global SFBool true optional
intensity intensityType 1 optional
location SFVec3f 0 0 0 optional
on SFBool true optional
radius restriction of SFFloat 100 optional

Used By

Source

<xs:element name="SpotLight">
  <xs:annotation>
    <xs:appinfo>
      <xs:attribute name="componentName" type="xs:NMTOKEN" fixed="Lighting"/>
      <xs:attribute name="componentLevel" type="xs:positiveInteger" fixed="2"/>Linear attenuation may occur at level 2, full support at level 3.</xs:appinfo>
    <xs:documentation source="http://www.web3d.org/documents/specifications/19775-1/V3.3/Part01/components/lighting.html#SpotLight"/>
  </xs:annotation>
  <xs:complexType>
    <xs:complexContent>
      <xs:extension base="X3DLightNode">
        <xs:attribute name="attenuation" type="SFVec3f" default="1 0 0">
          <xs:annotation>
            <xs:appinfo>
              <xs:minInclusive value="0"/>
            </xs:appinfo>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="beamWidth" default="0.7854">
          <xs:annotation>
            <xs:appinfo>
              <xs:attribute name="componentName" type="xs:NMTOKEN" fixed="Lighting"/>
              <xs:attribute name="componentLevel" type="xs:positiveInteger" fixed="3"/>
            </xs:appinfo>
          </xs:annotation>
          <xs:simpleType>
            <xs:restriction base="SFFloat">
              <xs:minExclusive value="0"/>
              <xs:maxInclusive value="1.570796"/>
            </xs:restriction>
          </xs:simpleType>
        </xs:attribute>
        <xs:attribute name="cutOffAngle" default="1.570796">
          <xs:simpleType>
            <xs:restriction base="SFFloat">
              <xs:minExclusive value="0"/>
              <xs:maxInclusive value="1.570796"/>
            </xs:restriction>
          </xs:simpleType>
        </xs:attribute>
        <xs:attribute name="direction" type="SFVec3f" default="0 0 -1"/>
        <xs:attribute name="location" type="SFVec3f" default="0 0 0"/>
        <xs:attribute name="radius" default="100">
          <xs:annotation>
            <xs:appinfo>
              <xs:attribute name="componentName" type="xs:NMTOKEN" fixed="Lighting"/>
              <xs:attribute name="componentLevel" type="xs:positiveInteger" fixed="3"/>
            </xs:appinfo>
          </xs:annotation>
          <xs:simpleType>
            <xs:restriction base="SFFloat">
              <xs:minInclusive value="0"/>
            </xs:restriction>
          </xs:simpleType>
        </xs:attribute>
        <xs:attribute name="global" type="SFBool" default="true"/>
        <xs:attribute name="containerField" type="xs:NMTOKEN" default="children"/>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>
</xs:element>

Sample