Cogs.Core
MarkerPointSetComponent.h
1#pragma once
2
3#include "Foundation/ComponentModel/Component.h"
4
5#include <glm/vec4.hpp>
6
7namespace Cogs
8{
9 namespace Core
10 {
11 class Context;
12
13 enum struct MarkerPointSetShape : uint32_t
14 {
18 };
19
22 {
23 public:
24 std::vector<glm::vec3> positions;
25 glm::vec4 diffuseColor = glm::vec4(1, 1, 1, 1);
26 glm::vec4 outlineColor = glm::vec4(0, 0, 0, 1);
28 float pointSize = 5.f;
29 float outline = 1.f;
30 float nearDistance = 0.f;
31 float farDistance = std::numeric_limits<float>::max();
32 bool smooth = true;
33
34 static void registerType();
35 };
36 }
37}
38
39template<> inline Cogs::StringView getName<Cogs::Core::MarkerPointSetShape>() { return "MarkerPointSetShape"; }
40
41template<> inline Cogs::StringView getName<Cogs::Core::MarkerPointSetComponent>() { return "MarkerPointSetComponent"; }
Base class for Component instances.
Definition: Component.h:143
! Generate a set of points for the given position array.
float farDistance
Don't display points further than this distance from the camera.
MarkerPointSetShape shape
Specify the shape of the points.
glm::vec4 outlineColor
Points outline color.
bool smooth
Smooth out the point edges.
float nearDistance
Don't display points closer than this distance from the camera.
std::vector< glm::vec3 > positions
Marker points positions.
glm::vec4 diffuseColor
Points inner color.
Provides a weakly referenced view over the contents of a string.
Definition: StringView.h:24
@ ViewAlignedDisc
Point is a flat disc aligned with the main camera view.
@ ObjectSpaceFloorDisc
Point is a flat disc on the XY-plane, point size is object-space diameter of disc.
@ FixedScreenSizeDisc
Point is a screen-space disc, point size is screen-space diameter of disc, won't work with multiple c...
Contains all Cogs related functionality.
Definition: FieldSetter.h:23