Adaptive Sampling
Adaptive sampling is a feature which allows you to reduce computing time on framebuffer’s areas that converge faster.
Usage
Attach a Variance AOV to this Context:
rpr_framebuffer framebufferVariance = nullptr; rprContextCreateFrameBuffer(context_, fmt, &desc, &framebufferVariance); rprContextSetAOV(context_, RPR_AOV_VARIANCE, framebufferVariance);
Set the following parameters:
// Size of the sampling area in pixels – recommended: [4, 16] rprContextSetParameterByKey1u(context_,RPR_CONTEXT_ADAPTIVE_SAMPLING_TILE_SIZE,16); // Minimum number of samples per pixel before activating Adaptive sampling // Recommended to set 10 or more rprContextSetParameterByKey1u(context_,RPR_CONTEXT_ADAPTIVE_SAMPLING_MIN_SPP,10); // Tolerance of the Adaptive Sampler // Between 0 and 1 // Lower value means better quality final image rprContextSetParameterByKey1f(context_,RPR_CONTEXT_ADAPTIVE_SAMPLING_THRESHOLD,0.1f);