我有个问题:
NXC中有这样一个struct函数:
struct colorType
{
int colorval;
unsigned int rawRed;
unsigned int rawGreen;
unsigned int rawBlue;
unsigned int normRed;
unsigned int normGreen;
unsigned int normBlue;
};
colorType cubeColor[6*9];
我在 F# 中创建了相同的结构,如下所示:
type colorType =
struct
val colorval: int
val rawRed: uint16
val rawGreen: uint16
val rawBlue: uint16
val normRed: uint16
val normGreen: uint16
val normBlue: uint16
end
但我不知道如何调用colorType cubeColor[6*9]; 在 F# 中。
你能帮我处理这个案子吗?
谢谢。