Skip to content

Ability to reliably generate transparent images #18636

@Alan01252

Description

@Alan01252

What variant of Codex are you using?

codex-cli 0.122.0-alpha.10

What feature would you like to see?

Codex currently exposes the built-in Responses
image_generation tool, but the serialized tool spec
appears to only include:

  {
    "type": "image_generation",
    "output_format": "png"
  } 

This makes it hard to reliably generate transparent PNG
assets. Prompting for “transparent background”, “alpha
channel”, or “alpha=0 outside the subject” often still
produces an opaque RGB image with a fake checkerboard or
matte background.

The Responses image generation tool supports options such
as:

 {
    "type": "image_generation",
    "output_format": "png",
    "background": "transparent",
    "quality": "high"
  }

It would be useful if Codex exposed these options, either
through configuration or an enhanced built-in image tool
schema.

Use case:

I am building small web games and need generated sprites/
assets with real alpha transparency so they can be
composited over game backgrounds without halos,
checkerboards, or matte cleanup. This matters for workflows
where Codex generates image assets and then writes them into
a project.

Suggested implementation:

  • Extend Codex’s ImageGeneration tool spec to include
    optional background, quality, and possibly size.
  • Allow background: "transparent" when output_format is png
    or webp.
  • Optionally expose a config default, e.g.
    image_generation.background = "transparent" and
    image_generation.quality = "high".
  • Preserve the current default behavior if no config is set.

Why this matters:

Without the background parameter, users must rely on prompt-
only transparency requests, which are unreliable. The
fallback is chroma-key or checkerboard extraction, which
adds artifacts and extra cleanup. Real alpha output would
make Codex much better at producing usable game art, UI
assets, stickers, icons, and composited web visuals.

Additional information

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requesttool-callsIssues related to tool calling

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions