Module VRML
Definitions of simple 3D graphics objects and VRML scenes containing
them
The objects are appropriate for data visualization, not for virtual
reality modelling. Scenes can be written to VRML files or visualized
immediately using a VRML browser, whose name is taken from the
environment variable VRMLVIEWER (under Unix).
This module used the original VRML definition, version 1.0. For the
newer VRML 2 or VRML97, use the module VRML2, which uses exactly the same
interface.
Example:
>>> from Scientific.Visualization.VRML import *
>>> scene = Scene([])
>>> scale = ColorScale(10.)
>>> for x in range(11):
>>> color = scale(x)
>>> scene.addObject(Cube(Vector(x, 0., 0.), 0.2,
>>> material=Material(diffuse_color = color)))
>>> scene.view()
-
- Parameters:
color (Color or str ) - a color object or a predefined color name
- Returns: Material
- a material with the 'diffuse color' attribute set to color
|
-
- Parameters:
color (Color or str ) - a color object or a predefined color name
- Returns: Material
- a material with the 'emissive color' attribute set to
color
|
_diffuse_material_dict
-
- Value:
|
_emissive_material_dict
-
- Value:
|
ex
-
- Value:
Vector(1.000000,0.000000,0.000000)
|
|
ey
-
- Value:
Vector(0.000000,1.000000,0.000000)
|
|
ez
-
- Value:
Vector(0.000000,0.000000,1.000000)
|
|