This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env bash | |
| # | |
| # File: macos-haskell-run-vulkan-triangles.sh | |
| # | |
| # Haskell Vulkan on MacOS example: | |
| # Build and run the vulkan-triangles GLFW example. | |
| # | |
| # The purpose of this script is to automate building and running the | |
| # vulkan-triangles GLFW example. There are some half-baked instructions | |
| # for MacOS available here: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Crappy Utah Teapot loader script for Blender 2.90.1 | |
| import bpy | |
| from mathutils import Vector | |
| def create4x4patch(points): | |
| surface_data = bpy.data.curves.new('wook', 'SURFACE') | |
| surface_data.dimensions = '3D' | |
| # set points per segments (U * V) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env cabal | |
| {-# LANGUAGE OverloadedStrings #-} | |
| {-# LANGUAGE ScopedTypeVariables #-} | |
| {- cabal: | |
| ghc-options: | |
| -O2 -threaded -rtsopts "-with-rtsopts=-N -T" | |
| -Wall -Wcompat -Wincomplete-record-updates | |
| -Wincomplete-uni-patterns -Wredundant-constraints |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/env cabal | |
| {-# LANGUAGE FlexibleContexts #-} | |
| {-# LANGUAGE NumericUnderscores #-} | |
| {-# LANGUAGE ScopedTypeVariables #-} | |
| {-# LANGUAGE TypeFamilies #-} | |
| {- cabal: | |
| build-depends: | |
| base |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| //! Creates WGPU context that must run async. | |
| //! | |
| //! Three important parts of the WGPU API are async functions: | |
| //! - Creating a new WGPU Instance. | |
| //! - Requesting a new WGPU Adapter. | |
| //! - Creating a WGPU Device and Queue. | |
| //! | |
| //! In non-web applications, we would like to block on these functions. However, | |
| //! for WASM (web) usage, we cannot block. | |
| //! |
OlderNewer