Anonymous user
Process SMIL directives in XML data: Difference between revisions
removed OpenGL and X3D and keep only SMIL
m (flag for difficulty issues, use template magic to put solution in page) |
(removed OpenGL and X3D and keep only SMIL) |
||
Line 1:
Please rename into: "process Smiled Data"
{{draft task}}
<!-- {{task|3D}} -->
In order to represent evolutions of data over time, the [http://www.w3.org/TR/SMIL/ SMIL] standard provides a solution to record the animation of data formated in XML.
* Smil: [[wp:Synchronized_Multimedia_Integration_Language|on Wikipedia]] / [http://www.w3.org/TR/SMIL/ SPECS] / [http://www.w3.org/TR/SMIL/smil-animation.html#q35 Examples]▼
The task is to create an utility that given the first Smiled XML file, would return the second one
▲*
And here is the same data with additional Smil statments that you should load, display and animate with OpenGL (or something else):▼
<lang xml><?xml version="1.0" ?>
<smil>▼
<X3D>
<Scene>
Line 16 ⟶ 19:
<Transform translation='0.0 0.0 0.0' scale='1 1 1'>
<Shape>
<Box size='2 1 2'
<animate attributeName="size" from="2 1 2"▼
to="1 2 1" begin="0s" dur="10s"/>▼
</Box>▼
<Appearance>
<Material diffuseColor='0.0 0.6 1.0'
<animate attributeName="diffuseColor" from="0.0 0.6 1.0"▼
to="1.0 0.4 0.0" begin="0s" dur="10s"/>▼
</Material>▼
</Appearance>
</Shape>
</Transform>
</Scene>
</X3D></smil></lang>
At t = 0 second here is the expected output:
▲And here is the same data with additional Smil statments that you should load, display and animate with OpenGL (or something else):
<lang xml><?xml version="1.0" ?>
▲<smil>
<X3D>
<Scene>
Line 35 ⟶ 43:
<Transform translation='0.0 0.0 0.0' scale='1 1 1'>
<Shape>
<Box size='2 1 2'/>
▲ <animate attributeName="size" from="2 1 2"
▲ to="1 2 1" begin="0s" dur="10s"/>
▲ </Box>
<Appearance>
<Material diffuseColor='0.0 0.6 1.0'/>
▲ <animate attributeName="diffuseColor" from="0.0 0.6 1.0"
▲ to="1.0 0.4 0.0" begin="0s" dur="10s"/>
▲ </Material>
</Appearance>
</Shape>
</Transform>
</Scene>
</X3D
At t = 2 second here is the expected output:
<lang xml> <Sphere radius="1"/>▼
<X3D>
<Scene>
<Viewpoint position="0 0 8" orientation="0 0 1 0"/>
<PointLight color='1 1 1' location='0 2 0'/>
<Transform translation='0.0 0.0 0.0' scale='1 1 1'>
<Shape>
<Box size='1.8 1.2 1.8'/>
<Appearance>
<Material diffuseColor='0.2 0.56 0.8'/>
</Appearance>
</Shape>
</Transform>
</Scene>
</X3D></lang>
|