Itasca C++ Interface
Loading...
Searching...
No Matches
igeomedge.h
Go to the documentation of this file.
1#pragma once
2
8#include "base/src/baseqt.h"
9#include "ilinktype.h"
10
11namespace itasca {
12 class IThing;
13}
14
15namespace itascaxd {
16 using namespace itasca;
17
18 class IGeomPoint;
19 class IGeomPoly;
20 class GeomBase;
21
24 class IGeomEdge {
25 public:
27 inline static const TType type_ = 0x4c815bcc;
28
30 virtual IThing * getIThing()=0;
32 virtual const IThing * getIThing() const=0;
33
35 virtual IGeomPoint * getPoint(uint32 end)=0;
37 virtual const IGeomPoint *getPoint(uint32 end) const=0;
40 virtual void setPoint(IGeomPoint *point,uint32 end)=0;
42 virtual bool isValid() const=0;
44 virtual bool isFake() const=0;
46 virtual DVect getCentroid() const=0;
48 virtual double getLength() const=0;
50 virtual DVect getDirection() const=0;
52 virtual DVect getVector() const=0;
54 virtual DVect getClosestPoint(const DVect &pos) const=0;
55
57 virtual CLinkType<IGeomEdge> getNext(uint32 end) const=0;
59 virtual LinkType<IGeomEdge> getNext(uint32 end)=0;
61 virtual CLinkType<IGeomPoly> getStart() const=0;
65 virtual int getPolyOrder() const=0;
67 virtual const GeomBase * getGeomBase() const=0;
69 virtual DVect convertToGlobal(double u) const =0;
71 virtual double convertToLocal(const DVect &pos) const =0;
72 };
73} // namespace itascaxd
74// EoF
All default base headers if Qt is being used.
Base class for items that will be stored in containers.
Definition ithing.h:30
Interface for a user-defined geometric edge, defined as the line between two IGeomPoint objects.
Definition igeomedge.h:24
virtual bool isFake() const =0
Returns true if the edge is fake meaning that the edge exists and valid but user should not be able t...
virtual IThing * getIThing()=0
Return an IThing interface for this object.
virtual DVect getDirection() const =0
Returns the unit vector from end 0 to end 1. Returns DVect(0) if not valid.
virtual const IGeomPoint * getPoint(uint32 end) const =0
Returns a pointer to the IGeomPoint associated with end 0 or 1. Returns 0 if end > 1....
virtual DVect getCentroid() const =0
Returns the centroid of the edge.
virtual LinkType< IGeomPoly > getStart()=0
Returns an interface to a LinkType<> object, a pointer to the first object in the linked list.
virtual DVect getVector() const =0
Returns the vector from end 0 to end 1. Return DVect(0) if not valid.
virtual LinkType< IGeomEdge > getNext(uint32 end)=0
Returns an interface to a LinkType<> object, a pointer to the next object in the linked list.
virtual DVect getClosestPoint(const DVect &pos) const =0
Returns the point on the edge closes to the point pos. Returns DVect(0) if not valid.
virtual CLinkType< IGeomPoly > getStart() const =0
Returns an interface to a CLinkType<> object, a const pointer to the first object in the linked list.
virtual DVect convertToGlobal(double u) const =0
Convert to global coordinate the point on edge. If u = 0.0 it will be position of point(0),...
virtual int getPolyOrder() const =0
Returns number of polygon faces attached.
virtual double convertToLocal(const DVect &pos) const =0
Convert o local edge coordinate.
virtual CLinkType< IGeomEdge > getNext(uint32 end) const =0
Returns an interface to a CLinkType<> object, a const pointer to the next object in the linked list.
virtual double getLength() const =0
Returns the distance between the two IGeomPoint objects, return 0.0 if not valid.
virtual const GeomBase * getGeomBase() const =0
Return const GeomBase.
virtual const IThing * getIThing() const =0
Return a const IThing interface for this object.
virtual void setPoint(IGeomPoint *point, uint32 end)=0
virtual bool isValid() const =0
Returns true if the edge is currently valid, that is if both ends (0 and 1) are assigned to a non-nul...
static const TType type_
The type identification number for this class, for use in convert_cast() and convert_getcast().
Definition igeomedge.h:27
virtual IGeomPoint * getPoint(uint32 end)=0
Returns a pointer to the IGeomPoint associated with end 0 or 1. Returns 0 if end > 1....
Interface for a user-defined geometric point.
Definition igeompoint.h:18
uint32 TType
class type indicator
Definition basedef.h:46
DVect3 DVect
Vector of doubles, either 2D or 3D.
Definition dim.h:154
Interface for LinkType<> objects, POD that contain both the pointer to the next object and an index f...
namespace Itasca
Definition basememory.cpp:14
Itasca Library standard namespace, specific to 2D or 3D.
Definition icontactmodule.h:4