Lightmetrica  0.0.1.50dbee3 (yosakoi)
 All Classes Functions Variables Typedefs Enumerations Enumerator
pssmlt.sampler.h
1 /*
2  Lightmetrica : A research-oriented renderer
3 
4  Copyright (c) 2014 Hisanari Otsu
5 
6  This program is free software: you can redistribute it and/or modify
7  it under the terms of the GNU General Public License as published by
8  the Free Software Foundation, either version 3 of the License, or
9  (at your option) any later version.
10 
11  This program is distributed in the hope that it will be useful,
12  but WITHOUT ANY WARRANTY; without even the implied warranty of
13  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  GNU General Public License for more details.
15 
16  You should have received a copy of the GNU General Public License
17  along with this program. If not, see <http://www.gnu.org/licenses/>.
18 */
19 
20 #pragma once
21 #ifndef LIB_LIGHTMETRICA_PSSMLT_SAMPLER_H
22 #define LIB_LIGHTMETRICA_PSSMLT_SAMPLER_H
23 
24 #include "sampler.h"
25 #include "math.types.h"
26 
27 LM_NAMESPACE_BEGIN
28 
29 class Random;
30 class RewindableSampler;
31 
43 {
44 public:
45 
46  LM_COMPONENT_INTERFACE_DEF("pssmltprimarysampler");
47 
48 public:
49 
51  virtual ~PSSMLTPrimarySampler() {}
52 
53 public:
54 
63  virtual void Configure(Random* rng, const Math::Float& s1, const Math::Float& s2) = 0;
64 
69  virtual void Accept() = 0;
70 
76  virtual void Reject() = 0;
77 
83  virtual void EnableLargeStepMutation(bool enable) = 0;
84 
90  virtual bool LargeStepMutation() const = 0;
91 
101  virtual void BeginRestore(RewindableSampler& rewindableSampler) = 0;
102 
108  virtual void EndRestore() = 0;
109 
110 public:
111 
112  virtual void GetCurrentSampleState(std::vector<Math::Float>& samples) const = 0;
113  virtual void GetCurrentSampleState(std::vector<Math::Float>& samples, int numSamples) = 0;
114 
115 };
116 
117 LM_NAMESPACE_END
118 
119 #endif // LIB_LIGHTMETRICA_PSSMLT_SAMPLER_H
virtual void Configure(Random *rng, const Math::Float &s1, const Math::Float &s2)=0
Definition: random.h:33
Definition: rewindablesampler.h:35
virtual void EndRestore()=0
virtual bool LargeStepMutation() const =0
virtual void EnableLargeStepMutation(bool enable)=0
Definition: pssmlt.sampler.h:42
virtual void Accept()=0
virtual void Reject()=0
Definition: sampler.h:37
virtual void BeginRestore(RewindableSampler &rewindableSampler)=0