Field curvature

Why a lens can focus a flat subject onto a curved surface — and how a field-dependent disk blur reveals the mismatch with a flat sensor.

Visible effect

The centre is sharp while flat detail softens toward the edge

When the image centre is focused on a flat sensor, detail can soften progressively toward the edges. Refocusing can move the sharp zone across the field, but it cannot make a genuinely curved best-focus surface coincide with the whole sensor at once.

The signature is position-dependent focus, not bent geometry. Straight lines keep their paths while fine texture and point highlights spread into larger circles of confusion away from the chosen sharp zone.

Physics

The lens forms its sharpest image on a curved surface

A curved best-focus surface does not coincide with a flat sensor On-axis and off-axis ray bundles pass through a lens. Their best-focus points lie on a curved image surface, while a flat sensor intersects only the central focus and records peripheral circles of confusion.lensflat sensorcurved best-focus surface
The flat sensor meets the best-focus surface on axis. Off-axis bundles have already crossed their focus before reaching it, so their footprints grow with field height even though the subject lies on one flat plane.

An ideal flat-field lens brings points from a flat subject plane to a flat image plane. In a lens with Petzval field curvature, the locus of best focus bends. A flat sensor can coincide with that locus only along a selected zone, so ray bundles elsewhere meet before or after the sensor and form circles of confusion.

Mathematics

A curved focal surface becomes a field-dependent blur radius

Let ρ be aspect-correct normalized distance from the optical axis. Near the axis, the sag of a rotationally symmetric surface begins approximately quadratically, sop = 2 is the default. The flat-sensor approximation maps that axial mismatch to a circle-of-confusion radius:

Redge is an artistic pixel calibration rather than a lens prescription. The power control changes how quickly softness appears across the field. The isolated model chooses the optical axis as the sharp zone and therefore satisfiesR(0) = 0; refocusing a physical lens can move that sharp zone away from the centre.

Shader

GLSL field-dependent disk gather

Each fragment measures its field radius, converts it to a local blur radius, and gathers deterministic disk samples in linear light.

fieldCurvatureDiskGLSL
// WHAT: Approximate a curved focal surface with blur that grows off axis.
// HOW: Convert field position to a local disk radius, choose a proportional
// bounded tap count, and gather an equal-area disk in linear light.
// WHY: A flat sensor intersects a curved best-focus surface progressively away
// from centre, so one uniform full-frame blur would hide the defining behavior.
const int FIELD_CURVATURE_MAX_SAMPLES = 96;
const float FIELD_CURVATURE_GOLDEN_ANGLE = 2.39996323;

float srgbToLinearChannel(float value) {
  if (value <= 0.04045) return value / 12.92;
  return pow((value + 0.055) / 1.055, 2.4);
}

vec3 srgbToLinear(vec3 value) {
  return vec3(
    srgbToLinearChannel(value.r),
    srgbToLinearChannel(value.g),
    srgbToLinearChannel(value.b)
  );
}

float fieldCurvatureRadius(
  vec2 sourceUv,
  vec2 opticalCenter,
  float sourceAspect,
  float edgeBlurPx,
  float fieldPower
) {
  vec2 field = sourceUv - opticalCenter;
  // Aspect correction makes equal optical field radii circular on screen.
  float rho = clamp(
    length(vec2(field.x * sourceAspect, field.y)) * 2.0,
    0.0,
    1.0
  );
  return edgeBlurPx * pow(rho, max(fieldPower, 0.1));
}

vec3 fieldCurvatureDisk(
  sampler2D source,
  vec2 sourceUv,
  vec2 sampleStep,
  vec2 opticalCenter,
  float sourceAspect,
  float edgeBlurPx,
  float fieldPower,
  int sampleCount
) {
  float radiusPx = fieldCurvatureRadius(
    sourceUv,
    opticalCenter,
    sourceAspect,
    edgeBlurPx,
    fieldPower
  );
  // Small local radii do not need the full worst-case sampling budget.
  int localSampleCount = min(
    sampleCount,
    max(1, int(ceil(radiusPx * 8.0)))
  );
  float count = float(localSampleCount);
  float lod = max(0.0, log2(max(radiusPx, 1.0)) - 2.0);
  vec3 accumulated = vec3(0.0);

  for (int index = 0; index < FIELD_CURVATURE_MAX_SAMPLES; index += 1) {
    if (index >= localSampleCount) break;
    // Equal-area golden-angle taps avoid rings as the local radius changes.
    float fraction = (float(index) + 0.5) / count;
    float sampleRadius = sqrt(fraction);
    float angle = float(index) * FIELD_CURVATURE_GOLDEN_ANGLE;
    vec2 disk = vec2(cos(angle), sin(angle)) * sampleRadius;
    vec3 encoded = textureLod(
      source,
      sourceUv + disk * sampleStep * radiusPx,
      lod
    ).rgb;
    accumulated += srgbToLinear(encoded);
  }

  // Normalize the linear-light sum so blur radius does not change exposure.
  return accumulated / count;
}
Processing pipelineBoxes mark actual render-pass boundaries.
  1. Source texturesRGB
  2. Field-dependent disk gatherOne fullscreen render pass
    • Calculate the aspect-correct field radius
    • Calculate the local disk radius
    • Take mip-prefiltered disk samples
    • Average in linear light
    • Mix and encode to sRGB
  3. Display output

Why these steps are here

  1. Measure the field in aspect-correct coordinates.Equal optical field angles should not depend on canvas shape.
  2. Keep the axis invariant. Multiplication byρᵖ makes the isolated effect vanish at the centre.
  3. Use a disk, not a screen-space warp. Defocused point energy occupies an area around the original point.
  4. Normalize in linear light. Averaging preserves uniform regions and avoids gamma-darkened blur.
  5. Bound the cost. The deterministic gather rises with maximum edge radius and stops at ninety-six taps.

Notes

  • The grid makes the defining evidence visible: lines remain geometrically straight while their edge contrast falls.
  • A single RGB image has no scene depth or measured focal-surface map. The playground demonstrates one flat-subject approximation.
  • Tangential and sagittal focal surfaces may separate as well as curve. That directional line spread belongs to astigmatism and is kept out of this circular kernel.
  • Real correction depends on lens prescription, focus distance, aperture, wavelength, sensor position, and any field-flattening elements.

References

Edmund Optics — How aberrations affect imaging lenses — manufacturer reference for spherical, astigmatic, field-curvature, and chromatic aberrations.

Nikon MicroscopyU — Introduction to microscope objectives — manufacturer educational reference on coma, astigmatism, field curvature, chromatic correction, and flare.