Fill Rate, Overdraw, Transparency, and Why Your GPU Is Crying

When people say “fill rate problem” in Unity, they usually mean one thing: the GPU is being asked to shade too many pixels. Not too many objects. Not too many scripts. Pixels. Fill Rate, Overdraw, Transparency, and Why Your GPU Is Crying. Lets learn!

Overdraw is the main reason this happens. But not all overdraw is equal, and not all of it is a mistake.

Let’s break this properly.


What Fill Rate Actually Means

Fill rate is how fast the GPU can draw and shade pixels on the screen.

If the same pixel is drawn once, life is good.
If it’s drawn 5 times in one frame, the GPU does 5x the work for the same final image. Suppose a painter who paints the wall five times!

That’s overdraw.

Too much overdraw → GPU-bound → FPS tanks while CPU looks bored.


Overdraw Is Not One Thing. There Are Three Scenarios.

1. Transparent Objects: Necessary Overdraw

Transparent objects must cause overdraw. This is not a Unity problem. This is math.

If you want:

  • Glass
  • UI
  • Particles
  • Smoke
  • VFX
  • Fences with alpha
  • Fading sprites

Then the GPU has to:

  1. Draw what’s behind
  2. Draw the transparent thing on top
  3. Blend colors

There is no shortcut. You cannot depth-test your way out of transparency.

This means:

  • Transparent objects are rendered back-to-front
  • Every layer adds more pixel shading work
  • Overdraw is guaranteed

Verdict:
This overdraw is by design. You cannot eliminate it. You can only reduce layers, screen coverage, and shader cost.

This is where most fill rate problems come from. Especially on mobile.


2. Opaque Objects: Unnecessary Overdraw (Waste)

Opaque objects can cause overdraw, but they shouldn’t. If they do, something went wrong.

Imagine:

  • A big wall
  • A small box is completely hidden behind it

Bad Case: Back-to-Front Rendering

GPU draws the hidden box first.
Then draws the wall over it.

Result:

  • Pixels for the box were shaded
  • Then thrown away
  • Total waste

Good Case: Front-to-Back Rendering

GPU draws the wall first.
Then checks depth when trying to draw the box.
Depth buffer says: “Already blocked.”

So the GPU skips drawing those pixels entirely.

This is called Early-Z Rejection.

Unity’s Role

Unity automatically sorts opaque objects front-to-back to maximize Early-Z rejection.

That’s why:

  • Opaque geometry usually does not cause fill rate problems
  • Overdraw from opaque objects is considered a bug or bad setup

If your opaque objects are causing fill rate issues, something is off:

  • Wrong render queue
  • Alpha-tested shaders pretending to be opaque
  • Too many decals
  • Weird custom shaders


3. The Hidden Killer: Post-Processing Overdraw

This is the part people forget and then blame “Unity performance.”

Post-processing effects like:

  • Bloom
  • Blur
  • Color Grading
  • Vignette
  • Film Grain
  • Motion Blur

Each one:

  • Reads the entire screen
  • Writes the entire screen
  • Often multiple times

If your screen is 1920×1080, a single fullscreen effect is roughly equivalent to drawing a massive transparent quad covering the whole screen.

Add several effects, and congratulations:

  • You are overdrawing every pixel multiple times
  • Every frame
  • No depth rejection possible

This is why:

  • Turning off post-processing gives instant FPS boost
  • Mobile GPUs especially suffer
  • GPU becomes fill-rate bound even in simple scenes


How This Turns Into a GPU-Bound Problem

You are GPU-bound when:

  • CPU finishes early
  • GPU frame time keeps growing
  • Reducing resolution improves FPS
  • Turning off transparency or post-processing helps immediately

Classic symptoms:

  • Lots of UI
  • Heavy particles
  • Glass everywhere
  • Full-screen effects
  • High resolution

This is not about draw calls. This is pixel math.


Final Mental Model

  • Transparent objects: Overdraw is unavoidable. Manage it. Reduce layers. Reduce coverage.

  • Opaque objects: Overdraw should be minimized automatically. If it isn’t, something is wrong.

  • Post-processing: Full-screen overdraw. Extremely expensive. Treat with suspicion.

If you remember one thing:

Fill rate problems are about how many times the GPU shades the same pixel, not how many objects you see.

Unity doesn’t magically fix this. Physics doesn’t care. Scripts don’t matter. The GPU just does the work you ask for, even if the work is pointless.

And yes, most of the time, the lag is coming from transparency and post effects. Not your gameplay code.

Post a Comment

0 Comments