ChrisOS Research ProjectOperating systems · language systems · graphics · machine emulation
DOCUMENTATION ARCHIVEMAIN BRANCH
ChrisOS/Source reference: LIB/XFORM.H

Source reference: LIB/XFORM.H

Deterministic source record. The complete textual file is reproduced below; this page does not replace architectural interpretation in the authored chapters.

File identity

Field Value
Path LIB/XFORM.H
Lines 29
Bytes 411
SHA-256 2812bf7d200a571cd1e82bd4ad1969ad5d463c1b9a9c9235dfeb5de939dea37c
ChrisOS revision da3df29cb397932c43d32373871fb9380e688ade

Detected syntactic dependencies

Line Include
— No preprocessor include detected.

Detected symbols

Line Symbol
13 xform_ident
22 xform_world

Complete source

The following block is the complete textual file at the recorded revision. No lines are elided, abbreviated or paraphrased.

#ifndef XFORM_H
#define XFORM_H

struct Xform {
    float x;
    float y;
    float z;
    float yaw;
    float pitch;
    int parent;
};

void xform_ident(struct Xform *t) {
    t->x = 0.0;
    t->y = 0.0;
    t->z = 0.0;
    t->yaw = 0.0;
    t->pitch = 0.0;
    t->parent = -1;
}

void xform_world(struct Xform *t, float *ox, float *oy, float *oz) {
    *ox = t->x;
    *oy = t->y;
    *oz = t->z;
}

#endif

Role of this record

The atlas guarantees file-by-file traceability. Responsibility, invariants, ownership, concurrency, security, performance and subsystem interactions belong in authored chapters and must cite this file when applicable.

Document record ID: source-2812bf7d200a571c Reviewed source: da3df29cb397 Class: generated-source-reference