Home / Blog / Midpoint Circle Algorithm
TECHNICAL DEEP-DIVE

How the Midpoint Circle Algorithm Works (For Minecraft Builders)

Every circle generator on the internet — including this one — relies on the same decades-old technique to turn a radius into a block pattern. Here’s what it’s actually doing, shown step by step rather than as a wall of math.

blockcirclegenerator.com Guides

Turning a radius into a set of block positions sounds simple, but doing it efficiently — without checking every single block in a square area to see if it happens to fall on the circle — took real thought to solve well. The midpoint circle algorithm (a close relative of the earlier Bresenham circle algorithm) is the standard answer, and it’s the same underlying method this site’s generators, most game engines, and most graphics libraries use. Understanding it isn’t necessary to use a circle generator, but it explains exactly why circles round the way they do, and why that rounding is consistent no matter which tool draws it.

The core insight: eight-way symmetry

A circle looks identical if you rotate it by 45 degrees eight times, or flip it across its horizontal, vertical, or either diagonal axis. This means a single calculated point on the circle’s edge has seven mirrored twins elsewhere on the same circle, at predictable positions. The algorithm exploits this directly: instead of calculating all the way around the circle, it only calculates one-eighth of it — a single octant, typically the section from straight up to the 45-degree diagonal — then mirrors that same calculated data into the other seven positions.

One calculated point (amber) mirrored to 7 others (green)

The amber cell above is the single point the algorithm actually computes for that step. The seven green cells at the same step are placed automatically by reflecting that one point’s coordinates across the circle’s symmetry axes — no separate calculation needed for any of them.

What the algorithm actually tracks

Starting at the top of the circle (directly above center) and moving one column outward at a time, the algorithm tracks a single running value — often called the decision parameter — that answers one question at each step: has the curve drifted far enough that the row needs to move down by one block, or does it stay at the current row? This decision parameter updates using simple addition at each step rather than needing a full distance calculation from scratch every time, which is what made the original algorithm fast enough to matter on early, computationally limited hardware — and it’s still the efficient choice today.

Walking through it step by step

  1. Start at the topmost point of the circle, directly above the center, and initialize the decision parameter based on the radius.
  2. Plot that starting point, and its seven mirrored positions around the circle, using the eight-way symmetry described above.
  3. Move one column outward (away from the vertical center line) and check the decision parameter: if it indicates the curve has moved closer to the center than the current row allows, drop the row down by one and update the parameter accordingly.
  4. Plot the new point and its seven mirrors again.
  5. Repeat steps 3 and 4 until the calculated column and row meet at the 45-degree diagonal — the boundary of the octant being calculated — at which point the entire circle has been plotted through symmetry alone.

See the algorithm’s output directly — generate any diameter and watch the resulting block pattern instantly.

Open the Circle Generator

Why this explains circle delta

At every step, the algorithm has to choose one of two possible rows for the current column — it can’t split the difference, since blocks only exist at whole-number positions. The decision parameter’s entire job is picking whichever row keeps the plotted point closest to the true mathematical curve. That per-step rounding choice is exactly what’s discussed elsewhere on this site as circle delta — the algorithm doesn’t create delta, it’s the mechanism that manages it as evenly as possible across the whole shape.

From flat circles to spheres

A sphere extends this same idea into three dimensions two ways at once: each horizontal layer is its own midpoint-circle calculation for that layer’s specific radius, and the radius itself is determined layer by layer using the sphere’s overall radius and how far that layer sits from the vertical center — the same relationship discussed in this site’s sphere-building guide. The algorithm doesn’t fundamentally change for 3D; it’s simply run once per layer, with each layer’s radius calculated first from the sphere’s overall dimensions.

Does every circle generator use exactly this method?

Most do, or use a close variant, since it’s the standard, well-tested approach rather than something built from scratch for any one tool. Minor implementation differences — how ties are broken when a point sits exactly between two rows, for instance — can cause a one-block difference at the boundary between two tools’ output for the same diameter, but the overall shape and the general rounding behavior stay consistent across virtually every implementation, because they’re all solving the same underlying symmetry problem the same way.

Why builders don’t need to know this to use a generator

None of the above is required knowledge to build a good circle — a generator or a size chart hands over the finished result without needing the underlying calculation understood at all. What this explanation does provide is a clear answer to “why does my circle round the way it does,” which otherwise can feel arbitrary. Once the eight-way symmetry and the per-step rounding decision are visible, the behavior of every circle, sphere, and arch on this site stops looking like an unexplained quirk and starts looking like the predictable output of a specific, well-defined process.

A simplified version anyone can trace by hand

For a small circle — 9 or 11 blocks — it’s entirely possible to trace the algorithm’s logic by hand: start at the top, and for each step outward, ask whether the next block down is closer to the true radius than staying on the current row. This is exactly the same “which block is closest to the curve” reasoning a builder does instinctively when placing blocks from a picture or count, just without the systematic decision-parameter tracking that keeps a generator’s version perfectly consistent across all eight octants simultaneously.

FAQ

Frequently asked questions

What is the midpoint circle algorithm? +

A method for drawing a circle on a grid by calculating one-eighth of the curve mathematically, then mirroring it into the other seven positions using the circle’s symmetry, rather than recalculating every point.

Why does the algorithm only calculate one-eighth of the circle? +

A circle is symmetric across eight equal octants around its center. Calculating one and mirroring it produces the identical result to calculating all eight directly, with far less computation.

Is this the algorithm Minecraft circle generators actually use? +

Most use this algorithm or a close variant, since it’s the standard, well-established method for drawing circles on any pixel or block grid.