00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024 #if defined(_MSC_VER)
00025 #pragma once
00026 #endif
00027
00028 #ifndef PBRT_SAMPLERS_HALTON_H
00029 #define PBRT_SAMPLERS_HALTON_H
00030
00031
00032 #include "sampler.h"
00033 #include "film.h"
00034
00035
00036 class HaltonSampler : public Sampler {
00037 public:
00038 HaltonSampler(int xs, int xe, int ys, int ye, int ps, float sopen, float sclose);
00039 int MaximumSampleCount() { return 1; }
00040 int GetMoreSamples(Sample *sample, RNG &rng);
00041 Sampler *GetSubSampler(int num, int count);
00042 int RoundSize(int size) const { return size; }
00043
00044 private:
00045
00046 int wantedSamples, currentSample;
00047 };
00048
00049
00050 HaltonSampler *CreateHaltonSampler(const ParamSet ¶ms, const Film *film,
00051 const Camera *camera);
00052
00053 #endif // PBRT_SAMPLERS_HALTON_H