Wayverb
Main Page
Related Pages
Classes
Files
File List
waveguide_base.h
1
#pragma once
2
3
#include "waveguide/bandpass_band.h"
4
5
#include "glm/fwd.hpp"
6
7
#include <experimental/optional>
8
#include <functional>
9
10
// forward declarations //////////////////////////////////////////////////////
11
12
namespace
cl
{
13
class
Buffer;
14
class
CommandQueue;
15
}
// namespace cl
16
17
namespace
wayverb
{
18
19
namespace
waveguide {
20
struct
voxels_and_mesh;
21
struct
single_band_parameters;
22
struct
multiple_band_constant_spacing_parameters;
23
}
// namespace waveguide
24
25
namespace
core
{
26
class
compute_context;
27
struct
environment;
28
}
// namespace core
29
30
namespace
combined {
31
32
// interesting stuff /////////////////////////////////////////////////////////
33
34
class
waveguide_base
{
35
public
:
36
waveguide_base
() =
default
;
37
waveguide_base
(
const
waveguide_base
&) =
default
;
38
waveguide_base
(
waveguide_base
&&) noexcept =
default
;
39
waveguide_base
& operator=(
const
waveguide_base
&) =
default
;
40
waveguide_base
& operator=(
waveguide_base
&&) noexcept =
default
;
41
virtual
~
waveguide_base
() noexcept =
default
;
42
43
virtual
std::unique_ptr<waveguide_base> clone()
const
= 0;
44
45
virtual
double
compute_sampling_frequency()
const
= 0;
46
47
virtual
std::experimental::optional<
48
util::aligned::vector<waveguide::bandpass_band>>
49
run(
const
core::compute_context
& cc,
50
const
waveguide::voxels_and_mesh
& voxelised,
51
const
glm::vec3& source,
52
const
glm::vec3& receiver,
53
const
core::environment
& environment,
54
double
simulation_time,
55
const
std::atomic_bool& keep_going,
56
std::function<
void
(cl::CommandQueue& queue,
57
const
cl::Buffer& buffer,
58
size_t
step,
59
size_t
steps)> pressure_callback) = 0;
60
};
61
62
std::unique_ptr<waveguide_base> make_waveguide_ptr(
63
const
waveguide::single_band_parameters
& t);
64
std::unique_ptr<waveguide_base> make_waveguide_ptr(
65
const
waveguide::multiple_band_constant_spacing_parameters
& t);
66
67
}
// namespace combined
68
}
// namespace wayverb
wayverb::combined::waveguide_base
Definition:
waveguide_base.h:34
cl
Definition:
waveguide_base.h:12
core
Definition:
traits.cpp:2
wayverb::waveguide::single_band_parameters
Definition:
simulation_parameters.h:9
wayverb::core::environment
Definition:
environment.h:6
wayverb
Definition:
capsule_base.h:9
wayverb::waveguide::voxels_and_mesh
Definition:
mesh.h:43
wayverb::core::compute_context
invariant: device is a valid device for the context
Definition:
common.h:13
wayverb::waveguide::multiple_band_constant_spacing_parameters
Definition:
simulation_parameters.h:32
src
combined
include
combined
waveguide_base.h
Generated by
1.8.11