Skip to main content
Glama

Read texture pixels

bb_get_texture_pixel

Read a rectangle of pixels from a texture to verify drawing results, returning rows of [r,g,b,a] values.

Instructions

Read a rectangle of pixels from a texture. Use this to verify what was drawn: it returns rows of [r,g,b,a].

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
hNo
wNo
xNo
yNo
targetsYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv2.0.0

TDQS

B3.2/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are provided, so the description carries the full burden. It usefully discloses the return shape ('rows of [r,g,b,a]'), which is real behavioral value, but omits coordinate origin/convention, out-of-bounds behavior, and texture-target semantics.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences with zero waste; the core action is front-loaded and the return format is attached where it matters.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness2/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, and while the return format is described, the five undocumented parameters (especially the required, untyped 'targets') and the absence of any annotation coverage leave significant gaps for calling this correctly.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters2/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 0% across five parameters, and the description does not compensate: x, y, w, h are only implied by 'rectangle', and the required 'targets' parameter is never explained at all. An agent cannot determine valid values for targets from this text.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb+resource ('Read a rectangle of pixels from a texture') and adds a downstream purpose ('verify what was drawn'). It is distinguishable from siblings like bb_draw_texture and bb_paint_pixels, though it never names them explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Provides one implied usage context ('verify what was drawn'), which is better than nothing, but gives no when-not conditions, no prerequisites, and no mention of alternative read paths (e.g. bb_screenshot).

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.