Sunday, December 12, 2010

wumpus-core

Copperbox revision 1946.

I've added a new type UNil to Core.Geometry and added affine instances for Pair and Maybe.

I believe I can unify the graphic types in Wumpus.Basic.Kernel.Objects by making them all extensions of Image

> type Image u a = CF (a, Prim u)

> i.e. type Image u a = DrawingContext -> (a, Prim u)

Currently I have Graphic to be different from Image:

> type Graphic u = DrawingContext -> Prim u

But I think if I make it  this type:

> type Graphic u = Image u (UNil u)

> i.e. type Graphic u = DrawingContext -> (UNil u, Prim u)

Then the dichotomy between Image and Graphic vanishes so they can use the same functions.

Blog Archive

About Me

My photo
Disambiguating biog as there are a few Stephen Tetley's in the world. I'm neither a cage fighter or yachtsman. I studied Fine Art in the nineties (foundation Bradford 1992, degree Cheltenham 1992 - 95) then Computing part-time at Leeds Met graduating in 2003. I'm the Stephen Tetley on Haskell Cafe and Stackoverflow.