Nebula
Toggle main menu visibility
Loading...
Searching...
No Matches
primitivetopology.h
Go to the documentation of this file.
1
#pragma once
2
//------------------------------------------------------------------------------
12
#include "
core/types.h
"
13
#include "
util/string.h
"
14
15
//------------------------------------------------------------------------------
16
namespace
CoreGraphics
17
{
18
class
PrimitiveTopology
19
{
20
public
:
22
enum
Code
23
{
24
InvalidPrimitiveTopology
,
25
26
PointList
,
27
LineList
,
28
LineStrip
,
29
LineListAdjacency
,
30
LineStripAdjacency
,
31
TriangleList
,
32
TriangleStrip
,
33
TriangleFan
,
34
TriangleListAdjacency
,
35
TriangleStripAdjacency
,
36
PatchList
,
37
38
NumTopologies
=
PatchList
39
};
40
42
static
Code
FromString
(
const
Util::String
& str);
44
static
Util::String
ToString
(
Code
code);
46
static
SizeT
NumberOfVertices
(
Code
topology,
SizeT
numPrimitives);
48
static
SizeT
NumberOfPrimitives
(
Code
topology,
SizeT
numVertices);
49
50
};
51
52
};
// namespace CoreGraphics
53
//------------------------------------------------------------------------------
54
CoreGraphics::PrimitiveTopology
The primitive topology for a draw call.
Definition
primitivetopology.h:19
CoreGraphics::PrimitiveTopology::Code
Code
enumeration
Definition
primitivetopology.h:23
CoreGraphics::PrimitiveTopology::TriangleListAdjacency
@ TriangleListAdjacency
Definition
primitivetopology.h:34
CoreGraphics::PrimitiveTopology::PointList
@ PointList
Definition
primitivetopology.h:26
CoreGraphics::PrimitiveTopology::LineStrip
@ LineStrip
Definition
primitivetopology.h:28
CoreGraphics::PrimitiveTopology::InvalidPrimitiveTopology
@ InvalidPrimitiveTopology
Definition
primitivetopology.h:24
CoreGraphics::PrimitiveTopology::TriangleList
@ TriangleList
Definition
primitivetopology.h:31
CoreGraphics::PrimitiveTopology::LineList
@ LineList
Definition
primitivetopology.h:27
CoreGraphics::PrimitiveTopology::TriangleStrip
@ TriangleStrip
Definition
primitivetopology.h:32
CoreGraphics::PrimitiveTopology::LineListAdjacency
@ LineListAdjacency
Definition
primitivetopology.h:29
CoreGraphics::PrimitiveTopology::PatchList
@ PatchList
Definition
primitivetopology.h:36
CoreGraphics::PrimitiveTopology::LineStripAdjacency
@ LineStripAdjacency
Definition
primitivetopology.h:30
CoreGraphics::PrimitiveTopology::TriangleStripAdjacency
@ TriangleStripAdjacency
Definition
primitivetopology.h:35
CoreGraphics::PrimitiveTopology::TriangleFan
@ TriangleFan
Definition
primitivetopology.h:33
CoreGraphics::PrimitiveTopology::NumTopologies
@ NumTopologies
Definition
primitivetopology.h:38
CoreGraphics::PrimitiveTopology::ToString
static Util::String ToString(Code code)
convert to string
Definition
primitivetopology.cc:38
CoreGraphics::PrimitiveTopology::NumberOfVertices
static SizeT NumberOfVertices(Code topology, SizeT numPrimitives)
compute number of vertices/indices given a primitive topology and number of primitives
Definition
primitivetopology.cc:62
CoreGraphics::PrimitiveTopology::FromString
static Code FromString(const Util::String &str)
convert from string
Definition
primitivetopology.cc:17
CoreGraphics::PrimitiveTopology::NumberOfPrimitives
static SizeT NumberOfPrimitives(Code topology, SizeT numVertices)
compute number of primitives given a primitive type and number of vertices/indices
Definition
primitivetopology.cc:86
CoreGraphics
Acceleration structures are used to enable ray tracing on the GPU by dividing the scene into a BVH.
Definition
accelerationstructure.h:24
string.h
Util.String
Nebula's universal string class.
Definition
String.cs:8
types.h
SizeT
int SizeT
Definition
types.h:42
code
render
coregraphics
primitivetopology.h
Generated on
for Nebula. Dark theme by
Tilen Majerle
. All rights reserved.