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
| -- https://md.ccc.ac/OSHOP2026-CAD-Showdown?both | |
| import qualified Waterfall as W | |
| import Linear | |
| import Control.Lens | |
| import Data.Function ((&)) | |
| body :: W.Solid | |
| body = | |
| let r = 10 | |
| f (a, b) = |
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 stack | |
| {- stack script --resolver lts-23.16 | |
| --package linear | |
| --package lens | |
| --package waterfall-cad | |
| --package waterfall-cad-svg | |
| --extra-dep waterfall-cad-svg-0.6.2.1 | |
| --extra-dep waterfall-cad-0.6.2.1 | |
| --extra-dep opencascade-hs-0.6.2.1 | |
| -} |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| object :: IO Waterfall.Solid | |
| object = text "/VarelaRound-Regular.ttf" 24 "Hello Hacker News" 12 |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| object :: IO Waterfall.Solid | |
| object = text "/VarelaRound-Regular.ttf" 24 "Hello Lobste.rs " 12 |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| object :: IO Waterfall.Solid | |
| object = text "/VarelaRound-Regular.ttf" 24 "Hello Discourse.Haskell.Org " 12 |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| threeFourFour :: IO Waterfall.Solid | |
| threeFourFour = text "/VarelaRound-Regular.ttf" 24 "Hello Reddit" 12 |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| threeFourFour :: IO Waterfall.Solid | |
| threeFourFour = text "/VarelaRound-Regular.ttf" 24 "Hello Mastodon!!!" 12 |
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
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize | |
| return . Waterfall.rotate (unit _x) (pi/2) . Waterfall.prism depth $ Waterfall.text font content | |
| threeFourFour :: IO Waterfall.Solid | |
| threeFourFour = text "/VarelaRound-Regular.ttf" 24 "Hello BlueSky" 12 |
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
| import qualified Waterfall as W | |
| import Linear | |
| import Data.Foldable | |
| object = fold $ W.tryRoundFillet 0.1 W.unitCube |
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
| module ThreeFourFour ( | |
| threeFourFour | |
| ) where | |
| import qualified Waterfall | |
| import Linear (unit, _x) | |
| text :: FilePath -> Double -> String -> Double -> IO Waterfall.Solid | |
| text fontpath fontSize content depth = do | |
| font <- Waterfall.fontFromPath fontpath fontSize |
NewerOlder