HighMap library (C++)
Loading...
Searching...
No Matches
shadows.hpp
Go to the documentation of this file.
1/* Copyright (c) 2023 Otto Link. Distributed under the terms of the GNU General
2 Public License. The full license is in the file LICENSE, distributed with
3 this software. */
4
19#pragma once
20
21#include "macrologger.h"
22
23#include "highmap/array.hpp"
24
25namespace hmap
26{
27
53Array hillshade(const Array &z,
54 float azimuth,
55 float zenith,
56 float talus_ref = 1.f);
57
69Array shadow_grid(const Array &z, float shadow_talus);
70
84Array shadow_heightmap(const Array &z,
85 float azimuth = 180.f,
86 float zenith = 45.f,
87 float distance = 0.2f);
88
113Array topographic_shading(const Array &z,
114 float azimuth,
115 float zenith,
116 float talus_ref = 1.f);
117
118} // namespace hmap
Declaration of the Array class for 2D floating-point arrays with various mathematical operations and ...
Definition algebra.hpp:23
Array topographic_shading(const Array &z, float azimuth, float zenith, float talus_ref=1.f)
Compute the topographic shadow intensity in the range [-1, 1].
Definition shadows.cpp:30
Array shadow_grid(const Array &z, float shadow_talus)
Compute the shadow intensity using a grid-based technique.
Definition shadows.cpp:47
float distance(const Point &p1, const Point &p2)
Calculates the distance between two points.
Definition points.cpp:127
Array shadow_heightmap(const Array &z, float azimuth=180.f, float zenith=45.f, float distance=0.2f)
Compute crude shadows from a heightmap.
Definition shadows.cpp:64
Array hillshade(const Array &z, float azimuth, float zenith, float talus_ref=1.f)
Compute the shaded relief map (hillshading) from a heightmap.
Definition shadows.cpp:15