Wayverb
program.h
1 #pragma once
2 
3 #include "raytracer/cl/structs.h"
4 
5 #include "core/program_wrapper.h"
6 #include "core/spatial_division/scene_buffers.h"
7 
8 namespace wayverb {
9 namespace raytracer {
10 namespace stochastic {
11 
12 class program final {
13 public:
14  program(const core::compute_context& cc);
15 
16  auto get_kernel() const {
17  return program_wrapper_.get_kernel<cl::Buffer, // reflections
18  cl_float3, // receiver
19  cl_float, // receiver radius
20  cl::Buffer, // triangles
21  cl::Buffer, // vertices
22  cl::Buffer, // surfaces
23  cl::Buffer, // stochastic path info
24  cl::Buffer, // stochastic output
25  cl::Buffer // intersected output
26  >("stochastic");
27  }
28 
29  auto get_init_stochastic_path_info_kernel() const {
30  return program_wrapper_.get_kernel<cl::Buffer, // buffer
31  core::bands_type, // initial energy
32  cl_float3 // initial position
33  >("init_stochastic_path_info");
34  }
35 
36 private:
37  core::program_wrapper program_wrapper_;
38 };
39 
40 } // namespace stochastic
41 } // namespace raytracer
42 } // namespace wayverb
Definition: program_wrapper.h:8
Definition: pressure.h:22
Definition: capsule_base.h:9
invariant: device is a valid device for the context
Definition: common.h:13