From f910579e66a1495c4c1c97e2b99ea178d9d194ee Mon Sep 17 00:00:00 2001 From: pacien Date: Sat, 9 Dec 2017 01:59:50 +0100 Subject: Add proper struct documentation Signed-off-by: pacien --- include/common/geom.h | 12 ++++++++++-- include/common/matrix.h | 6 +++++- 2 files changed, 15 insertions(+), 3 deletions(-) (limited to 'include/common') diff --git a/include/common/geom.h b/include/common/geom.h index 4445998..a843c76 100644 --- a/include/common/geom.h +++ b/include/common/geom.h @@ -15,16 +15,24 @@ typedef int32_t IntVector; /** - * Type: CartesianVector + * Struct: CartesianVector * An abstract 2-D vector in cartesian coordinates. + * + * Fields: + * x - the horizontal component + * y - the vertical component */ typedef struct { IntVector x, y; } CartesianVector; /** - * Type: CartesianMapping + * Struct: CartesianMapping * A tuple of cartesian vectors representing a mapping. + * + * Fields: + * origin - preimage vector + * target - image vector */ typedef struct { CartesianVector origin, target; diff --git a/include/common/matrix.h b/include/common/matrix.h index 726a8ab..fe4a12a 100644 --- a/include/common/matrix.h +++ b/include/common/matrix.h @@ -12,8 +12,12 @@ #include "geom.h" /** - * Type: IntSquareMatrix + * Struct: IntSquareMatrix * Represents a square integer matrix. + * + * Fields: + * **elements - NULL-terminated array of element pointers + * dim - dimension */ typedef struct { IntVector **elements; -- cgit v1.2.3