Ogre Procedural  0.3.0 unstable
Procedural Geometry & Textures for Ogre3D
Public Member Functions | Public Attributes | List of all members
Procedural::Segment2D Struct Reference

Represents a 2D segment. More...

#include <ProceduralGeometryHelpers.h>

Public Member Functions

 Segment2D ()
 
 Segment2D (Ogre::Vector2 a, Ogre::Vector2 b)
 Contructor with arguments. More...
 
bool findIntersect (const Segment2D &other, Ogre::Vector2 &intersection) const
 Computes the interesction between current segment and another segment. More...
 
bool intersects (const Segment2D &other) const
 Tells whether this segments intersects the other segment. More...
 

Public Attributes

Ogre::Vector2 mA
 
Ogre::Vector2 mB
 

Detailed Description

Represents a 2D segment.

Constructor & Destructor Documentation

◆ Segment2D() [1/2]

Procedural::Segment2D::Segment2D ( )

◆ Segment2D() [2/2]

Procedural::Segment2D::Segment2D ( Ogre::Vector2  a,
Ogre::Vector2  b 
)

Contructor with arguments.

Member Function Documentation

◆ findIntersect()

bool Procedural::Segment2D::findIntersect ( const Segment2D other,
Ogre::Vector2 intersection 
) const

Computes the interesction between current segment and another segment.

Parameters
otherthe other segment
intersectionthe point of intersection if outputed there if it exists
Returns
true if segments intersect, false otherwise

◆ intersects()

bool Procedural::Segment2D::intersects ( const Segment2D other) const

Tells whether this segments intersects the other segment.

Member Data Documentation

◆ mA

Ogre::Vector2 Procedural::Segment2D::mA

◆ mB

Ogre::Vector2 Procedural::Segment2D::mB

The documentation for this struct was generated from the following file: