Skip to content

Releases

shadersmith v0.3.0

Choose a tag to compare

@SalyyS1 SalyyS1 released this 14 Nov 18:13

Highlights in shadersmith v0.3.0

  • Official Minecraft 26.3 (97.1) Vanilla Contract Dataset: Extracted full vanilla core shader, GLSL include, post-effect, and std140 uniform block layouts for official release 26.3 (pack_format 97.1), with major.minor format tuple resolution (97.1) and release-aware --mc-range traversal.
  • Post-Effect Graph, Sampler, and std140 Block Cross-Checking (SM065..SM068):
    • SM065: Validates internal "targets" and "external_targets" across pass "inputs" and "output", catching undeclared framebuffers and read-before-write pass ordering bugs.
    • SM066: Cross-checks pass inputs[].sampler_name (<Name>Sampler) against uniform sampler2D declarations across pack fragment shaders and transitive includes.
    • SM067: Verifies pass "uniforms" member names, types, and positional order against GLSL layout(std140) uniform block declarations.
    • SM068: Reports malformed post_effect/*.json files with syntax diagnostics, while refining SM062 to recognize valid vanilla post vertex shaders (minecraft:post/rotscale) and auto-migrate stale screenquad paths.
  • Circular Include Detection (SM033), Comment-Safe GLSL Analysis, and pack.mcmeta Bounds Validation (SM075):
    • SM033: Deterministic DFS cycle detection across #include and #moj_import chains.
    • Line-preserving // and /* ... */ comment stripping prevents false positives on commented-out directives, gl_VertexID, samplers, and uniform blocks, while extending SM050 to catch flat/smooth/noperspective/centroid bare interface variables.
    • SM075: Flags inverted min_format..max_format bounds and invalid overlays.entries directory names violating [a-zA-Z0-9_-]+.
  • Rich OASIS SARIF v2.1.0 Catalog & GitHub Action v0.3.0: Added --format sarif, full RuleCatalog descriptors (SM001..SM075) with %SRCROOT% relative URIs, and sarif-file / exit-code outputs on SalyyS1/shadersmith@v0.3.0.
  • Zero-Upload Browser GLSL & Overlay Inspector: Live at https://salyys1.github.io/shadersmith/ with client-side .zip decompression, 1.21.4..26.3 compatibility matrix, std140 byte-offset diff explorer, and 1-click mechanical migration.

SHA-256 Checksum

  • shadersmith-0.3.0.jar: 57dc3fb3e47f2fae4458c8a823b3df45c398aef512c7e3ff44da334ac9b01f03

ShaderSmith v0.2.0

Choose a tag to compare

@SalyyS1 SalyyS1 released this 14 Nov 06:38

ShaderSmith v0.2.0

Highlights

  • Overlay-Aware Multi-Version Validation (pack.mcmeta Overlays): Parses overlays.entries across legacy [min, max], {min_inclusive, max_inclusive}, and modern min_format/max_format schemas, stacks matching overlay assets/... files per target version during check --mc and check --mc-range, and reports diagnostics at exact physical file paths for IDE and GitHub SARIF annotations.
  • New Shader & Post-Effect Rules (SM032, SM064, SM074): Validates custom-namespace #include / #moj_import targets across overlays (SM032), verifies custom post-effect .vsh/.fsh pass sources (SM064), and flags missing or empty overlays.entries directories (SM074).
  • Asset-Preserving .zip Migration & Deterministic --zip Output: Fixes .zip migration so binary textures, fonts, models, and pack.mcmeta are safely extracted and preserved (with zip-slip path traversal guards), adds --zip <out.zip> byte-reproducible archive output, and prints resource-pack-sha1=<hex> for server.properties.
  • Composite GitHub Action (action.yml): Run SalyyS1/shadersmith@v0.2.0 directly in GitHub Actions workflows with SARIF v2.1.0 Code Scanning integration.

Verification

  • 39/39 JUnit tests passing on Java 21 (./gradlew build --no-daemon).

v0.1.0

Choose a tag to compare

@SalyyS1 SalyyS1 released this 06 Sep 09:52

First release.

shadersmith checks a resource pack's core shaders against the version they are about to run on. The client
does not validate them against anything — it compiles whatever it is given and runs it — so a shader written
for one version can compile on the next and read the wrong uniform, because the contract it was written
against changed without an error saying so. shadersmith holds that contract per version, extracted from the
game's own files, and reports every place the pack disagrees with it, with the fix inline.

Run shadersmith check <pack>/ --mc <version>. See the README for the codes and what each one means.