Back to class index
Capsule[Class Summary]
l
r
ctor (+2 overloads)
SetFrom(s)
SetDegenerate()
IsDegenerate()[const]
LineLength()[const]
Height()[const]
Diameter()[const]
Bottom()[const]
Center()[const]
Centroid()[const]
AnyPointFast()[const]
ExtremePoint(direction)[const] (+1 overload)
ProjectToAxis(...)[const]
Top()[const]
UpDirection()[const]
Volume()[const]
SurfaceArea()[const]
CrossSection(l)[const]
HeightLineSegment()[const]
IsFinite()[const]
PointInside(l,a,d)[const]
UniformPointPerhapsInside(l,x,y)[const]
SphereA()[const]
SphereB()[const]
MinimalEnclosingAABB()[const]
MinimalEnclosingOBB()[const]
RandomPointInside(rng)[const]
RandomPointOnSurface(rng)[const]
Translate(offset)
Scale(...)
Transform(transform) (+3 overloads)
ClosestPoint(targetPoint)[const]
Distance(point)[const] (+6 overloads)
Contains(point)[const] (+7 overloads)
Intersects(ray)[const] (+11 overloads)
ToString()[const]
SerializeToString()[const]
SerializeToCodeString()[const]
Equals(rhs,epsilon)[const]
BitEquals(other)[const]
FromString(str,outEndStr)[static] (+1 overload)

Capsule::UniformPointPerhapsInside

Syntax

float4 Capsule::UniformPointPerhapsInside(float l, float x, float y) const; [4 lines of code]

Generates a point that perhaps lies inside this capsule.

Note
This function will generate points uniformly, but they do not necessarily lie inside the capsule.

Parameters

floatlA normalized value between [0,1]. This specifies the point position along the height line of this capsule. floatxA normalized value between [0,1]. This specifies the x coordinate on the plane of the circle cross-section specified by l. floatyA normalized value between [0,1]. This specifies the y coordinate on the plane of the circle cross-section specified by l.

See Also

PointInside().