Interface Sound

All Superinterfaces:
X3DChildNode, X3DNode, X3DSoundNode
All Known Implementing Classes:
Sound

public interface Sound extends X3DSoundNode
The Sound node controls the 3D spatialization of sound playback by a child AudioClip or MovieTexture node.

Warning: this is an abstract interface that cannot be instantiated as a concrete object. Java programmers typically only need to use concrete objects provided by the org.web3d.x3d.jsail classes. X3D node tooltip: [X3DSoundNode] The Sound node controls the 3D spatialization of sound playback by a child AudioClip or MovieTexture node. Sound intensity includes stereo support, varying according to user location and view direction in the scene. Hint: if the audio source is stereo or multi-channel, channel separation is retained during playback. Warning: while providing sounds on the ground plane, ensure that the audible auralization volume is sufficiently elevated to match avatar height. Hint: X3D Sound component Figure 16.2 Sound Node Geometry, <a href="https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/sound.html#f-Soundnodegeometry" target="_blank">https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/sound.html#f-Soundnodegeometry</a> Hint: X3D Scene Authoring Hints:Audio <a href="https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#Audio" target="_blank">https://www.web3d.org/x3d/content/examples/X3dSceneAuthoringHints.html#Audio</a> Hint: Wikipedia 3D sound localization <a href="https://en.wikipedia.org/wiki/3D_sound_localization" target="_blank">https://en.wikipedia.org/wiki/3D_sound_localization</a> *


Package hint: This interface is defined by the X3D Java Language Binding Specification for the Scene Authoring Interface (SAI).
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Provide String value from inputOutput SFString field named description.
    float[]
    Provide array of 3-tuple float results from inputOutput SFVec3f field named direction.
    boolean
    Provide boolean value from inputOutput SFBool field named enabled.
    float
    Provide float value within allowed range of [0,1] from inputOutput SFFloat field named intensity.
    float[]
    Provide array of 3-tuple float results from inputOutput SFVec3f field named location.
    float
    Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named maxBack.
    float
    Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named maxFront.
    Provide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.
    float
    Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named minBack.
    float
    Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named minFront.
    float
    Provide float value within allowed range of [0,1] from inputOutput SFFloat field named priority.
    Provide org.web3d.x3d.sai.Sound.X3DSoundSourceNode instance (using a properly typed node) from inputOutput SFNode field source.
    boolean
    Provide boolean value from initializeOnly SFBool field named spatialize.
    Accessor method to assign String value to inputOutput SFString field named description.
    setDirection(float[] newValue)
    Accessor method to assign 3-tuple float array to inputOutput SFVec3f field named direction.
    setEnabled(boolean newValue)
    Accessor method to assign boolean value to inputOutput SFBool field named enabled.
    setIntensity(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named intensity.
    setLocation(float[] newValue)
    Accessor method to assign 3-tuple float array to inputOutput SFVec3f field named location.
    setMaxBack(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named maxBack.
    setMaxFront(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named maxFront.
    Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.
    setMinBack(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named minBack.
    setMinFront(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named minFront.
    setPriority(float newValue)
    Accessor method to assign float value to inputOutput SFFloat field named priority.
    Accessor method to assign org.web3d.x3d.sai.Sound.X3DSoundSourceNode instance (using a properly typed node) to inputOutput SFNode field source.
    setSpatialize(boolean newValue)
    Accessor method to assign boolean value to initializeOnly SFBool field named spatialize.
  • Method Details

    • getDescription

      String getDescription()
      Provide String value from inputOutput SFString field named description.

      Tooltip: Author-provided prose that describes intended purpose of this node. Hint: include space characters since a description is not a DEF identifier. Write short phrases that make descriptions clear and readable. Hint: many XML tools substitute XML character references for special characters automatically if needed within an attribute value (such as &#38; for & ampersand character, or &#34; for " quotation-mark character). *
      Specified by:
      getDescription in interface X3DSoundNode
      Returns:
      value of description field
    • setDescription

      Sound setDescription(String newValue)
      Accessor method to assign String value to inputOutput SFString field named description.

      Tooltip: Author-provided prose that describes intended purpose of this node. Hint: include space characters since a description is not a DEF identifier. Write short phrases that make descriptions clear and readable. Hint: many XML tools substitute XML character references for special characters automatically if needed within an attribute value (such as &#38; for & ampersand character, or &#34; for " quotation-mark character). *
      Specified by:
      setDescription in interface X3DSoundNode
      Parameters:
      newValue - is new value for the description field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getDirection

      float[] getDirection()
      Provide array of 3-tuple float results from inputOutput SFVec3f field named direction.

      Tooltip: direction of sound axis, relative to local coordinate system. *
      Returns:
      value of direction field
    • setDirection

      Sound setDirection(float[] newValue)
      Accessor method to assign 3-tuple float array to inputOutput SFVec3f field named direction.

      Tooltip: direction of sound axis, relative to local coordinate system. *
      Parameters:
      newValue - is new value for the direction field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getEnabled

      boolean getEnabled()
      Provide boolean value from inputOutput SFBool field named enabled.

      Tooltip: Enables/disables node operation. *
      Specified by:
      getEnabled in interface X3DSoundNode
      Returns:
      value of enabled field
    • setEnabled

      Sound setEnabled(boolean newValue)
      Accessor method to assign boolean value to inputOutput SFBool field named enabled.

      Tooltip: Enables/disables node operation. *
      Specified by:
      setEnabled in interface X3DSoundNode
      Parameters:
      newValue - is new value for the enabled field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getIntensity

      float getIntensity()
      Provide float value within allowed range of [0,1] from inputOutput SFFloat field named intensity.

      Tooltip: Factor [0,1] adjusting loudness (decibels) of emitted sound. *
      Returns:
      value of intensity field
    • setIntensity

      Sound setIntensity(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named intensity.

      Tooltip: Factor [0,1] adjusting loudness (decibels) of emitted sound. *
      Parameters:
      newValue - is new value for the intensity field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getLocation

      float[] getLocation()
      Provide array of 3-tuple float results from inputOutput SFVec3f field named location.

      Tooltip: Position of sound ellipsoid center, relative to local coordinate system. Hint: improve audibility by setting location='0 1.6 0' so that center height of sound ellipsoid matches typical NavigationInfo avatarSize height. *
      Returns:
      value of location field
    • setLocation

      Sound setLocation(float[] newValue)
      Accessor method to assign 3-tuple float array to inputOutput SFVec3f field named location.

      Tooltip: Position of sound ellipsoid center, relative to local coordinate system. Hint: improve audibility by setting location='0 1.6 0' so that center height of sound ellipsoid matches typical NavigationInfo avatarSize height. *
      Parameters:
      newValue - is new value for the location field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getMaxBack

      float getMaxBack()
      Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named maxBack.

      Tooltip: Outer (zero loudness)ellipsoid distance along back direction. Warning: ensure minBack &lt;= maxBack. *
      Returns:
      value of maxBack field
    • setMaxBack

      Sound setMaxBack(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named maxBack.

      Tooltip: Outer (zero loudness)ellipsoid distance along back direction. Warning: ensure minBack &lt;= maxBack. *
      Parameters:
      newValue - is new value for the maxBack field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getMaxFront

      float getMaxFront()
      Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named maxFront.

      Tooltip: Outer (zero loudness)ellipsoid distance along front direction. Warning: ensure minFront &lt;= maxFront. *
      Returns:
      value of maxFront field
    • setMaxFront

      Sound setMaxFront(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named maxFront.

      Tooltip: Outer (zero loudness)ellipsoid distance along front direction. Warning: ensure minFront &lt;= maxFront. *
      Parameters:
      newValue - is new value for the maxFront field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getMetadata

      X3DMetadataObject getMetadata()
      Provide org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) from inputOutput SFNode field metadata.

      Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node. Hint: X3D Architecture 7.2.4 Metadata <a href="https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/core.html#Metadata" target="_blank">https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/core.html#Metadata</a> *
      Specified by:
      getMetadata in interface X3DChildNode
      Specified by:
      getMetadata in interface X3DNode
      Specified by:
      getMetadata in interface X3DSoundNode
      Returns:
      value of metadata field
      See Also:
    • setMetadata

      Sound setMetadata(X3DMetadataObject newValue)
      Accessor method to assign org.web3d.x3d.sai.Core.X3DMetadataObject instance (using a properly typed node) to inputOutput SFNode field metadata.

      Tooltip: [X3DMetadataObject] Information about this node can be contained in a MetadataBoolean, MetadataDouble, MetadataFloat, MetadataInteger, MetadataString or MetadataSet node. Hint: X3D Architecture 7.2.4 Metadata <a href="https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/core.html#Metadata" target="_blank">https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof//Part01/components/core.html#Metadata</a> *
      Specified by:
      setMetadata in interface X3DChildNode
      Specified by:
      setMetadata in interface X3DNode
      Specified by:
      setMetadata in interface X3DSoundNode
      Parameters:
      newValue - is new value for the metadata field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
      See Also:
    • getMinBack

      float getMinBack()
      Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named minBack.

      Tooltip: Inner (full loudness) ellipsoid distance along back direction. Warning: ensure minBack &lt;= maxBack. *
      Returns:
      value of minBack field
    • setMinBack

      Sound setMinBack(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named minBack.

      Tooltip: Inner (full loudness) ellipsoid distance along back direction. Warning: ensure minBack &lt;= maxBack. *
      Parameters:
      newValue - is new value for the minBack field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getMinFront

      float getMinFront()
      Provide float value within allowed range of [0,infinity) from inputOutput SFFloat field named minFront.

      Tooltip: Inner (full loudness) ellipsoid distance along front direction. Warning: ensure minFront &lt;= maxFront. *
      Returns:
      value of minFront field
    • setMinFront

      Sound setMinFront(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named minFront.

      Tooltip: Inner (full loudness) ellipsoid distance along front direction. Warning: ensure minFront &lt;= maxFront. *
      Parameters:
      newValue - is new value for the minFront field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getPriority

      float getPriority()
      Provide float value within allowed range of [0,1] from inputOutput SFFloat field named priority.

      Tooltip: Player hint [0,1] if needed to choose which sounds to play. *
      Returns:
      value of priority field
    • setPriority

      Sound setPriority(float newValue)
      Accessor method to assign float value to inputOutput SFFloat field named priority.

      Tooltip: Player hint [0,1] if needed to choose which sounds to play. *
      Parameters:
      newValue - is new value for the priority field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getSource

      X3DSoundSourceNode getSource()
      Provide org.web3d.x3d.sai.Sound.X3DSoundSourceNode instance (using a properly typed node) from inputOutput SFNode field source.

      Tooltip: [X3DSoundSourceNode] sound source for the Sound node, either an AudioClip node or a MovieTexture node. Warning: if source field is not specified, the Sound node does not emit audio. *
      Returns:
      value of source field
    • setSource

      Sound setSource(X3DSoundSourceNode newValue)
      Accessor method to assign org.web3d.x3d.sai.Sound.X3DSoundSourceNode instance (using a properly typed node) to inputOutput SFNode field source.

      Tooltip: [X3DSoundSourceNode] sound source for the Sound node, either an AudioClip node or a MovieTexture node. Warning: if source field is not specified, the Sound node does not emit audio. *
      Parameters:
      newValue - is new value for the source field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).
    • getSpatialize

      boolean getSpatialize()
      Provide boolean value from initializeOnly SFBool field named spatialize.

      Tooltip: Whether to spatialize sound playback relative to viewer. Hint: only effective within the auralization volume. *
      Returns:
      value of spatialize field
    • setSpatialize

      Sound setSpatialize(boolean newValue)
      Accessor method to assign boolean value to initializeOnly SFBool field named spatialize.

      Tooltip: Whether to spatialize sound playback relative to viewer. Hint: only effective within the auralization volume. *
      Parameters:
      newValue - is new value for the spatialize field.
      Returns:
      Sound - namely this same object to allow sequential method pipelining (i.e. consecutive method invocations on the same object).