             segmentStartPos_eye, endPosCut_eye, fragmentColor);
         finalColor = finalColor + fragmentColor * (1.0f - finalColor.a);
       }
-      setPositionAndDepth(endPosCut_eye);
+      position = fromEyeToNdcSpace(endPos_eye);
       outputColor = clamp(finalColor, vec4(0.0), vec4(1.0));
       finalColor = vec4(0);
       segmentStartPos_eye = endPosCut_eye;

    updateActiveObjects(objectId, activeObjects);
    int activeObjectCount = bitCount(activeObjects);

    /*
    if (objectId == 0 && fragmentColor.w > alphaThresholdForDepth)
    {
      setPositionAndDepth(currentFragment.eyePos);
    }
    */

    // fetch next Fragment
    nextFragmentReadStatus = false;

    fragmentColor = fragmentColor + sampleColor * (1.0f - fragmentColor.a);

    if (fragmentColor.a > alphaThresholdForDepth)
    {
      gl_FragDepth = fromEyeToNdcSpace(startPos_eye).z;
    }

    // early ray termination
    if (fragmentColor.a > 0.999)
