Extensions:2.4/Py/Scripts/Import/X3D VRML97

提供: wiki
< Extensions:2.4‎ | Py‎ | Scripts‎ | Import
移動先: 案内検索
VRML97 (.wrl)
Import VRML97 Files (.wrl)
UI location Group: Import
Version 0.1 - 2008.10.10 Author(s) Campbell Barton
Blender 2.48 License GPL


Executable information
File name import_web3d.py
Python modules For X3D only, a full python install (xml.dom.minidom)


Links Python & Plugins forum at Blender Artists.


Support

Introduction

This script imports lamps, cameras, primitives and meshes with materials, textures, UV coords and vertex colors.

Its aim is not to support every X3D/VRML standard since that would require supporting interactive elements and features that don't map well to blenders

Importing hand written VRML files that make use of more advanced features like PROTO's will not work, however this importer should be able to load scenes generated from other 3D software.

Usage

Instructions

n/a

Shortcuts

Editor info: List of shortcuts used by the script, if any. Mostly relevant for scripts with guis. We should of course standardize basic ones: ESC to cancel, ESC and q to quit, etc.

Configuration

Editor info: Config options available in the script's gui or via the Scripts Config Editor.

Hierarchy boolean off
When enabled, transform nodes will be imported as parent objects to the children they transform.
Circle Div int 16
The number of divisions used for circles with primitive geometry types - Sphere, Cone, and Cylinder.

Notes

n/a

Compatibility

Supports importing static VRML97 scenes, textures, lights, geometry and cameras.

Geometry


  • creaseAngle is used as blenders auto smooth
  • solid - this does not translate directly into a blender setting and is ignored, but could be used to set the drawtype.

IndexedFaceSet

  • colorPerVertex True/False
  • texCoord's
  • ccw bool flips faces when False
  • color

    Unsupported
  • convex bool (ignored)
  • normals, normalPerVertex (ignored since blender uses its own normals)

IndexedLineSet
Imported as poly curves, color is unsupported because blender cannot sure color in curves.

IndexedPointSet
Import as a mesh with verts, color is unsupported because blender cant store color per vertex.

Sphere
Supports all parameters

  • radius

Cylinder
Supports all parameters

  • radius
  • height
  • bottom
  • side
  • top

Cone
Supports all parameters

  • radius
  • height
  • bottom
  • side

Box
Supports all parameters

  • size

Appearance


Material (Supports most parameters)

  • ambientIntensity
  • diffuseColor
  • emissiveColor - converted from a color to an intensity
  • shininess
  • specularColor
  • transparency

Texture (Supports ImageTexture only)
PixelTexture and MovieTexture are not yet supported.

  • repeatS and repeatT - converted to texture repeat and image clampX/Y values.

TextureTransform (Fully supported)
This node transforms UV coords.

  • translation
  • rotation
  • scale
  • center

Lights


PointLight, DirectionalLight amd SpotLight (Supports common parameters)

  • beamWidth
  • color
  • cutOffAngle
  • direction
  • intensity
  • location
  • radius

    Unsupported
  • ambientIntensity cant be used for blenders lamps.
  • attenuation formula dosnt convert into blenders attenuation modes.
  • "on" would not be useful to support.

Other


Inline
Inline option for referencing external VRML files is supported. Note, currently this is not supported for the x3d importer.

Known Issues

  • PROTO defined types are not supported yet.
  • Importing instances is not yet supported.