Passing enumerated constants to a function

I can’t seem to google any help with how to go about passing an enumerated list of constants to a function e.g.
enum bmpHdr{
hdr = 54,
pal = 1024,
xpi = 256,
ypi = 256

bmpBlob <- blob(bmpHdr.hdr+bmpHdr.pal+bmpHdr.xpi*bmpHdr.ypi); //enums used to size blob OK

initBmpHdr(bmpBlob, bmpHdr); //Error: expected ‘.’ when attempting to pass enumerated table to a function

I could use an ordinary table of key:value pairs for the details but they are constants so it seems more appropriate to declare them as such. However it doesn’t seem possible to get pass a reference to them. I tried bmpHdr() bmpHdr{} but the compiler keeps expecting a ‘.’