Gfx GX Fn GXInitLightAttnK - wowjinxy/libPorpoise GitHub Wiki
GXInitLightAttnK
- Category:
Lighting
- Matrix Status:
Implemented
- Matrix Notes: Verified SDK-parity write scope: updates only distance attenuation coefficients (
k0..k2) and leaves angular terms unchanged.
- Matrix Link: Gfx-GX-API-Matrix
Official SDK (Reference)
- Manual root:
reference/rvlsdk/man/en_US/gx
- Primary SDK source area:
demos/PikminDemo/src/gx (GC-style Dolphin GX source)
- Notes:
libPorpoise Implementation
- Runtime implementation area:
src/gx
- Public API surface:
include/dolphin/gx
- Notes:
SDK vs Porpoise Diff
- Signature parity:
- Behavioral parity:
-
Known divergence:
Validation Checklist
Working Notes
- Docs checked against
reference/man/gfx/gx/Lighting/GXInitLightAttnK.html and SDK source in reference/gx/GXLight.c.
- SDK behavior:
- Writes only distance attenuation coefficients into the light object (
k[0..2]).
- Does not modify angular attenuation coefficients (
a[0..2]).
- Runtime behavior in
src/gx/pc_gx.c:
GXInitLightAttnK writes exactly k0/k1/k2 and leaves a0/a1/a2 untouched.
- Result:
- Function semantics match SDK for distance-only attenuation updates.