Bomberman
Public Member Functions | Private Attributes | List of all members
RAY::Drawables::Drawables3D::Ray Class Reference

Ray in a three-dimensionnal space. More...

#include <Ray.hpp>

Inheritance diagram for RAY::Drawables::Drawables3D::Ray:
Collaboration diagram for RAY::Drawables::Drawables3D::Ray:

Public Member Functions

 Ray (const Vector3 &startPosition, const Vector3 &direction, const Color &color)
 Ray constructor. More...
 
 Ray (const Ray &)=default
 A default copy constructor. More...
 
Rayoperator= (const Ray &)=default
 A line is assignable. More...
 
 ~Ray () override=default
 A default destructor. More...
 
const Vector3getDirection (void) const
 
RaysetDirection (const Vector3 &direction)
 Set end position. More...
 
void drawOn (RAY::Window &) override
 Draw point on window. More...
 
- Public Member Functions inherited from RAY::Drawables::ADrawable3D
 ADrawable3D (const RAY::Vector3 &position, const RAY::Color &color)
 
 ADrawable3D (const ADrawable3D &)=default
 A default copy constructor. More...
 
 ~ADrawable3D () override=default
 A default destructor. More...
 
virtual void drawWiresOn (RAY::Window &)
 Draw drawble's wires on window. More...
 
const RAY::ColorgetColor (void) const
 
ADrawable3DsetColor (const RAY::Color &color)
 set color More...
 
const RAY::ColorgetDebugColor (void) const
 
ADrawable3DsetDebugColor (const RAY::Color &debugColor)
 set the debug color More...
 
virtual const RAY::Vector3getPosition (void) const
 
virtual ADrawable3DsetPosition (const Vector3 &position)
 set position More...
 
- Public Member Functions inherited from RAY::Drawables::IDrawable
virtual ~IDrawable ()=default
 

Private Attributes

Vector3 _direction
 

Additional Inherited Members

- Protected Attributes inherited from RAY::Drawables::ADrawable3D
Vector3 _position
 Position of the ADrawable. More...
 
Color _color
 Color of the ADrawable. More...
 
Color _debugColor = GREEN
 Color of the ADrawable's Debug. More...
 

Detailed Description

Ray in a three-dimensionnal space.

Constructor & Destructor Documentation

◆ Ray() [1/2]

RAY::Drawables::Drawables3D::Ray::Ray ( const Vector3 startPosition,
const Vector3 direction,
const Color color 
)

Ray constructor.

Parameters
startPositionposition of top-left point
directiondirection of the ray
ColorColor of the line

◆ Ray() [2/2]

RAY::Drawables::Drawables3D::Ray::Ray ( const Ray )
default

A default copy constructor.

◆ ~Ray()

RAY::Drawables::Drawables3D::Ray::~Ray ( )
overridedefault

A default destructor.

Member Function Documentation

◆ drawOn()

void RAY::Drawables::Drawables3D::Ray::drawOn ( RAY::Window )
overridevirtual

Draw point on window.

Implements RAY::Drawables::ADrawable3D.

◆ getDirection()

const RAY::Vector3 & RAY::Drawables::Drawables3D::Ray::getDirection ( void  ) const
Returns
the end position of the line

◆ operator=()

Ray& RAY::Drawables::Drawables3D::Ray::operator= ( const Ray )
default

A line is assignable.

◆ setDirection()

Ray & RAY::Drawables::Drawables3D::Ray::setDirection ( const Vector3 direction)

Set end position.

Member Data Documentation

◆ _direction

Vector3 RAY::Drawables::Drawables3D::Ray::_direction
private

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