Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Tools and samples for understanding Apple's Metal shading language and its LLVM Bitcode shader files

License

Notifications You must be signed in to change notification settings

zeejuncode/MetalShaderTools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

1 Commit

Repository files navigation

Tools for examining Apple's Metal shaders.

Contents

  • unmetallib.py: extracts .metallib files to .air files.
  • sampleshader/: contains:
    • a Metal shader from Apple's HelloTriangle project
    • the compiled metallib using Xcode 9.3's metal compiler
    • the .air files recompiled to x86_64 and arm64 assembly using LLVM 6.0.0 to show that Metal shaders are valid LLVM Bitcode and can be processed using normal LLVM tools.

Other Metal projects you might find useful

License

My code (unmetallib.py, sampleshader/*.sh) is under the MIT license.

sampleshader/AAPLShaders.metal and sampleshader/AAPLShaderTypes.h are taken from Apple's HelloTriangle project. Their license can be found in sampleshader/AAPLShaders_LICENSE.txt (also MIT license)

About

Tools and samples for understanding Apple's Metal shading language and its LLVM Bitcode shader files

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • LLVM 38.8%
  • Assembly 24.9%
  • Metal 19.0%
  • C 7.3%
  • Python 6.6%
  • Shell 3.4%

AltStyle によって変換されたページ (->オリジナル) /