libtcod
Loading...
Searching...
No Matches
heightmap.h File Reference

Terrain heightmap module. More...

#include "mersenne_types.h"
#include "noise.h"
#include "portability.h"

Go to the source code of this file.

Classes

struct  TCOD_heightmap_t

Functions

TCOD_heightmap_tTCOD_heightmap_new (int w, int h)
void TCOD_heightmap_delete (TCOD_heightmap_t *hm)
float TCOD_heightmap_get_value (const TCOD_heightmap_t *hm, int x, int y)
float TCOD_heightmap_get_interpolated_value (const TCOD_heightmap_t *hm, float x, float y)
void TCOD_heightmap_set_value (TCOD_heightmap_t *hm, int x, int y, float value)
float TCOD_heightmap_get_slope (const TCOD_heightmap_t *hm, int x, int y)
void TCOD_heightmap_get_normal (const TCOD_heightmap_t *hm, float x, float y, float n[3], float waterLevel)
int TCOD_heightmap_count_cells (const TCOD_heightmap_t *hm, float min, float max)
bool TCOD_heightmap_has_land_on_border (const TCOD_heightmap_t *hm, float waterLevel)
void TCOD_heightmap_get_minmax (const TCOD_heightmap_t *hm, float *min, float *max)
void TCOD_heightmap_copy (const TCOD_heightmap_t *hm_source, TCOD_heightmap_t *hm_dest)
void TCOD_heightmap_add (TCOD_heightmap_t *hm, float value)
void TCOD_heightmap_scale (TCOD_heightmap_t *hm, float value)
void TCOD_heightmap_clamp (TCOD_heightmap_t *hm, float min, float max)
void TCOD_heightmap_normalize (TCOD_heightmap_t *hm, float min, float max)
void TCOD_heightmap_clear (TCOD_heightmap_t *hm)
void TCOD_heightmap_lerp_hm (const TCOD_heightmap_t *hm1, const TCOD_heightmap_t *hm2, TCOD_heightmap_t *out, float coef)
void TCOD_heightmap_add_hm (const TCOD_heightmap_t *hm1, const TCOD_heightmap_t *hm2, TCOD_heightmap_t *out)
void TCOD_heightmap_multiply_hm (const TCOD_heightmap_t *hm1, const TCOD_heightmap_t *hm2, TCOD_heightmap_t *out)
void TCOD_heightmap_add_hill (TCOD_heightmap_t *hm, float hx, float hy, float h_radius, float h_height)
void TCOD_heightmap_dig_hill (TCOD_heightmap_t *hm, float hx, float hy, float h_radius, float h_height)
void TCOD_heightmap_dig_bezier (TCOD_heightmap_t *hm, int px[4], int py[4], float startRadius, float startDepth, float endRadius, float endDepth)
void TCOD_heightmap_rain_erosion (TCOD_heightmap_t *hm, int nbDrops, float erosionCoef, float sedimentationCoef, TCOD_Random *rnd)
void TCOD_heightmap_kernel_transform (TCOD_heightmap_t *hm, int kernel_size, const int *dx, const int *dy, const float *weight, float minLevel, float maxLevel)
void TCOD_heightmap_add_voronoi (TCOD_heightmap_t *hm, int nbPoints, int nbCoef, const float *coef, TCOD_Random *rnd)
void TCOD_heightmap_mid_point_displacement (TCOD_heightmap_t *hm, TCOD_Random *rnd, float roughness)
void TCOD_heightmap_add_fbm (TCOD_heightmap_t *hm, TCOD_noise_t noise, float mul_x, float mul_y, float add_x, float add_y, float octaves, float delta, float scale)
void TCOD_heightmap_scale_fbm (TCOD_heightmap_t *hm, TCOD_noise_t noise, float mul_x, float mul_y, float add_x, float add_y, float octaves, float delta, float scale)
void TCOD_heightmap_islandify (TCOD_heightmap_t *hm, float seaLevel, TCOD_Random *rnd)

Detailed Description

Terrain heightmap module.