Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | Related Pages

A48::Edge Class Reference

The Edge class represents the edge topological entity of the 4-8 mesh. More...

#include <edge.h>

Inheritance diagram for A48::Edge:

Inheritance graph
[legend]
Collaboration diagram for A48::Edge:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 Edge (Vertex *p0, Vertex *p1)
Hedgehedge (int i)
Vertexorg ()
 Returns the origin vertex.

Vertexdst ()
 Returns the end vertex.

int level ()
 Returns the edge resolution level.

bool is_bdry ()
 Returns true if the edge belongs to mesh border, else return false.

bool is_subdiv ()
 Returns true if the edge is a subdivision edge, else return false.


Private Attributes

Hedge h_ [2]
 Two half-edges. One for each face use.


Detailed Description

The Edge class represents the edge topological entity of the 4-8 mesh.

This class inherits the Markable class properties (used to convert a general mesh into a triangulated quadrangulation). The Edge class also inherits the MxHeapable class properties. The MxHeapable class is subclass of MxHeap that is a component of the priority_queue class. The MxHeap class is used to refine and simplify schemes of the mesh 4-8.

Definition at line 98 of file edge.h.


Constructor & Destructor Documentation

Edge::Edge Vertex p0,
Vertex p1
 

Updates the vertices of the adge. Also updates the half-edge fields.

Parameters:
p0 Pointer to origin vertex.
p1 Pointer to end vertex.

Definition at line 19 of file edge.cpp.

References h_, A48::Hedge::set_edge(), A48::Hedge::set_face(), A48::Hedge::set_next(), and A48::Hedge::set_org().

00020 { 00021 h_[0].set_org(p0); h_[1].set_org(p1); 00022 h_[0].set_face(NULL); h_[1].set_face(NULL);; 00023 h_[0].set_next(NULL); h_[1].set_next(NULL); 00024 h_[0].set_edge(this); h_[1].set_edge(this); 00025 }


Member Function Documentation

Hedge * Edge::hedge int  i  ) 
 

Returns a half-edge specified by the index i. i=0 half-edge of the origin vertex. i=1 half-edge if the end vertex.

Parameters:
i Index of the half-edge.
Returns:
half-edge of the edge.

Definition at line 34 of file edge.cpp.

References h_.

Referenced by A48::Mesh::adapt_refine(), A48::Mesh::add_edge(), A48::Mesh::is_triquad(), A48::Mesh::make_triquad(), A48::Hedge::mate(), A48::Mesh::update_ref_front(), and A48::Mesh::update_simpl_front().

00035 { 00036 switch (i) { 00037 case 0: return &h_[0]; 00038 case 1: return &h_[1]; 00039 } 00040 throw Error("edge n"); 00041 }

bool A48::Edge::is_bdry  )  [inline]
 

Returns true if the edge belongs to mesh border, else return false.

Returns:
boolean type (true or false).

Definition at line 122 of file edge.h.

References A48::Hedge::face(), and h_.

Referenced by A48::Vertex::is_bdry(), A48::Hedge::is_bdry(), and A48::Mesh::is_triquad().

00122 { return (h_[0].face() == NULL || h_[1].face() == NULL); }

bool A48::Edge::is_subdiv  )  [inline]
 

Returns true if the edge is a subdivision edge, else return false.

The edge is a subdiv edge if its half-edges are subdiv half-edges.

Definition at line 127 of file edge.h.

References h_, and A48::Hedge::is_subdiv_itself().

Referenced by A48::Mesh::update_ref_front().

00127 { return (h_[0].is_subdiv_itself() || h_[1].is_subdiv_itself()); }


The documentation for this class was generated from the following files:
Generated on Mon Oct 11 19:32:35 2004 for A48 by doxygen 1.3.7