@prefix :        <https://www.web3d.org/x3d/content/examples/X3dForAdvancedModeling/Animation/DEF_USE_AnimationExample.ttl#> .
@prefix owl:     <http://www.w3.org/2002/07/owl#> .
@prefix rdf:     <http://www.w3.org/1999/02/22-rdf-syntax-ns#> .
@prefix rdfs:    <http://www.w3.org/2000/01/rdf-schema#> .
@prefix schema:  <http://schema.org/> .
@prefix dcterms: <http://purl.org/dc/terms/> .
@prefix xsd:     <http://www.w3.org/2001/XMLSchema#> .
@prefix x3d:     <https://www.web3d.org/specifications/x3d-4.0.xsd#> .
@prefix x3do:    <https://www.web3d.org/specifications/X3dOntology4.0#> .

:X3D a owl:NamedIndividual, x3do:X3D ;
  x3do:hasHead :head ;
  x3do:hasScene :Scene ;
  x3do:profile 'Immersive' ;
  x3do:version '3.3' ;
  x3do:noNamespaceSchemaLocation 'https://www.web3d.org/specifications/x3d-3.3.xsd' .
:head a owl:NamedIndividual, x3do:head ;
  x3do:hasParent :X3D ;
  x3do:hasMeta :meta_1_1, :meta_1_2, :meta_1_3, :meta_1_4, :meta_1_5, :meta_1_6, :meta_1_7, :meta_1_8, :meta_1_9, :meta_1_10, :meta_1_11, :meta_1_12, :meta_1_13, :meta_1_14, :meta_1_15 .
:meta_1_1 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'DEF_USE_AnimationExample.x3d' ;
  x3do:name 'title' .
:meta_1_2 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'Illustrate how USE nodes implement copy by reference, resulting in immediate changes when original DEF node is modified. A single MasterMaterial node is animated, and changes in the parent MasterAppearance are reflected throughout the scene graph.' ;
  x3do:name 'description' .
:meta_1_3 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'Don Brutzman' ;
  x3do:name 'creator' .
:meta_1_4 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content '1 September 2024' ;
  x3do:name 'modified' .
:meta_1_5 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'DEF_USE_AnimationExampleScreenshot.png' ;
  x3do:name 'Image' .
:meta_1_6 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'X3D Specification Mantis Issue https://www.web3d.org/member-only/mantis/view.php?id=690' ;
  x3do:name 'TODO' .
:meta_1_7 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'Wikipedia: Evaluation strategy, pass by sharing https://en.wikipedia.org/wiki/Evaluation_strategy#Call_by_sharing' ;
  x3do:name 'reference' .
:meta_1_8 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'X3D 4.0 Architecture, ISO/IEC 19775-1:2023, clause 4 Concepts, 4.4.3 DEF/USE semantics' ;
  x3do:name 'specificationSection' .
:meta_1_9 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'https://www.web3d.org/specifications/X3Dv4Draft/ISO-IEC19775-1v4-IS.proof/Part01/concepts.html#DEF_USE_Semantics' ;
  x3do:name 'specificationUrl' .
:meta_1_10 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter02GeometryPrimitives/GeometryPrimitiveNodes.x3d' ;
  x3do:name 'reference' .
:meta_1_11 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'https://www.web3d.org/x3d/content/examples/X3dForAdvancedModeling/Animation/DEF_USE_AnimationExample.x3d' ;
  x3do:name 'identifier' .
:meta_1_12 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'Altova XMLSpy https://www.altova.com/xmlspy-xml-editor' ;
  x3do:name 'generator' .
:meta_1_13 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'XMLSpyPrettyPrintSpacingTextViewSettings.png' ;
  x3do:name 'reference' .
:meta_1_14 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content 'X3D-Edit 4.0 https://www.web3d.org/x3d/tools/X3D-Edit' ;
  x3do:name 'generator' .
:meta_1_15 a owl:NamedIndividual, x3do:meta ;
  x3do:hasParent :head ;
  x3do:content '../license.html' ;
  x3do:name 'license' .
:meta dcterms:title "DEF_USE_AnimationExample.x3d" .
:meta dcterms:description "Illustrate how USE nodes implement copy by reference, resulting in immediate changes when original DEF node is modified. A single MasterMaterial node is animated, and changes in the parent MasterAppearance are reflected throughout the scene graph." .
:meta dcterms:creator "Don Brutzman" .
:meta dcterms:modified "1 September 2024" .
:meta dcterms:Image "DEF_USE_AnimationExampleScreenshot.png" .
:meta dcterms:reference "Wikipedia: Evaluation strategy, pass by sharing https://en.wikipedia.org/wiki/Evaluation_strategy#Call_by_sharing" .
:meta dcterms:reference "https://www.web3d.org/x3d/content/examples/X3dForWebAuthors/Chapter02GeometryPrimitives/GeometryPrimitiveNodes.x3d" .
:meta dcterms:identifier "https://www.web3d.org/x3d/content/examples/X3dForAdvancedModeling/Animation/DEF_USE_AnimationExample.x3d" .
:meta dcterms:generator "Altova XMLSpy https://www.altova.com/xmlspy-xml-editor" .
:meta dcterms:reference "XMLSpyPrettyPrintSpacingTextViewSettings.png" .
:meta dcterms:generator "X3D-Edit 4.0 https://www.web3d.org/x3d/tools/X3D-Edit" .
:meta dcterms:license "../license.html" .
:Scene a owl:NamedIndividual, x3do:Scene ;
  x3do:hasParent :X3D ;
  x3do:hasChildren :WorldInfo_2_1, :Background_2_2, :EntryView, :TopLevelTouchSensor, :Group_2_5 .
:WorldInfo_2_1 a owl:NamedIndividual, x3do:WorldInfo ;
  x3do:hasParent :Scene ;
  x3do:title 'DEF_USE_AnimationExample.x3d' .
:Background_2_2 a owl:NamedIndividual, x3do:Background ;
  x3do:hasParent :Scene ;
  x3do:skyColor ( 0.6 0.8 0.8 ) .
:EntryView a owl:NamedIndividual, x3do:Viewpoint ;
  x3do:hasParent :Scene ;
  x3do:DEF 'EntryView' ;
  x3do:description 'DEF - USE Animation Example' ;
  x3do:position ( 0 0 13 ) .
:TopLevelTouchSensor a owl:NamedIndividual, x3do:TouchSensor ;
  x3do:hasParent :Scene ;
  x3do:DEF 'TopLevelTouchSensor' ;
  x3do:description 'select and hold to run animation' .
:Group_2_5 a owl:NamedIndividual, x3do:Group ;
  x3do:hasParent :Scene ;
  x3do:hasChildren :TransparentSelectableBox, :HighererRowTransform, :Clock, :ColorChanger, :LowerRowTransform ;
  x3do:hasROUTE :ROUTE_2_5_5, :ROUTE_2_5_6, :ROUTE_2_5_7 .
:TransparentSelectableBox a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Group_2_5 ;
  x3do:hasGeometry :Box_2_5_1_1 ;
  x3do:hasAppearance :Appearance_2_5_1_2 ;
  x3do:DEF 'TransparentSelectableBox' .
:Box_2_5_1_1 a owl:NamedIndividual, x3do:Box ;
  x3do:hasParent :TransparentSelectableBox ;
  x3do:size ( 16 8 .001 ) .
:Appearance_2_5_1_2 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :TransparentSelectableBox ;
  x3do:hasMaterial :Material_2_5_1_2_1 .
:Material_2_5_1_2_1 a owl:NamedIndividual, x3do:Material ;
  x3do:hasParent :Appearance_2_5_1_2 ;
  x3do:transparency 1 .
:HighererRowTransform a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Group_2_5 ;
  x3do:hasChildren :Transform_2_5_2_1, :Transform_2_5_2_2, :Transform_2_5_2_3, :Transform_2_5_2_4, :Transform_2_5_2_5 ;
  x3do:DEF 'HighererRowTransform' ;
  x3do:translation ( 0 1.5 0 ) .
:Transform_2_5_2_1 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :HighererRowTransform ;
  x3do:hasChildren :Shape_2_5_2_1_1, :Transform_2_5_2_1_2 ;
  x3do:translation ( -5 0 0 ) .
:Shape_2_5_2_1_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_1 ;
  x3do:hasGeometry :DefaultBox ;
  x3do:hasAppearance :MasterAppearance .
:DefaultBox a owl:NamedIndividual, x3do:Box ;
  x3do:hasParent :Shape_2_5_2_1_1 ;
  x3do:DEF 'DefaultBox' .
:MasterAppearance a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_2_1_1 ;
  x3do:hasMaterial :MasterMaterial ;
  x3do:DEF 'MasterAppearance' .
:MasterMaterial a owl:NamedIndividual, x3do:Material ;
  x3do:hasParent :MasterAppearance ;
  x3do:DEF 'MasterMaterial' ;
  x3do:diffuseColor ( 0.4 0.4 0.4 ) .
:Transform_2_5_2_1_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Transform_2_5_2_1 ;
  x3do:hasChildren :SmallDEFText ;
  x3do:translation ( 0 1.6 0 ) .
:SmallDEFText a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_1_2 ;
  x3do:hasGeometry :Text_2_5_2_1_2_1_1 ;
  x3do:hasAppearance :TextAppearance ;
  x3do:DEF 'SmallDEFText' .
:Text_2_5_2_1_2_1_1 a owl:NamedIndividual, x3do:Text ;
  x3do:hasParent :SmallDEFText ;
  x3do:hasFontStyle :SmallFontStyle ;
  x3do:string '"DEF"' .
:SmallFontStyle a owl:NamedIndividual, x3do:FontStyle ;
  x3do:hasParent :Text_2_5_2_1_2_1_1 ;
  x3do:DEF 'SmallFontStyle' ;
  x3do:justify '"MIDDLE" "MIDDLE"' ;
  x3do:size 0.5 .
:TextAppearance a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :SmallDEFText ;
  x3do:hasMaterial :Material_2_5_2_1_2_1_2_1 ;
  x3do:DEF 'TextAppearance' .
:Material_2_5_2_1_2_1_2_1 a owl:NamedIndividual, x3do:Material ;
  x3do:hasParent :TextAppearance ;
  x3do:diffuseColor ( 1 1 1 ) .
:Transform_2_5_2_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :HighererRowTransform ;
  x3do:hasChildren :Shape_2_5_2_2_1, :Transform_2_5_2_2_2 ;
  x3do:translation ( -2.5 0 0 ) .
:Shape_2_5_2_2_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_2 ;
  x3do:hasGeometry :DefaultCone ;
  x3do:hasAppearance :MasterAppearance-USE-1 .
:DefaultCone a owl:NamedIndividual, x3do:Cone ;
  x3do:hasParent :Shape_2_5_2_2_1 ;
  x3do:DEF 'DefaultCone' .
:MasterAppearance-USE-1 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_2_2_1 ;
  owl:sameAs :MasterAppearance . # DEF matching this USE
:Transform_2_5_2_2_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Transform_2_5_2_2 ;
  x3do:hasChildren :SmallUSEText ;
  x3do:translation ( 0 1.6 0 ) .
:SmallUSEText a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_2_2 ;
  x3do:hasGeometry :Text_2_5_2_2_2_1_1 ;
  x3do:hasAppearance :TextAppearance-USE-1 ;
  x3do:DEF 'SmallUSEText' .
:Text_2_5_2_2_2_1_1 a owl:NamedIndividual, x3do:Text ;
  x3do:hasParent :SmallUSEText ;
  x3do:hasFontStyle :SmallFontStyle-USE-1 ;
  x3do:string '"USE"' .
:SmallFontStyle-USE-1 a owl:NamedIndividual, x3do:FontStyle ;
  x3do:hasParent :Text_2_5_2_2_2_1_1 ;
  owl:sameAs :SmallFontStyle . # DEF matching this USE
:TextAppearance-USE-1 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :SmallUSEText ;
  owl:sameAs :TextAppearance . # DEF matching this USE
:Transform_2_5_2_3 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :HighererRowTransform ;
  x3do:hasChildren :Shape_2_5_2_3_1, :Transform_2_5_2_3_2 .
:Shape_2_5_2_3_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_3 ;
  x3do:hasGeometry :DefaultCylinder ;
  x3do:hasAppearance :MasterAppearance-USE-2 .
:DefaultCylinder a owl:NamedIndividual, x3do:Cylinder ;
  x3do:hasParent :Shape_2_5_2_3_1 ;
  x3do:DEF 'DefaultCylinder' .
:MasterAppearance-USE-2 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_2_3_1 ;
  owl:sameAs :MasterAppearance . # DEF matching this USE
:Transform_2_5_2_3_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Transform_2_5_2_3 ;
  x3do:hasChildren :SmallUSEText-USE-1 ;
  x3do:translation ( 0 1.6 0 ) .
:SmallUSEText-USE-1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_3_2 ;
  owl:sameAs :SmallUSEText . # DEF matching this USE
:Transform_2_5_2_4 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :HighererRowTransform ;
  x3do:hasChildren :Shape_2_5_2_4_1, :Transform_2_5_2_4_2 ;
  x3do:translation ( 2.5 0 0 ) .
:Shape_2_5_2_4_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_4 ;
  x3do:hasGeometry :DefaultSphere ;
  x3do:hasAppearance :MasterAppearance-USE-3 .
:DefaultSphere a owl:NamedIndividual, x3do:Sphere ;
  x3do:hasParent :Shape_2_5_2_4_1 ;
  x3do:DEF 'DefaultSphere' .
:MasterAppearance-USE-3 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_2_4_1 ;
  owl:sameAs :MasterAppearance . # DEF matching this USE
:Transform_2_5_2_4_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Transform_2_5_2_4 ;
  x3do:hasChildren :SmallUSEText-USE-2 ;
  x3do:translation ( 0 1.6 0 ) .
:SmallUSEText-USE-2 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_4_2 ;
  owl:sameAs :SmallUSEText . # DEF matching this USE
:Transform_2_5_2_5 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :HighererRowTransform ;
  x3do:hasChildren :Shape_2_5_2_5_1, :Transform_2_5_2_5_2 ;
  x3do:translation ( 4 0 0 ) .
:Shape_2_5_2_5_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_5 ;
  x3do:hasGeometry :DefaultText ;
  x3do:hasAppearance :MasterAppearance-USE-4 .
:DefaultText a owl:NamedIndividual, x3do:Text ;
  x3do:hasParent :Shape_2_5_2_5_1 ;
  x3do:hasFontStyle :DefaultFontStyle ;
  x3do:DEF 'DefaultText' ;
  x3do:string '"hello" "X3D!"' .
:DefaultFontStyle a owl:NamedIndividual, x3do:FontStyle ;
  x3do:hasParent :DefaultText ;
  x3do:DEF 'DefaultFontStyle' .
:MasterAppearance-USE-4 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_2_5_1 ;
  owl:sameAs :MasterAppearance . # DEF matching this USE
:Transform_2_5_2_5_2 a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Transform_2_5_2_5 ;
  x3do:hasChildren :SmallUSEText-USE-3 ;
  x3do:translation ( 1.2 1.6 0 ) .
:SmallUSEText-USE-3 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :Transform_2_5_2_5_2 ;
  owl:sameAs :SmallUSEText . # DEF matching this USE
:Clock a owl:NamedIndividual, x3do:TimeSensor ;
  x3do:hasParent :Group_2_5 ;
  x3do:DEF 'Clock' ;
  x3do:cycleInterval '8' ;
  x3do:enabled false ;
  x3do:loop true .
:ColorChanger a owl:NamedIndividual, x3do:ColorInterpolator ;
  x3do:hasParent :Group_2_5 ;
  x3do:DEF 'ColorChanger' ;
  x3do:key ( 0 0.5 0.5 0.75 1.0 ) ;
  x3do:keyValue ( 1 1 1 1 0 0 0 1 0 0 0 1 1 1 1 ) .
:ROUTE_2_5_5 a owl:NamedIndividual, x3do:ROUTE ;
  x3do:hasParent :Group_2_5 ;
  x3do:fromField 'isActive' ;
  x3do:fromNode 'TopLevelTouchSensor' ;
  x3do:toField 'enabled' ;
  x3do:toNode 'Clock' .
:ROUTE_2_5_6 a owl:NamedIndividual, x3do:ROUTE ;
  x3do:hasParent :Group_2_5 ;
  x3do:fromField 'fraction_changed' ;
  x3do:fromNode 'Clock' ;
  x3do:toField 'set_fraction' ;
  x3do:toNode 'ColorChanger' .
:ROUTE_2_5_7 a owl:NamedIndividual, x3do:ROUTE ;
  x3do:hasParent :Group_2_5 ;
  x3do:fromField 'value_changed' ;
  x3do:fromNode 'ColorChanger' ;
  x3do:toField 'diffuseColor' ;
  x3do:toNode 'MasterMaterial' .
:LowerRowTransform a owl:NamedIndividual, x3do:Transform ;
  x3do:hasParent :Group_2_5 ;
  x3do:hasChildren :Shape_2_5_8_1 ;
  x3do:DEF 'LowerRowTransform' ;
  x3do:translation ( 0 -2 0 ) .
:Shape_2_5_8_1 a owl:NamedIndividual, x3do:Shape ;
  x3do:hasParent :LowerRowTransform ;
  x3do:hasGeometry :UserMessage ;
  x3do:hasAppearance :Appearance_2_5_8_1_2 .
:UserMessage a owl:NamedIndividual, x3do:Text ;
  x3do:hasParent :Shape_2_5_8_1 ;
  x3do:hasFontStyle :MessageFontStyle ;
  x3do:DEF 'UserMessage' ;
  x3do:string '"ColorInterpolator modifies one Material" "in a single DEF=MasterAppearance node," "other USE nodes apply those values." "" "To animate, select and hold" "using your pointing device."' .
:MessageFontStyle a owl:NamedIndividual, x3do:FontStyle ;
  x3do:hasParent :UserMessage ;
  x3do:DEF 'MessageFontStyle' ;
  x3do:justify '"MIDDLE" "MIDDLE"' ;
  x3do:size 0.6 ;
  x3do:cssStyle 'BOLD' .
:Appearance_2_5_8_1_2 a owl:NamedIndividual, x3do:Appearance ;
  x3do:hasParent :Shape_2_5_8_1 ;
  x3do:hasMaterial :Material_2_5_8_1_2_1 .
:Material_2_5_8_1_2_1 a owl:NamedIndividual, x3do:Material ;
  x3do:hasParent :Appearance_2_5_8_1_2 ;
  x3do:diffuseColor ( 1 1 1 ) .
