Skip to content

Commit

Permalink
Add ShaderData Transform and demo catch error when building simple-cube
Browse files Browse the repository at this point in the history
  • Loading branch information
alt-romes committed Feb 4, 2024
1 parent 7a443d2 commit 9d36c62
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions ghengin-core-indep/ghengin-core-indep/Ghengin/Core/Shader.hs
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ import Ghengin.Core.Shader.Pipeline
import Geomancy.Vec2
import Geomancy.Vec3
import Geomancy.Mat4
import Geomancy.Transform

import qualified FIR.Prim.Image as FIR
import qualified SPIRV.Image as SPIRV
Expand Down Expand Up @@ -94,6 +95,9 @@ instance KnownSymbol name => ShaderData (StructVec3 name) where
instance ShaderData Mat4 where
type FirType Mat4 = M 4 4 FIR.Float

instance ShaderData Transform where
type FirType Transform = M 4 4 FIR.Float

instance KnownSymbol name => ShaderData (StructMat4 name) where
type FirType (StructMat4 name) = FIR.Struct '[ name 'FIR.:-> M 4 4 FIR.Float ]

Expand Down

0 comments on commit 9d36c62

Please sign in to comment.