Add Framwork for Assignment 3

This commit is contained in:
hal8174 2024-06-13 13:53:07 +02:00
parent a2d7f5c414
commit c864d2a42f
14 changed files with 50048 additions and 48111 deletions

View file

@ -0,0 +1,37 @@
#pragma once
#include <random_sampler.hpp>
namespace embree {
// Wrapper class
class RandomSamplerWrapper {
public:
RandomSampler sampler;
virtual void init(int id) {
RandomSampler_init(sampler, id);
}
virtual void init(int pixelID, int sampleID) {
RandomSampler_init(sampler, pixelID, sampleID);
}
virtual void init(int x, int y, int sampleID) {
RandomSampler_init(sampler, x, y, sampleID);
}
virtual float get1D() {
return RandomSampler_get1D(sampler);
}
virtual Vec2f get2D() {
return RandomSampler_get2D(sampler);
}
virtual Vec3fa get3D() {
return RandomSampler_get3D(sampler);
}
};
}