Depth Map Techniques

A grayscale image representing distance from the camera, where brightness indicates depth. Used with ControlNet to maintain spatial structure during generation.

Depth maps provide 3D spatial information to guide AI image generation.

How Depth Maps Work

  • White areas: Close to camera
  • Black areas: Far from camera
  • Gray gradients: Intermediate distances

Creating Depth Maps

From Photos (Estimation)

  • MiDaS, Depth Anything models
  • Built into most ControlNet UIs
  • Approximate but effective

From 3D Software

  • Render depth pass
  • Exact depth values
  • Perfect for 3D-assisted workflows

Hand-Drawn

  • Simple geometric depth
  • Rough spatial guidance
  • Minimal effort

Using with ControlNet

  1. Load image or create depth map
  2. Apply depth preprocessor if needed
  3. Use Depth ControlNet model
  4. Set control strength (0.5-1.0)
  5. Generate with desired prompt

Use Cases

  • Scene reconstruction: Maintain room layout
  • Character posing: Preserve depth relationships
  • Landscape control: Keep foreground/background
  • Object placement: Correct spatial ordering

Depth vs Other Controls

ControlWhat It Captures
Depth3D spatial relationships
CannyEdge outlines
PoseHuman skeleton
SegmentationObject regions

Tips

  • Combine depth with other controls
  • Lower strength for more creativity
  • Clean up estimated depth maps
  • Works best with clear depth separation