 		return;
 	}
 
+#ifdef ENABLE_PROGRESSIVE
 #if IDATEN_SAMPLER == IDATEN_SAMPLER_SOBOL
 	auto scramble = random[idx] * 0x1fe3434f;
 	path.sampler.init(frame, 0, scramble, sobolmatrices);

	int sample = path.samples;

	float4 data;
#if 1
	surf2Dread(&data, outSurface, ix * sizeof(float4), iy);

	// First data.w value is 0.

	auto rnd = random[idx];
	auto scramble = rnd * 0x1fe3434f * ((frame + 133 * rnd) / (aten::CMJ::CMJ_DIM * aten::CMJ::CMJ_DIM));
	path.sampler.init(frame % (aten::CMJ::CMJ_DIM * aten::CMJ::CMJ_DIM), 0, scramble);
#endif
#else
	auto scramble = (iy * height * 4 + ix * 4) * maxSamples + sample + 1 + frame;
	path.sampler.init(frame, 0, scramble, sobolmatrices);
#endif

	float s = (ix + path.sampler.nextSample()) / (float)(camera->width);
