Skip to content

Class Argos::PointsPerFaceSampler

ClassList > Argos > PointsPerFaceSampler

Surface sampler that generates a fixed number of random points on each face, regardless of face area. More...

  • #include <PointsPerFaceSampler.h>

Inherits the following classes: Argos::ISurfaceSampler

Public Functions

Type Name
PointsPerFaceSampler (std::size_t pointPerFace)
virtual std::string name () override const
Short identifier of the sampler including its parameter.
virtual PointCloud sample (const Mesh & mesh) override
Sample m_pointPerFace random points on each face.

Public Functions inherited from Argos::ISurfaceSampler

See Argos::ISurfaceSampler

Type Name
virtual std::string name () const = 0
Short identifier of the strategy.
virtual PointCloud sample (const Mesh & mesh) = 0
Sample a point cloud from a mesh.
virtual ~ISurfaceSampler () = default

Detailed Description

Points are distributed uniformly over each face using barycentric coordinates. Useful when every face should contribute equally.

Public Functions Documentation

function PointsPerFaceSampler

inline explicit Argos::PointsPerFaceSampler::PointsPerFaceSampler (
    std::size_t pointPerFace
) 

Parameters:

  • pointPerFace Fixed number of samples per face.

function name

Short identifier of the sampler including its parameter.

inline virtual std::string Argos::PointsPerFaceSampler::name () override const

Returns:

"(PointsPerFaceSampler-ppf<n>)".

Implements Argos::ISurfaceSampler::name


function sample

Sample m_pointPerFace random points on each face.

virtual PointCloud Argos::PointsPerFaceSampler::sample (
    const  Mesh & mesh
) override

Parameters:

  • mesh Input mesh.

Returns:

Point cloud with m_pointPerFace * faceCount points.

Implements Argos::ISurfaceSampler::sample



The documentation for this class was generated from the following file include/algos/mesh_to_pointcloud/PointsPerFaceSampler.h