   // Calc hits with clip sphere.
   float tsnear = 0.0f;
   float tsfar = 0.0f;
-  if (t_clipSphere)
+  if (t_clipping && clipSphere)
   {
     // In probe mode, rays that don't hit the sphere simply aren't rendered.
     // In ordinary sphere mode, the intersection data is memorized.
-    if (!intersectSphere(ray, sphereCenter, sphereRadius, &tsnear, &tsfar) && t_useSphereAsProbe)
+    if (!intersectSphere(ray, sphereCenter, sphereRadius, &tsnear, &tsfar) && useSphereAsProbe)
     {
       d_output[y * texwidth + x] = make_uchar4(0);
       return;

         bool t_illumination,
         bool t_opacityCorrection,
         bool t_earlyRayTermination,
         bool t_clipPlane,
         bool t_clipSphere,
         bool t_useSphereAsProbe,
         int t_mipMode,
         bool t_useIbr
        >

                       const float3 volPos, const float3 volSizeHalf,
                       const float3 probePos, const float3 probeSizeHalf,
                       const float3 L, const float3 H,
                       const bool clipPlane,
                       const bool clipSphere,
                       const bool useSphereAsProbe,
                       const float3 sphereCenter, const float sphereRadius,
                       const float3 planeNormal, const float planeDist,
                       void* d_depth, int dp,
