Avara3D 0.2.0
C++ API reference
Line.h
1//
2// Line.h
3// avara3d
4//
5// Created by Morgan Davis on 5/20/18.
6// Copyright © 2026 Morgan K Davis. All rights reserved.
7//
8
9#ifndef AVARA3D_MESH_LINE_H
10#define AVARA3D_MESH_LINE_H
11
12#include <memory>
13
14#include "a3d/Color.h"
15#include "a3d/Math.h"
16
17namespace a3d {
18
19 class Line {
20
21// [Internal Lifecycle Functions]
22
23 public:
24 Line(const math::vec3& fromLocation, const math::vec3& toLocation);
25 Line(const math::vec3& fromLocation, const math::vec3& toLocation, const Color& color);
26 Line(const math::vec3& fromLocation,
27 const math::vec3& toLocation,
28 const math::vec3& fromColor,
29 const math::vec3& toColor);
30 Line(const math::vec3& fromLocation,
31 const math::vec3& toLocation,
32 const Color& fromColor,
33 const Color& toColor);
34
35 // [Internal Member Functions]
36
37 const math::vec3& fromLocation() const;
38 void fromLocation(const math::vec3& location);
39
40 const math::vec3& toLocation() const;
41 void toLocation(const math::vec3& location);
42
43 const Color& fromColor() const;
44 void fromColor(const Color& color);
45
46 const Color& toColor() const;
47 void toColor(const Color& color);
48
49 private:
50 // [Private Member Variables]
51
52 math::vec3 _fromLocation;
53 math::vec3 _toLocation;
54 Color _fromColor;
55 Color _toColor;
56 };
57
58}
59
60#endif // AVARA3D_MESH_LINE_H