WEMLoad

MLModule
genre WEMGenerate
author MeVis Medical Solutions AG
package MeVisLab/Standard
dll MLWEMModules
definition MLWEMModules.def
see also LocalWEMLoad, WEMSave
inherits from WEMGenerator
keywords surface, file, format, off, ply, stl, geom

Purpose

The module WEMLoad loads different 3D mesh file formats from disk and converts them to a WEM.

Usage

Select a filename for the 3D mesh by browsing your file system and connect the output to the input of any WEM module.

Surface models generated by other applications sometimes have a counter-clockwise ordering of nodes in the faces. If such models are loaded, all the face normals will point inwards, so do not forget to check Mirror Faces. This applies to the Stanford models, for example.

Details

The following 3D mesh file formats are currently supported by this module:

Format Description
Object File Format (*.off *.geom)

This file format was developed in 1986 at Digital Equipment Corporation’s Workstation Systems Engineering for the interchange and archiving of 3D objects. It is mostly known as GeomView Object File Format because of its use in the 3D mesh viewer with the same name.

Useful links:

http://www.geomview.org/

http://www.csit.fsu.edu/~burkardt/data/off/off.html

Wavefront (*.obj)

This file format is used by the WaveFront suite of commercial high-end animation packages. It was developed by Wavefront/Alias Technologies. The file format is also used in 3D photography.

Useful link:

http://www.csit.fsu.edu/~burkardt/data/obj/obj.html

Polygon File Format (*.ply)

This format is also known as Stanford File Format and is widely known because of the Stanford Bunny which is a scan-converted 3D mesh of a bunny. Its shape is very good for testing triangle reduction and triangle decimation algorithms due to its specific geometry.

Useful links:

http://www.csit.fsu.edu/~burkardt/data/ply/ply.html

http://astronomy.swin.edu.au/~pbourke/dataformats/ply/

http://graphics.stanford.edu/data/3Dscanrep/

Standard Tessellation Language (*.stl)

STL (Standard Tessellation Language) is a file format native to the stereolithography CAD software created by 3D Systems of Valencia, CA, USA. STL files describe only the surface geometry of a three dimensional object without any representation of color, texture or other common CAD model attributes.

Useful link:

http://en.wikipedia.org/wiki/STL_(file_format)

VRML (*.wrl) WEMLoad supports rudimentary VRML format for loading indexed triangle faces with color and normals
Winged Edge Mesh (*.wem) This format was created to support the ever growing number of WEM features. It is the only format which can hold the very specific WEM parameters. The more advanced WEM related things cannot be stored by the other public formats. Its main goal is to keep the loading process as fast as possible, and it succeeds so by loading meshes at least two to four times faster. The size on disk is also considerably smaller.

More information on the public file formats can be found at this link: http://cmp.felk.cvut.cz/~pajdla/Doc/3D.formats.html

Windows

Default Panel

../../../Modules/ML/MLWEMModules/mhelp/Images/Screenshots/WEMLoad._default.png

Output Fields

The loaded mesh in WEM format.

outWEM

name: outWEM, type: WEM(MLBase)
For accessing this object via scripting see the Scripting Reference: MLWEMWrapper.

Parameter Fields

Field Index

Auto load: Bool isProcessing: Bool Overwrite label and description: Bool
Close: Trigger Label: String progress: Float
Description: String Load: Trigger shouldComputeNormals: Bool
elapsedTime: Float loading: Bool Status: String
Filename: String Loading was successful: Bool Triangulate Faces: Bool
filenameInfo: String loadSurface: Trigger updateMode: Enum
Generate Edges: Bool Mirror Faces: Bool  
id: Integer Mode: Enum  

Visible Fields

Auto load

name: autoApply, type: Bool, default: TRUE

If checked, the module will load the WEM on changing any parameter.

see also WEMGenerator.autoApply

Load

name: apply, type: Trigger

If pressed, the given mesh is loaded as a WEM.

see also WEMGenerator.apply

Close

name: clear, type: Trigger, deprecated name: unloadSurface

If pressed, the output WEM is cleared (made empty).

see also WEMGenerator.clear

Overwrite label and description

name: overwriteLabelDescription, type: Bool, default: FALSE

If checked, label and description strings are set in the output WEM to Label and Description.

see also WEMGenerator.overwriteLabelDescription

Label

name: label, type: String

Sets a label string in the output WEM.

see also WEMGenerator.label

Description

name: description, type: String

Sets a description string in the output WEM.

see also WEMGenerator.description

Filename

name: filename, type: String

Sets the filename of the 3D mesh file on disk.

Loading was successful

name: loadingOK, type: Bool, persistent: no

Shows whether the loading was successful.

Mirror Faces

name: mirrorFaces, type: Bool, default: FALSE

If checked, the coordinates of each polygon are flipped in the mesh so that inside becomes outside.

Some meshes are stored in clockwise vertex ordering, others in counter-clockwise ordering, this option let’s you choose how the mesh is supposed to be used.

Generate Edges

name: generateEdges, type: Bool, default: TRUE

If checked, WEM edges are being generated.

Generating WEM edges takes up half the amount of loading time, so if you do not need edges for further processing or visualization, this option can be turned off. It will speed up the loading process by a factor of two! Should modules in the WEM pipeline do need edges, those will be generated on that module, with the exception of the SoWEM modules.

Triangulate Faces

name: triangulateFaces, type: Bool, default: FALSE

If checked, non-triangle faces will be triangulated after loading.

Normally this module outputs a 3D mesh with the same number and type of faces like described in the file and the file format. This can include triangles, quads or arbitrary polygons. This option will output a WEM with only triangles. Some WEM modules support arbitrary polygons, others do not.

Mode

name: triangulationMode, type: Enum, default: Strip

Defines the triangulation mode.

Values:

Title Name Description
Center node Center node In the first case a center node is calculated for the polygon which is then shared by all triangles making up the polygon.
Fan Fan A triangle fan is created.
Strip Strip A triangle strip is created.

Status

name: status, type: String, persistent: no

Shows the status of this module.

Hidden Fields

isProcessing

name: isProcessing, type: Bool, persistent: no

see WEMGenerator.isProcessing

elapsedTime

name: elapsedTime, type: Float, persistent: no

see WEMGenerator.elapsedTime

id

name: id, type: Integer, default: 0

see WEMGenerator.id

updateMode

name: updateMode, type: Enum, default: AutoUpdate, deprecated name: autoUpdate

If checked, the module loads on network start-up.

see also WEMGenerator.updateMode

shouldComputeNormals

name: shouldComputeNormals, type: Bool, default: FALSE

see WEMGenerator.shouldComputeNormals

loading

name: loading, type: Bool, persistent: no

loadSurface

name: loadSurface, type: Trigger

progress

name: progress, type: Float, persistent: no

filenameInfo

name: filenameInfo, type: String, persistent: no