CUGL 2.3
Cornell University Game Library
|
Enumerations | |
enum class | Joint : int { MITRE = 0 , SQUARE = 1 , ROUND = 2 } |
enum class | EndCap : int { BUTT = 0 , SQUARE = 1 , ROUND = 2 } |
enum class | Traversal : int { NONE = 0 , OPEN = 1 , CLOSED = 2 , INTERIOR = 3 } |
enum class | Capsule { DEGENERATE = 0 , FULL = 1 , HALF = 2 , HALF_REVERSE = 3 } |
Enumerations for the polygon factories.
This namespace is a collection of enumerations for the various polygon tools like EarclipTriangulator
. We gather them together in one place so that they may be used in multiple classes. For example, we have multiple triangulator and extruder classes. Therefore, the enumerations should not be tied to any one class.
|
strong |
This enum specifies a capsule shape
A capsule is a box with semicircular ends along the major axis. They are a popular physics object, particularly for character avatars. The rounded ends means they are less likely to snag, and they naturally fall off platforms when they go too far.
Sometimes we only want half a capsule (so a semicircle at one end, but not both). This enumeration allows us to specify the exact capsule we want. This enumeration is used by both PolyFactory
and the physics class physics2::CapsuleObstacle
.
|
strong |
The types of caps supported in an extrusion.
A cap is the rule for how to end an extruded line segment that has no neighbor on that end. If there is no cap, the path terminates at the end vertices.
This enumeration is used by SimpleExtruder
, ComplexExtruder
, and scene2::PathNode
.
|
strong |
The types of joints supported in an extrusion.
A joint is the rule for how to connect two extruded line segments. If there is not joint, the path will look like a sequence of overlapping rectangles.
This enumeration is used by SimpleExtruder
, ComplexExtruder
, and scene2::PathNode
.
Enumerator | |
---|---|
MITRE | Mitre joint; ideal for paths with sharp corners |
SQUARE | Bevel joint; ideal for smoother paths (DEFAULT) |
ROUND | Round joint; used to smooth out paths with sharp corners |
|
strong |
This enum lists the types of path traversal that are supported.
This enumeration is used by both PolyFactory
and scene2::WireNode
.