Documentation - Meshola - web based mesh content creation ;

Meshola -- web based mesh content creation

Home Log In Facebook Contact Keep Me Posted Public Meshes Source Code Articles API & Applications

API XML Documentation

The process for using the API is to create XML, send it to the API and receive the result, which is generally an FBX file but may be something else. The ShapeTemplateLib Library, available via NuGet, is the fastest way to generate XML through the classes that are defined in it. However, the XML can also be defined manually and sent via Python or any other environment that can post to the web and retrieve a file. This documentation is the reference for the XML. You can send Templates and Basic Shapes to the API and get back meshes. The Hello, Stairs sample code shows how to package and transmit the XML.

Templates

The templates can be submitted directly to the API to receive meshes.

GearBase (Preview)

The Gearbase is a gear shape

SimpleLayout (Preview)

The simplelayout is a layout of walls, holes and floor/ceiling panels. Edges and vertices form the wall panels. Panels can have holes, which are defined via a HoleGroup. A holegroup consists of some number of BoundaryRectangle, BoundaryPolygon or BoundaryEllipse outlines. The wall panels are created vertically and can intersect. Horizontal panels, used for floors and roofs, are defined in a HorizontalPanel object, and these can also have holes, defined in a HoleGroup. The scale of the rendered mesh can be controlled by the HorizontalScale and VerticalScale properties so that the resulting mesh can be generated in a size appropriate for the platform using the mesh.

SingleRoomBuilding (Preview)

The single room is a template for creating a rectangular building with a single room with a space for a door and up to 4 windows and a flat roof. This will use the simplelayout template as its basis, so it will compile to a simplelayout

StraightStairs (Preview)

The straight stairs template is a set of stairs.

Basic shapes

The basic shapes can be submitted directly to the API to receive meshes.

FlatMesh (Preview)

A FlatMesh is a basic shape, and is simply a closed non-intersecting polygon. It has a boundary, mesh properties, a relative XAxis, an offset, and possibly holes. For purposes of placing holes a panel is defined in the XY plane.The winding of the boundary determines the relative Z axis, counter clockwise winding indicates that Z is 'out' or towards the viewer looking at the panel.

Panel (Preview)

The Panel is a basic shape consisting of two FlatMesh shapes that are a 'front' and 'back' and that are connected via a connector mesh. The front and back meshes can have holes that don't connect to each other, and there can be holes that connect the front and back, so its a very versatile shape.

Data Classes

The data classes are support classes used in Basic shapes and templates. They are sent to the API as properties of basic shapes or templates but not in of themselves.

Hole

The hole in a flat mesh describes its placement and dimension. A hole is defined by a boundary and an offset from a (0,0) position on the mesh in XY space. A mesh can have any orientation, of course, but for the purposes of placing holes the mesh is positioned to an XY plane with +Z looking towards you, and the hole is defined as an offset and boundary in that XY space

HoleContainer

Hole container

Point2DContainer

This class holds an X,Y value representing a point in 2D. One use is to define edge positions in a simple layout The name used for this element to the API is the field name for whatever contains it.

Quaternion

BoundaryRoot

BoundaryEllipse

The BoundaryEllipse class is used to define an ellipse with a width and a height. This width and height are X and Y values; boundaries are defined in an XY plane that the viewer is facing, with X to the right, Y up and Z coming out. The XML name for this node will be the property name of the class that contains it

BoundaryPolygon

The BoundaryLineSegment class is used to define an list of line segments. This width and height are X and Y values; boundaries are defined in an XY plane that the viewer is facing, with X to the right, Y up and Z coming out. These segments should form a closed non-intersecting polygon and should be wound counter clockwise. A counter-clockwise triangle would be (0,0) -> (50,0) -> (25,25)

BoundaryRectangle

The BoundaryRectangle class is used to define a rectangle with a width and a height. This width and height are X and Y values; boundaries are defined in an XY plane that the viewer is facing, with X to the right, Y up and Z coming out.

Point2D

This class holds an X,Y value representing a point in 2D. One use is to define edge positions in a simple layout The name used for this element to the API is the field name for whatever contains it.

Point3D

This class holds an X,Y and Z value representing a point in 3D space The name used for this element to the API is the field name for whatever contains it.

MeshDisplayProperties

The Mesh display properties are associated with a single mesh that has a single UV. The properties include color, material name, name of texture file and which sides of the mesh to show. The name of the material will be placed into the output for use by the consumer of the mesh.

Vector3D

This class holds an X,Y and Z value representing a vector in 3D space The name used for this element to the API is the field name for whatever contains it. The Vector3D and the Point3D contain the same thing, and X Y and Z value, the difference is intent and over time there may be vector or matrix routines that will want a class that can do vector operations

ConnectedHole

A connected hole is part of a panel. It is composed of two definitions, one for the front and one for the back, and the mesh display properties for the connecting mesh

;