{"id":16856609,"url":"https://github.com/grovesnl/spirv_cross","last_synced_at":"2025-04-04T07:08:28.679Z","repository":{"id":40614112,"uuid":"104680194","full_name":"grovesNL/spirv_cross","owner":"grovesNL","description":"Safe Rust wrapper around SPIRV-Cross","archived":false,"fork":false,"pushed_at":"2023-07-28T07:22:38.000Z","size":1902,"stargazers_count":86,"open_issues_count":15,"forks_count":42,"subscribers_count":4,"default_branch":"master","last_synced_at":"2024-10-14T14:11:27.992Z","etag":null,"topics":["directx","graphics","metal","opengl","rust","spir-v","spirv","spirv-cross","vulkan"],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/grovesNL.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":".github/FUNDING.yml","license":"LICENSE-APACHE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":["grovesNL"]}},"created_at":"2017-09-24T22:19:54.000Z","updated_at":"2024-09-21T10:41:13.000Z","dependencies_parsed_at":"2024-06-18T21:53:14.131Z","dependency_job_id":null,"html_url":"https://github.com/grovesNL/spirv_cross","commit_stats":{"total_commits":305,"total_committers":22,"mean_commits":"13.863636363636363","dds":0.2065573770491803,"last_synced_commit":"aae970dee36e8f5eca528ee4a60c0e08d93641c1"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grovesNL%2Fspirv_cross","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grovesNL%2Fspirv_cross/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grovesNL%2Fspirv_cross/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/grovesNL%2Fspirv_cross/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/grovesNL","download_url":"https://codeload.github.com/grovesNL/spirv_cross/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247135144,"owners_count":20889421,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["directx","graphics","metal","opengl","rust","spir-v","spirv","spirv-cross","vulkan"],"created_at":"2024-10-13T14:04:48.856Z","updated_at":"2025-04-04T07:08:28.643Z","avatar_url":"https://github.com/grovesNL.png","language":"Rust","funding_links":["https://github.com/sponsors/grovesNL"],"categories":[],"sub_categories":[],"readme":"\u003ch1 align=\"center\"\u003e\n  spirv_cross\n\u003c/h1\u003e\n\u003cdiv align=\"center\"\u003e\n  Safe wrapper around \u003ca href=\"https://github.com/KhronosGroup/SPIRV-Cross\"\u003eSPIR-V Cross\u003c/a\u003e\n\u003c/div\u003e\n\u003cbr /\u003e\n\u003cdiv align=\"center\"\u003e\n  \u003ca href=\"https://crates.io/crates/spirv_cross\"\u003e\u003cimg src=\"https://img.shields.io/crates/v/spirv_cross.svg?label=spirv_cross\" alt=\"Crate\"\u003e\u003c/a\u003e \u003ca href=\"https://travis-ci.org/grovesNL/spirv_cross\"\u003e\u003cimg src=\"https://travis-ci.org/grovesNL/spirv_cross.svg?branch=master\" alt=\"Travis Build Status\" /\u003e\u003c/a\u003e \u003ca href=\"https://ci.appveyor.com/project/grovesNL/spirv-cross/branch/master\"\u003e\u003cimg src=\"https://ci.appveyor.com/api/projects/status/ja22j0ueje51sd76/branch/master?svg=true\" alt=\"Appveyor Build Status\" /\u003e\u003c/a\u003e\n\u003c/div\u003e\n\n## Example\n\n`spirv_cross` provides a safe wrapper around [SPIRV-Cross](https://github.com/KhronosGroup/SPIRV-Cross) for use with Rust. For example, here is a simple function to parse a SPIR-V module and compile it to HLSL and MSL:\n\n```rust\nextern crate spirv_cross;\nuse spirv_cross::{spirv, hlsl, msl, ErrorCode};\n\nfn example(module: spirv::Module) -\u003e Result\u003c(), ErrorCode\u003e {\n    // Compile to HLSL\n    let ast = spirv::Ast::\u003chlsl::Target\u003e::parse(\u0026module)?;\n    println!(\"{}\", ast.compile()?);\n\n    // Compile to MSL\n    let ast = spirv::Ast::\u003cmsl::Target\u003e::parse(\u0026module)?;\n    println!(\"{}\", ast.compile()?);\n\n    Ok(())\n}\n```\n\n## License\n\nThis project is licensed under either of [Apache License, Version\n2.0](LICENSE-APACHE) or [MIT license](LICENSE-MIT), at your option.\n\n## Contribution\n\nUnless you explicitly state otherwise, any contribution intentionally submitted\nfor inclusion in this project by you, as defined in the Apache 2.0 license,\nshall be dual licensed as above, without any additional terms or conditions.\n\nSee [CONTRIBUTING.md](CONTRIBUTING.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrovesnl%2Fspirv_cross","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fgrovesnl%2Fspirv_cross","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fgrovesnl%2Fspirv_cross/lists"}