Agent skill
validate-render-kzahedi-yars-2
Validates YARS rendering by exporting first frame as PNG and comparing with reference screenshot
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/validate-render-kzahedi-yars-2
SKILL.md
Validate YARS Rendering
This skill ensures that rendering and texture functionality works correctly by:
- Running YARS with image export enabled to capture the first frame
- Comparing the exported frame with the reference screenshot.png
- Reporting any visual differences that might indicate rendering issues
Usage
Automatically invoked when:
- User asks to check visualization or rendering
- After graphics/texture changes
- When validating material or shader modifications
- To verify Ogre3D rendering is working correctly
Validation Steps
# Navigate to build directory
cd build
# Create frames directory for output
mkdir -p frames
# Run YARS with frame capture
# NOTE: Frame export requires setting frames directory in XML config
# or via __YARS_GET_FRAMES_DIRECTORY macro
# Frame capture auto-enables if directory is set (see SdlWindow.cpp:82-88)
timeout 60s ./bin/yars --xml ../xml/braitenberg.xml --iterations 10
# Expected output: frames/frame_00000001.png through frame_00000010.png
# Compare first frame with reference using ImageMagick
compare -metric RMSE frames/frame_00000001.png ../screenshot.png diff.png
# Or use visual diff
# open frames/frame_00000001.png
# open ../screenshot.png
Success Criteria
- ✅ YARS builds and runs without errors
- ✅ Frames are successfully exported to frames/ directory
- ✅ Exported images are valid PNG files
- ✅ Visual comparison shows matching rendering (textures, geometry, lighting)
- ✅ Pixel difference within acceptable threshold
Configuration Notes
Frame Export Setup (from SdlWindow.cpp):
- Auto-enables when
__YARS_GET_FRAMES_DIRECTORYis set - Exports to:
{framesDir}/frame_{index:08d}.png - Uses Ogre3D's
RenderTexture::writeContentsToFile()
To Enable Frame Export:
- Check XML config for frames directory setting
- OR modify configuration to set frames output directory
- Frames will be captured automatically each step
Known Limitations
- Need to determine exact XML config or command-line option for frames directory
- Reference screenshot.png may be from specific simulation state
- May need to match exact camera position/orientation
- Lighting and shadow settings affect visual comparison
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?