$search

edu::tum::cs::vis::model::util::Mesh Class Reference

Inheritance diagram for edu::tum::cs::vis::model::util::Mesh:
Inheritance graph
[legend]

List of all members.

Public Member Functions

void drawBoundingBox (PGraphics g)
void drawLines (PGraphics g, Color overrideColor)
void drawTriangles (PGraphics g, Color overrideColor)
float getDepth ()
float getHeight ()
void getIntersectedTriangles (final Point3f rayStart, final Point3f rayEnd, final ArrayList< IntersectedTriangle > intersectedTriangles)
ArrayList< LinegetLines ()
Float getMaxX ()
Float getMaxY ()
Float getMaxZ ()
Float getMinX ()
Float getMinY ()
Float getMinZ ()
String getTextureBasePath ()
ArrayList< TrianglegetTriangles ()
float getWidth ()
void resetMinMaxValues ()
void setLines (ArrayList< Line > lines)
void setTextureBasePath (String textureBasePath)
void setTriangles (ArrayList< Triangle > triangles)

Protected Attributes

Float maxX = null
Float maxY = null
Float maxZ = null
Float minX = null
Float minY = null
Float minZ = null

Private Member Functions

void setTextureImage ()

Private Attributes

ArrayList< Linelines = new ArrayList<Line>()
String textureBasePath
boolean texturesInitialized = false
ArrayList< Triangletriangles = new ArrayList<Triangle>()

Static Private Attributes

static final long serialVersionUID = -2761386921853967131L

Detailed Description

A Mesh contains list of Triangles and Lines which represent an Object.

See also:
Triangle
Line
Author:
Stefan Profanter

Definition at line 36 of file Mesh.java.


Member Function Documentation

void edu::tum::cs::vis::model::util::Mesh::drawBoundingBox ( PGraphics  g  )  [inline]

Draws the bounding box around the model with the current style

Parameters:
g Graphics context

Definition at line 93 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::drawLines ( PGraphics  g,
Color  overrideColor 
) [inline]

Draw the lines list to the applet

Parameters:
g Applet to draw on
overrideColor override the draw color an texture. Draw whole object in the given color if != null

Definition at line 115 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::drawTriangles ( PGraphics  g,
Color  overrideColor 
) [inline]

Draw the triangles list to the applet

Parameters:
g Graphics to draw on
overrideColor override the draw color an texture. Draw whole object in the given color if != null

Definition at line 131 of file Mesh.java.

float edu::tum::cs::vis::model::util::Mesh::getDepth (  )  [inline]

Returns the depth of the model by searching the biggest distance on the z-axis between the vectors.

Returns:
float as depth of the model

Definition at line 147 of file Mesh.java.

float edu::tum::cs::vis::model::util::Mesh::getHeight (  )  [inline]

Returns the height of the model by searching the biggest distance on the y-axis between the vectors.

Returns:
float as height of the model

Definition at line 179 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::getIntersectedTriangles ( final Point3f  rayStart,
final Point3f  rayEnd,
final ArrayList< IntersectedTriangle intersectedTriangles 
) [inline]

Searches all triangles which intersect the given ray (rayStart, rayEnd) and adds them to intersectedTriangles. Not only the segment between rayStart and rayEnd is checked but the whole ray from -infinity to +infinity.

Parameters:
rayStart start point of the ray.
rayEnd end point of the ray.
intersectedTriangles list where to add intersecting triangles

Definition at line 217 of file Mesh.java.

ArrayList<Line> edu::tum::cs::vis::model::util::Mesh::getLines (  )  [inline]

Get all lines of this mesh

Returns:
the lines

Definition at line 233 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMaxX (  )  [inline]

Set maximum x coordinate of this mesh. No coordinate of all its children should be bigger than this value. Used for drawing a bounding box.

Returns:
maximum x

Definition at line 243 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMaxY (  )  [inline]

Set maximum y coordinate of this mesh. No coordinate of all its children should be bigger than this value. Used for drawing a bounding box.

Returns:
maximum y

Definition at line 255 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMaxZ (  )  [inline]

Set maximum z coordinate of this mesh. No coordinate of all its children should be bigger than this value. Used for drawing a bounding box.

Returns:
maximum z

Definition at line 267 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMinX (  )  [inline]

Set minimum x coordinate of this mesh. No coordinate of all its children should be smaller than this value. Used for drawing a bounding box.

Returns:
minimum x

Definition at line 279 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMinY (  )  [inline]

Set minimum y coordinate of this mesh. No coordinate of all its children should be smaller than this value. Used for drawing a bounding box.

Returns:
minimum y

Definition at line 291 of file Mesh.java.

Float edu::tum::cs::vis::model::util::Mesh::getMinZ (  )  [inline]

Set minimum z coordinate of this mesh. No coordinate of all its children should be smaller than this value. Used for drawing a bounding box.

Returns:
minimum z

Definition at line 303 of file Mesh.java.

String edu::tum::cs::vis::model::util::Mesh::getTextureBasePath (  )  [inline]

Return base path for relative paths of texture images.

Returns:
the base path

Definition at line 314 of file Mesh.java.

ArrayList<Triangle> edu::tum::cs::vis::model::util::Mesh::getTriangles (  )  [inline]

Get all triangles of this mesh

Returns:
the triangles

Definition at line 323 of file Mesh.java.

float edu::tum::cs::vis::model::util::Mesh::getWidth (  )  [inline]

Returns the width of the model by searching the biggest distance on the x-axis between the vectors.

Returns:
float as width of the model

Definition at line 333 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::resetMinMaxValues (  )  [inline]

Set minX,maxX, minY,maxY, minZ, maxZ to null to force recalculation when they are accessed next time

Definition at line 363 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::setLines ( ArrayList< Line lines  )  [inline]

Set lines array of this mesh.

Parameters:
lines the lines to set

Definition at line 373 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::setTextureBasePath ( String  textureBasePath  )  [inline]

Set base path for relative paths of texture images.

Parameters:
textureBasePath the base path

Definition at line 383 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::setTextureImage (  )  [inline, private]

Only used for initialization! per definition is: textureProcessing x = textureSketchup x * picture.width textureProcessing y = picture.height - textureSketchup y * picture.height it also creates an PImage to each Triangle (if it contains any Texture)

Definition at line 392 of file Mesh.java.

void edu::tum::cs::vis::model::util::Mesh::setTriangles ( ArrayList< Triangle triangles  )  [inline]

Set triangles array of this mesh

Parameters:
triangles the triangles to set

Definition at line 472 of file Mesh.java.


Member Data Documentation

ArrayList<Line> edu::tum::cs::vis::model::util::Mesh::lines = new ArrayList<Line>() [private]

List of all lines parsed from file

Definition at line 85 of file Mesh.java.

Maximum x-position of model

Definition at line 50 of file Mesh.java.

Maximum y-position of model

Definition at line 58 of file Mesh.java.

Maximum z-position of model

Definition at line 66 of file Mesh.java.

Minimum x-position of model

Definition at line 46 of file Mesh.java.

Minimum y-position of model

Definition at line 54 of file Mesh.java.

Minimum z-position of model

Definition at line 62 of file Mesh.java.

final long edu::tum::cs::vis::model::util::Mesh::serialVersionUID = -2761386921853967131L [static, private]

auto generated

Definition at line 41 of file Mesh.java.

Base path for relative paths in texture filenames.

Definition at line 76 of file Mesh.java.

Is false until setTextureImage is called and the textures of all triangles are initialized.

Definition at line 71 of file Mesh.java.

ArrayList<Triangle> edu::tum::cs::vis::model::util::Mesh::triangles = new ArrayList<Triangle>() [private]

List of all triangles parsed from file

Definition at line 80 of file Mesh.java.


The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Properties Friends


knowrob_cad_parser
Author(s): Stefan Profanter
autogenerated on Tue Mar 5 12:15:34 2013