---
title: "Origin of the DMC Sampler"
canonical: "https://documentation.chaos.com/space/THEORY/116719663/Origin%20of%20the%20DMC%20Sampler"
format: markdown
---
This page provides information on the DMC Sampler used in V-Ray.

 

## <span style="color: #000000"> </span><span style="color: #000000">**Overview**</span>

---

<span style="color: #000000">The DMC Sampler is a framework within V-Ray for determining exactly which samples are to be taken around pixels involved in "blurry" effects such as anti-aliasing, depth of field, indirect illumination, area lights, glossy reflections/refractions, translucency, motion blur, and so on. DMC stands for Deterministic Monte Carlo.</span>

 

## **Origin of DMC Sampler**

---

<span style="color: #000000">Monte Carlo (MC) sampling is a method for evaluating "blurry" values. Monte Carlo sampling uses pseudo-random numbers which are different for each and every evaluation, so re-rendering a single image would always produce slightly different results in the noise. V-Ray uses a variant of Monte Carlo sampling called deterministic Monte Carlo (DMC) which uses a predefined set of samples, so re-rendering an image always produces the exact same result. These samples might also be further optimized to reduce noise.</span>

<span style="color: #000000">Instead of having separate sampling methods for each of the blurry values, V-Ray has a single unified framework that determines exactly which samples (and exactly how many) are to be taken for a particular value, depending on the context in which that value is required. This framework is the DMC Sampler.</span>

<span style="color: #000000">By default, the deterministic Monte Carlo method used by V-Ray is a modification of Schlick sampling, introduced by Christophe Schlick in 1991 (see the  </span>[References](https://docs-chaos.atlassian.net/wiki/spaces/THEORY/pages/116719663/Origin+of+the+DMC+Sampler#References)<span style="color: #000000"> section below).</span>


## **Determining Values for DMC Sampler**

---

<span style="color: #000000">V-Ray determines the values automatically for the user. There are no settings that need tweaking, other than the actual samples for camera rays.</span>

<span style="color: #000000">In theory, the number of samples for blurry values is determined based on the following factors: </span>

- <span style="color: #000000">The importance of the value (for example, dark glossy reflections can do with fewer samples than bright ones, since the effect of the reflection on the final result is smaller; distant area lights require fewer samples than closer ones. Basing the number of samples allocated for a value on importance is called</span><span style="color: #000000">* importance sampling*</span><span style="color: #000000">.</span>
- <span style="color: #000000">The variance (think "noise") of the samples taken for a particular value - if the samples are not very different from each other, then the value can do with fewer samples; if the samples are very different, then a larger number of them will be necessary to get a good result. This basically works by looking at the samples as they are computed one by one and deciding, after each new sample, if more samples are required. This technique is called </span><span style="color: #000000">*early termination *</span><span style="color: #000000">or</span><span style="color: #000000">* *</span><span style="color: #000000">*[adaptive sampling](https://docs-chaos.atlassian.net/wiki/spaces/THEORY/pages/116719732)*</span><span style="color: #000000">. </span>


> Macro (anchor)



## <span style="color: #000000"> </span><span style="color: #000000">**References**</span><span style="color: #000000"> </span>

---

More information on deterministic Monte Carlo sampling for computer graphics can be found from the sources listed below.

- <span style="color: #000000">Schlick, C., 1991, </span><span style="color: #000000">**An Adaptive Sampling Technique for Multidimensional Integration by Ray Tracing**</span><span style="color: #000000">, in Second Eurographics Workshop on Rendering (Spain), pp. 48-56</span>  
<span style="color: #000000">*Describes deterministic MC sampling for antialiasing, motion blur, depth of field, area light sampling and glossy reflections. *</span>

- <span style="color: #000000">Masaki Aono and Ryutarou Ohbuchi, November 25, 1996, </span><span style="color: #000000">**Quasi-Monte Carlo Rendering with Adaptive Sampling**</span><span style="color: #000000">, IBM Tokyo Research Laboratory Technical Report RT0167, pp.1-5;</span>  
online version can be found <span style="color: #000000">[here](http://www.kki.yamanashi.ac.jp/~ohbuchi/online_pubs/eg96_html/eg96.htm)</span><span style="color: #000000">  </span>  
<span style="color: #000000"> </span><span style="color: #000000">*Describes an application of low discrepancy sequences to area light sampling and the global illumination problem.*</span>  
<span style="color: #000000">* *</span><span style="color: #000000"> </span>
- <span style="color: #000000"> Fajardo, M., August 13, 2001, </span><span style="color: #000000">**Monte Carlo Raytracing in Action**</span><span style="color: #000000">, in </span><span style="color: #000000">**State of the Art in Monte Carlo Ray Tracing for Realistic Image Synthesis**</span><span style="color: #000000">, SIGGRAPH 2001 Course 21, pp. 151-162;</span>  
<span style="color: #000000">online version can be found </span><span style="color: #000000">[here](http://cseweb.ucsd.edu/~viscomp/classes/cse274/wi18/readings/course29sig01.pdf)</span><span style="color: #000000">  </span>  
<span style="color: #000000"> </span><span style="color: #000000">*Describes the ARNOLD renderer employing randomized quasi-Monte Carlo sampling using low discrepancy sequences for pixel sampling, global illumination, area light sampling, motion blur, depth of field, etc.*</span>  
<span style="color: #000000">* *</span><span style="color: #000000"> </span>
- <span style="color: #000000">Veach, E., December 1997, </span><span style="color: #000000">**Robust Monte Carlo Methods for Light Transport Simulation**</span><span style="color: #000000">, Ph. D. dissertation for Stanford University, pp. 58-65</span>  
<span style="color: #000000">online version can be found</span> <span style="color: #000000">[here](http://graphics.stanford.edu/papers/veach_thesis/)</span><span style="color: #000000">  </span> <span style="color: #000000"> </span> <span style="color: #000000"> </span>  
<span style="color: #000000"> </span><span style="color: #000000">*Includes a description of low discrepancy sequences, quasi-Monte Carlo sampling and its application to solving the global illumination problem.*</span>  
<span style="color: #000000">* *</span><span style="color: #000000"> </span>
- <span style="color: #000000">Szirmay-Kalos, L., 1998, </span><span style="color: #000000">**Importance Driven Quasi-Monte Carlo Walk Solution of the Rendering Equation**</span><span style="color: #000000">, Winter School of Computer Graphics Conf., 1998</span>  
online version can be found <span style="color: #000000">[here](https://www.sciencedirect.com/science/article/abs/pii/S0097849399000308)</span>   
 <span style="color: #000000">*Describes a two-pass method for solving the global illumination problem employing quasi-Monte Carlo*</span> * sampling,* <span style="color: #000000">* as well as importance sampling using low discrepancy sequences.*</span>