KiCad PCB EDA Suite
SHAPE_RECT Class Reference

#include <shape_rect.h>

Inheritance diagram for SHAPE_RECT:
SHAPE

Public Member Functions

 SHAPE_RECT ()
 Constructor Creates an empty (0-sized) rectangle. More...
 
 SHAPE_RECT (int aX0, int aY0, int aW, int aH)
 Constructor Creates a rectangle defined by top-left corner (aX0, aY0), width aW and height aH. More...
 
 SHAPE_RECT (const VECTOR2I &aP0, int aW, int aH)
 Constructor Creates a rectangle defined by top-left corner aP0, width aW and height aH. More...
 
 SHAPE_RECT (const SHAPE_RECT &aOther)
 
SHAPEClone () const override
 Function Clone() More...
 
const BOX2I BBox (int aClearance=0) const override
 Function BBox() More...
 
int Diagonal () const
 Function Diagonal() More...
 
bool Collide (const SEG &aSeg, int aClearance=0) const override
 Function Collide() More...
 
const VECTOR2IGetPosition () const
 Function GetPosition() More...
 
const VECTOR2I GetSize () const
 Function GetSize() More...
 
const int GetWidth () const
 Function GetWidth() More...
 
const int GetHeight () const
 Function GetHeight() More...
 
void Move (const VECTOR2I &aVector) override
 
bool IsSolid () const override
 
const SHAPE_LINE_CHAIN Outline () const
 
SHAPE_TYPE Type () const
 Function Type() More...
 
virtual bool Collide (const VECTOR2I &aP, int aClearance=0) const
 Function Collide() More...
 
virtual bool Collide (const SHAPE *aShape, int aClearance, VECTOR2I &aMTV) const
 Function Collide() More...
 
virtual bool Collide (const SHAPE *aShape, int aClearance=0) const
 
virtual VECTOR2I Centre () const
 Function Centre() More...
 
virtual bool Parse (std::stringstream &aStream)
 
virtual const std::string Format () const
 
FACETNewFacet ()
 
SGNODECalcShape (SGNODE *aParent, SGNODE *aColor, WRL1_ORDER aVertexOrder, float aCreaseLimit=0.74317, bool isVRML2=false)
 

Protected Types

typedef VECTOR2I::extended_type ecoord
 

Protected Attributes

SHAPE_TYPE m_type
 

type of our shape

More...
 

Private Attributes

VECTOR2I m_p0
 

Top-left corner

More...
 
int m_w
 

Width

More...
 
int m_h
 

Height

More...
 

Detailed Description

Definition at line 34 of file shape_rect.h.

Member Typedef Documentation

◆ ecoord

typedef VECTOR2I::extended_type SHAPE::ecoord
protectedinherited

Definition at line 63 of file shape.h.

Constructor & Destructor Documentation

◆ SHAPE_RECT() [1/4]

SHAPE_RECT::SHAPE_RECT ( )
inline

Constructor Creates an empty (0-sized) rectangle.

Definition at line 41 of file shape_rect.h.

41  :
42  SHAPE( SH_RECT ), m_w( 0 ), m_h( 0 )
43  {}
SHAPE(SHAPE_TYPE aType)
Constructor.
Definition: shape.h:72
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
Definition: shape.h:45

Referenced by Clone().

◆ SHAPE_RECT() [2/4]

SHAPE_RECT::SHAPE_RECT ( int  aX0,
int  aY0,
int  aW,
int  aH 
)
inline

Constructor Creates a rectangle defined by top-left corner (aX0, aY0), width aW and height aH.

Definition at line 49 of file shape_rect.h.

49  :
50  SHAPE( SH_RECT ), m_p0( aX0, aY0 ), m_w( aW ), m_h( aH )
51  {}
SHAPE(SHAPE_TYPE aType)
Constructor.
Definition: shape.h:72
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
Definition: shape.h:45

◆ SHAPE_RECT() [3/4]

SHAPE_RECT::SHAPE_RECT ( const VECTOR2I aP0,
int  aW,
int  aH 
)
inline

Constructor Creates a rectangle defined by top-left corner aP0, width aW and height aH.

Definition at line 57 of file shape_rect.h.

57  :
58  SHAPE( SH_RECT ), m_p0( aP0 ), m_w( aW ), m_h( aH )
59  {}
SHAPE(SHAPE_TYPE aType)
Constructor.
Definition: shape.h:72
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
Definition: shape.h:45

◆ SHAPE_RECT() [4/4]

SHAPE_RECT::SHAPE_RECT ( const SHAPE_RECT aOther)
inline

Definition at line 61 of file shape_rect.h.

61  :
62  SHAPE( SH_RECT ),
63  m_p0( aOther.m_p0 ),
64  m_w( aOther.m_w ),
65  m_h( aOther.m_h )
66  {};
SHAPE(SHAPE_TYPE aType)
Constructor.
Definition: shape.h:72
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
Definition: shape.h:45

Member Function Documentation

◆ BBox()

const BOX2I SHAPE_RECT::BBox ( int  aClearance = 0) const
inlineoverridevirtual

Function BBox()

Computes a bounding box of the shape, with a margin of aClearance a collision.

Parameters
aClearancehow much the bounding box is expanded wrs to the minimum enclosing rectangle for the shape.
Returns
the bounding box.

Implements SHAPE.

Definition at line 74 of file shape_rect.h.

75  {
76  BOX2I bbox( VECTOR2I( m_p0.x - aClearance, m_p0.y - aClearance ),
77  VECTOR2I( m_w + 2 * aClearance, m_h + 2 * aClearance ) );
78  //printf("bb : %s\n",bbox.Format().c_str());
79  return bbox;
80  }
VECTOR2 defines a general 2D-vector/point.
Definition: vector2d.h:61
VECTOR2< int > VECTOR2I
Definition: vector2d.h:594
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163

References m_h, m_p0, m_w, VECTOR2< T >::x, and VECTOR2< T >::y.

Referenced by Collide().

◆ CalcShape()

SGNODE * SHAPE::CalcShape ( SGNODE aParent,
SGNODE aColor,
WRL1_ORDER  aVertexOrder,
float  aCreaseLimit = 0.74317,
bool  isVRML2 = false 
)
inherited

Definition at line 713 of file wrlfacet.cpp.

715 {
716  if( facets.empty() || !facets.front()->HasMinPoints() )
717  return NULL;
718 
719  std::vector< std::list< FACET* > > flist;
720 
721  // determine the max. index and size flist as appropriate
722  std::list< FACET* >::iterator sF = facets.begin();
723  std::list< FACET* >::iterator eF = facets.end();
724 
725  int maxIdx = 0;
726  int tmi;
727  float maxV = 0.0;
728  float tV = 0.0;
729 
730  while( sF != eF )
731  {
732  tV = (*sF)->CalcFaceNormal();
733  tmi = (*sF)->GetMaxIndex();
734 
735  if( tmi > maxIdx )
736  maxIdx = tmi;
737 
738  if( tV > maxV )
739  maxV = tV;
740 
741  ++sF;
742  }
743 
744  ++maxIdx;
745 
746  if( maxIdx < 3 )
747  return NULL;
748 
749  flist.resize( maxIdx );
750 
751  // create the lists of facets common to indices
752  sF = facets.begin();
753 
754  while( sF != eF )
755  {
756  (*sF)->Renormalize( tV );
757  (*sF)->CollectVertices( flist );
758  ++sF;
759  }
760 
761  // calculate the normals
762  size_t vs = flist.size();
763 
764  for( size_t i = 0; i < vs; ++i )
765  {
766  sF = flist[i].begin();
767  eF = flist[i].end();
768 
769  while( sF != eF )
770  {
771  (*sF)->CalcVertexNormal( i, flist[i], aCreaseLimit );
772  ++sF;
773  }
774  }
775 
776  std::vector< WRLVEC3F > vertices;
777  std::vector< WRLVEC3F > normals;
778  std::vector< SGCOLOR > colors;
779 
780  // push the facet data to the final output list
781  sF = facets.begin();
782  eF = facets.end();
783 
784  while( sF != eF )
785  {
786  (*sF)->GetData( vertices, normals, colors, aVertexOrder );
787  ++sF;
788  }
789 
790  flist.clear();
791 
792  if( vertices.size() < 3 )
793  return NULL;
794 
795  IFSG_SHAPE shapeNode( false );
796 
797  if( !isVRML2 )
798  {
799  shapeNode.NewNode( aParent );
800 
801  if( aColor )
802  {
803  if( NULL == S3D::GetSGNodeParent( aColor ) )
804  shapeNode.AddChildNode( aColor );
805  else
806  shapeNode.AddRefNode( aColor );
807  }
808  }
809 
810  std::vector< SGPOINT > lCPts; // vertex points in SGPOINT (double) format
811  std::vector< SGVECTOR > lCNorm; // per-vertex normals
812  vs = vertices.size();
813 
814  for( size_t i = 0; i < vs; ++i )
815  {
816  SGPOINT pt;
817  pt.x = vertices[i].x;
818  pt.y = vertices[i].y;
819  pt.z = vertices[i].z;
820  lCPts.push_back( pt );
821  lCNorm.emplace_back( normals[i].x, normals[i].y, normals[i].z );
822  }
823 
824  vertices.clear();
825  normals.clear();
826 
827  IFSG_FACESET fsNode( false );
828 
829  if( !isVRML2 )
830  fsNode.NewNode( shapeNode );
831  else
832  fsNode.NewNode( aParent );
833 
834  IFSG_COORDS cpNode( fsNode );
835  cpNode.SetCoordsList( lCPts.size(), &lCPts[0] );
836  IFSG_COORDINDEX ciNode( fsNode );
837 
838  for( int i = 0; i < (int)lCPts.size(); ++i )
839  ciNode.AddIndex( i );
840 
841  IFSG_NORMALS nmNode( fsNode );
842  nmNode.SetNormalList( lCNorm.size(), &lCNorm[0] );
843 
844  if( !colors.empty() )
845  {
846  IFSG_COLORS nmColor( fsNode );
847  nmColor.SetColorList( colors.size(), &colors[0] );
848  colors.clear();
849  }
850 
851  if( !isVRML2 )
852  return shapeNode.GetRawPtr();
853 
854  return fsNode.GetRawPtr();
855 }
double x
Definition: sg_base.h:70
IFSG_COORDS is the wrapper for SGCOORDS.
Definition: ifsg_coords.h:40
IFSG_COORDINDEX is the wrapper for SGCOORDINDEX.
IFSG_COLORS is the wrapper for SGCOLORS.
Definition: ifsg_colors.h:41
SGLIB_API SGNODE * GetSGNodeParent(SGNODE *aNode)
Definition: ifsg_api.cpp:636
double y
Definition: sg_base.h:71
IFSG_NORMALS is the wrapper for the SGNORMALS class.
Definition: ifsg_normals.h:40
#define NULL
std::list< FACET * > facets
Definition: wrlfacet.h:143
IFSG_FACESET is the wrapper for the SGFACESET class.
Definition: ifsg_faceset.h:40
double z
Definition: sg_base.h:72
static VRML_COLOR colors[VRML_COLOR_LAST]
IFSG_SHAPE is the wrapper for the SGSHAPE class.
Definition: ifsg_shape.h:40

References IFSG_NODE::AddChildNode(), IFSG_INDEX::AddIndex(), IFSG_NODE::AddRefNode(), colors, SHAPE::facets, IFSG_NODE::GetRawPtr(), S3D::GetSGNodeParent(), IFSG_FACESET::NewNode(), IFSG_SHAPE::NewNode(), NULL, IFSG_COLORS::SetColorList(), IFSG_COORDS::SetCoordsList(), IFSG_NORMALS::SetNormalList(), SGPOINT::x, SGPOINT::y, and SGPOINT::z.

Referenced by WRL1FACESET::TranslateToSG(), X3DIFACESET::TranslateToSG(), and WRL2FACESET::TranslateToSG().

◆ Centre()

virtual VECTOR2I SHAPE::Centre ( ) const
inlinevirtualinherited

Function Centre()

Computes a center-of-mass of the shape

Returns
the center-of-mass point

Definition at line 153 of file shape.h.

154  {
155  return BBox( 0 ).Centre(); // if nothing better is available....
156  }
virtual const BOX2I BBox(int aClearance=0) const =0
Function BBox()
Vec Centre() const
Definition: box2.h:78

References SHAPE::BBox(), and BOX2< Vec >::Centre().

Referenced by PNS_PCBNEW_RULE_RESOLVER::CollideHoles().

◆ Clone()

SHAPE* SHAPE_RECT::Clone ( ) const
inlineoverridevirtual

Function Clone()

Returns a dynamically allocated copy of the shape

Return values
copyof the shape

Reimplemented from SHAPE.

Definition at line 68 of file shape_rect.h.

69  {
70  return new SHAPE_RECT( *this );
71  }
SHAPE_RECT()
Constructor Creates an empty (0-sized) rectangle.
Definition: shape_rect.h:41

References SHAPE_RECT().

◆ Collide() [1/4]

bool SHAPE_RECT::Collide ( const SEG aSeg,
int  aClearance = 0 
) const
overridevirtual

Function Collide()

Checks if the boundary of shape (this) lies closer to the point aP than aClearance, indicating a collision.

Returns
true, if there is a collision.

Implements SHAPE.

Definition at line 563 of file shape_collisions.cpp.

564 {
565  //VECTOR2I pmin = VECTOR2I( std::min( aSeg.a.x, aSeg.b.x ), std::min( aSeg.a.y, aSeg.b.y ) );
566  //VECTOR2I pmax = VECTOR2I( std::max( aSeg.a.x, aSeg.b.x ), std::max( aSeg.a.y, aSeg.b.y ));
567  //BOX2I r( pmin, VECTOR2I( pmax.x - pmin.x, pmax.y - pmin.y ) );
568 
569  //if( BBox( 0 ).SquaredDistance( r ) > aClearance * aClearance )
570  // return false;
571 
572  if( BBox( 0 ).Contains( aSeg.A ) || BBox( 0 ).Contains( aSeg.B ) )
573  return true;
574 
575  VECTOR2I vts[] = { VECTOR2I( m_p0.x, m_p0.y ),
576  VECTOR2I( m_p0.x, m_p0.y + m_h ),
577  VECTOR2I( m_p0.x + m_w, m_p0.y + m_h ),
578  VECTOR2I( m_p0.x + m_w, m_p0.y ),
579  VECTOR2I( m_p0.x, m_p0.y ) };
580 
581  for( int i = 0; i < 4; i++ )
582  {
583  SEG s( vts[i], vts[i + 1], i );
584 
585  if( s.Distance( aSeg ) < aClearance )
586  return true;
587  }
588 
589  return false;
590 }
VECTOR2 defines a general 2D-vector/point.
Definition: vector2d.h:61
VECTOR2< int > VECTOR2I
Definition: vector2d.h:594
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
Definition: seg.h:39
const BOX2I BBox(int aClearance=0) const override
Function BBox()
Definition: shape_rect.h:74
VECTOR2I A
Definition: seg.h:47
VECTOR2I B
Definition: seg.h:48

References SEG::A, SEG::B, BBox(), SEG::Distance(), m_h, m_p0, m_w, VECTOR2< T >::x, and VECTOR2< T >::y.

Referenced by Collide().

◆ Collide() [2/4]

virtual bool SHAPE::Collide ( const VECTOR2I aP,
int  aClearance = 0 
) const
inlinevirtualinherited

Function Collide()

Checks if the boundary of shape (this) lies closer to the point aP than aClearance, indicating a collision.

Returns
true, if there is a collision.

Reimplemented in SHAPE_POLY_SET, SHAPE_LINE_CHAIN, SHAPE_ARC, and SHAPE_SEGMENT.

Definition at line 109 of file shape.h.

110  {
111  return Collide( SEG( aP, aP ), aClearance );
112  }
virtual bool Collide(const VECTOR2I &aP, int aClearance=0) const
Function Collide()
Definition: shape.h:109
Definition: seg.h:39

Referenced by collide(), PNS::ITEM::collideSimple(), PNS::HIT_VISITOR::operator()(), and PNS::OPTIMIZER::smartPadsSingle().

◆ Collide() [3/4]

bool SHAPE::Collide ( const SHAPE aShape,
int  aClearance,
VECTOR2I aMTV 
) const
virtualinherited

Function Collide()

Checks if the boundary of shape (this) lies closer to the shape aShape than aClearance, indicating a collision.

Parameters
aShapeshape to check collision against
aClearanceminimum clearance
aMTVminimum translation vector
Returns
true, if there is a collision.

Definition at line 549 of file shape_collisions.cpp.

550 {
551  return CollideShapes( this, aShape, aClearance, true, aMTV );
552 }
bool CollideShapes(const SHAPE *aA, const SHAPE *aB, int aClearance, bool aNeedMTV, VECTOR2I &aMTV)

References CollideShapes().

◆ Collide() [4/4]

bool SHAPE::Collide ( const SHAPE aShape,
int  aClearance = 0 
) const
virtualinherited

Definition at line 555 of file shape_collisions.cpp.

556 {
557  VECTOR2I dummy;
558 
559  return CollideShapes( this, aShape, aClearance, false, dummy );
560 }
VECTOR2 defines a general 2D-vector/point.
Definition: vector2d.h:61
static LIB_PART * dummy()
Used to draw a dummy shape when a LIB_PART is not found in library.
bool CollideShapes(const SHAPE *aA, const SHAPE *aB, int aClearance, bool aNeedMTV, VECTOR2I &aMTV)

References CollideShapes(), and dummy().

◆ Diagonal()

int SHAPE_RECT::Diagonal ( ) const
inline

Function Diagonal()

Returns length of the diagonal of the rectangle

Returns
diagonal length

Definition at line 88 of file shape_rect.h.

89  {
90  return VECTOR2I( m_w, m_h ).EuclideanNorm();
91  }
VECTOR2< int > VECTOR2I
Definition: vector2d.h:594
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
T EuclideanNorm() const
Destructor.
Definition: vector2d.h:299

References VECTOR2< T >::EuclideanNorm(), m_h, and m_w.

◆ Format()

const std::string SHAPE::Format ( ) const
virtualinherited

Reimplemented in SHAPE_POLY_SET, and SHAPE_LINE_CHAIN.

Definition at line 35 of file shape.cpp.

36 {
37  assert( false );
38  return std::string( "" );
39 }

Referenced by SHAPE_FILE_IO::Write().

◆ GetHeight()

const int SHAPE_RECT::GetHeight ( ) const
inline

Function GetHeight()

Returns
height of the rectangle

Definition at line 131 of file shape_rect.h.

132  {
133  return m_h;
134  }
int m_h
Height
Definition: shape_rect.h:166

References m_h.

◆ GetPosition()

const VECTOR2I& SHAPE_RECT::GetPosition ( ) const
inline

Function GetPosition()

Returns
top-left corner of the rectangle

Definition at line 101 of file shape_rect.h.

102  {
103  return m_p0;
104  }
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160

References m_p0.

Referenced by Collide(), PNS::LOGGER::dumpShape(), PNS::SOLID::Hull(), PNS::OPTIMIZER::rectBreakouts(), and ROUTER_PREVIEW_ITEM::ViewDraw().

◆ GetSize()

const VECTOR2I SHAPE_RECT::GetSize ( ) const
inline

Function GetSize()

Returns
size of the rectangle

Definition at line 111 of file shape_rect.h.

112  {
113  return VECTOR2I( m_w, m_h );
114  }
VECTOR2< int > VECTOR2I
Definition: vector2d.h:594
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163

References m_h, and m_w.

Referenced by Collide(), PNS::LOGGER::dumpShape(), PNS::SOLID::Hull(), PNS::OPTIMIZER::rectBreakouts(), and ROUTER_PREVIEW_ITEM::ViewDraw().

◆ GetWidth()

const int SHAPE_RECT::GetWidth ( ) const
inline

Function GetWidth()

Returns
width of the rectangle

Definition at line 121 of file shape_rect.h.

122  {
123  return m_w;
124  }
int m_w
Width
Definition: shape_rect.h:163

References m_w.

◆ IsSolid()

bool SHAPE_RECT::IsSolid ( ) const
inlineoverridevirtual

Implements SHAPE.

Definition at line 141 of file shape_rect.h.

142  {
143  return true;
144  }

◆ Move()

void SHAPE_RECT::Move ( const VECTOR2I aVector)
inlineoverridevirtual

Implements SHAPE.

Definition at line 136 of file shape_rect.h.

137  {
138  m_p0 += aVector;
139  }
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160

References m_p0.

◆ NewFacet()

FACET * SHAPE::NewFacet ( )
inherited

Definition at line 705 of file wrlfacet.cpp.

706 {
707  FACET* fp = new FACET;
708  facets.push_back( fp );
709  return fp;
710 }
Definition: wrlfacet.h:41
std::list< FACET * > facets
Definition: wrlfacet.h:143

References SHAPE::facets.

Referenced by WRL1FACESET::TranslateToSG(), X3DIFACESET::TranslateToSG(), and WRL2FACESET::TranslateToSG().

◆ Outline()

const SHAPE_LINE_CHAIN SHAPE_RECT::Outline ( ) const
inline

Definition at line 146 of file shape_rect.h.

147  {
148  SHAPE_LINE_CHAIN rv;
149  rv.Append( m_p0 );
150  rv.Append( m_p0.x, m_p0.y + m_h );
151  rv.Append( m_p0.x + m_w, m_p0.y + m_h );
152  rv.Append( m_p0.x + m_w, m_p0.y );
153  rv.Append( m_p0 );
154  rv.SetClosed( true );
155  return rv;
156  }
void Append(int aX, int aY, bool aAllowDuplication=false)
Function Append()
void SetClosed(bool aClosed)
Function SetClosed()
VECTOR2I m_p0
Top-left corner
Definition: shape_rect.h:160
int m_h
Height
Definition: shape_rect.h:166
int m_w
Width
Definition: shape_rect.h:163
SHAPE_LINE_CHAIN.

References SHAPE_LINE_CHAIN::Append(), m_h, m_p0, m_w, SHAPE_LINE_CHAIN::SetClosed(), VECTOR2< T >::x, and VECTOR2< T >::y.

Referenced by Collide(), and D_PAD::MergePrimitivesAsPolygon().

◆ Parse()

bool SHAPE::Parse ( std::stringstream &  aStream)
virtualinherited

Reimplemented in SHAPE_POLY_SET, and SHAPE_LINE_CHAIN.

Definition at line 28 of file shape.cpp.

29 {
30  assert( false );
31  return false;
32 }

◆ Type()

SHAPE_TYPE SHAPE::Type ( ) const
inlineinherited

Function Type()

Returns the type of the shape.

Return values
thetype

Definition at line 85 of file shape.h.

86  {
87  return m_type;
88  }
SHAPE_TYPE m_type
type of our shape
Definition: shape.h:168

References SHAPE::m_type.

Referenced by PNS::DP_GATEWAYS::BuildFromPrimitivePair(), CollideShapes(), PNS::OPTIMIZER::computeBreakouts(), PNS::LOGGER::dumpShape(), PNS::SOLID::Hull(), ROUTER_PREVIEW_ITEM::ViewDraw(), and SHAPE_FILE_IO::Write().

Member Data Documentation

◆ m_h

int SHAPE_RECT::m_h
private

Height

Definition at line 166 of file shape_rect.h.

Referenced by BBox(), Collide(), Diagonal(), GetHeight(), GetSize(), and Outline().

◆ m_p0

VECTOR2I SHAPE_RECT::m_p0
private

Top-left corner

Definition at line 160 of file shape_rect.h.

Referenced by BBox(), Collide(), GetPosition(), Move(), and Outline().

◆ m_type

SHAPE_TYPE SHAPE::m_type
protectedinherited

type of our shape

Definition at line 168 of file shape.h.

Referenced by SHAPE::Type().

◆ m_w

int SHAPE_RECT::m_w
private

Width

Definition at line 163 of file shape_rect.h.

Referenced by BBox(), Collide(), Diagonal(), GetSize(), GetWidth(), and Outline().


The documentation for this class was generated from the following files: