HighMap library (C++)
Loading...
Searching...
No Matches
hmap::BumpFunction Class Reference

Bump (x, y) function class. More...

#include <functions.hpp>

Inheritance diagram for hmap::BumpFunction:
Collaboration diagram for hmap::BumpFunction:

Public Member Functions

 BumpFunction (float gain, Vec2< float > center)
 Construct a new Bump Function object.
 
- Public Member Functions inherited from hmap::Function
 Function ()
 Default constructor. Initializes the delegate function to a default that returns 0.
 
virtual ~Function ()=default
 Virtual destructor to ensure proper cleanup in derived classes.
 
 Function (HMAP_FCT_XY_TYPE delegate)
 Constructor to initialize with a specific delegate function.
 
HMAP_FCT_XY_TYPE get_delegate () const
 Get the current delegate function.
 
float get_value (float x, float y, float ctrl_param) const
 Call the delegate function with given arguments.
 
void set_delegate (HMAP_FCT_XY_TYPE new_delegate)
 Set a new delegate function.
 

Protected Attributes

float gain
 Gain value that controls the steepness of the bump.
 
Vec2< float > center
 Primitive reference center.
 

Detailed Description

Bump (x, y) function class.

This class models a bump function with a specified gain and reference center. It extends the base Function class.

Constructor & Destructor Documentation

◆ BumpFunction()

hmap::BumpFunction::BumpFunction ( float  gain,
Vec2< float >  center 
)

Construct a new Bump Function object.

Parameters
gainGain that controls the steepness of the bump.
centerPrimitive reference center.

Member Data Documentation

◆ gain

float hmap::BumpFunction::gain
protected

Gain value that controls the steepness of the bump.

◆ center

Vec2<float> hmap::BumpFunction::center
protected

Primitive reference center.


The documentation for this class was generated from the following files: