Files
jak-project/goal_src/jak2/engine/debug/memory-usage-h.gc
T
water111 b5705bde96 [decomp] Partial implementation of tie (#1916)
Some stuff isn't working fully yet:
- fog color
- time of day
- draw order for multiple passes (currently all draws in the default tie
bucket)
- possibly settings for transparent stuff (untested, but might work)
- the "vanish" effect (we might not want this anyway?)
- environment mapping/etie completely not implemented.


![image](https://user-images.githubusercontent.com/48171810/192154314-2cc8ac51-9dad-474f-a84b-3a1d98973215.png)

![image](https://user-images.githubusercontent.com/48171810/192154316-457a7ee0-b5a4-4a40-b48e-8863114da735.png)
2022-09-25 12:50:51 -04:00

116 lines
2.4 KiB
Common Lisp

;;-*-Lisp-*-
(in-package goal)
;; name: memory-usage-h.gc
;; name in dgo: memory-usage-h
;; dgos: ENGINE, GAME
(defenum mem-usage-id
:bitfield #f
:type uint32
(tfragment 1)
(tfragment-base 2)
(tfragment-common 3)
(tfragment-level0 4)
(tfragment-level1 5)
(tfragment-color 6)
(tfragment-debug 7)
(tie-fragment 9)
(tie-gif 10)
(tie-points 11)
(tie-colors 12)
(tie-draw-points 13)
(tie-debug 14)
(tie-generic 17)
(instance-tie 18)
(instance-tie-colors0 19)
(instance-tie-colors1 20)
(instance-tie-colors2 21)
(instance-tie-colors3 22)
(inst-tie-colors* 23)
(entity 43)
(camera 44)
(res 48)
(bsp-main 58)
(bsp-misc 59)
(bsp-node 60)
(bsp-leaf-vis-self 61)
(bsp-leaf-vis-adj 62)
(pat 64)
(level-code 65)
(entity-links 66)
(joint 67)
(joint-anim-compressed-control 69)
(joint-anim-fixed 70)
(joint-anim-frame 71)
(subtitle 72)
(art-group 73)
(art-mesh-anim 74)
(art-mesh-geo 75)
(art-joint-geo 76)
(art-joint-anim 77)
(merc-ctrl 78)
(joint-anim-drawable 79)
(blend-shape 80)
(texture 82)
(array 84)
(eye-anim 111)
)
(define-extern mem-size (function basic symbol int int))
;; DECOMP BEGINS
;; this file is debug only
(declare-file (debug))
(when *debug-segment*
(deftype memory-usage-info (structure)
((name string :offset-assert 0)
(count int32 :offset-assert 4)
(used int32 :offset-assert 8)
(total int32 :offset-assert 12)
)
:method-count-assert 9
:size-assert #x10
:flag-assert #x900000010
)
(deftype memory-usage-block (basic)
((work-bsp basic :offset-assert 4)
(length int32 :offset-assert 8)
(data memory-usage-info 112 :inline :offset-assert 16)
)
:method-count-assert 12
:size-assert #x710
:flag-assert #xc00000710
(:methods
(reset! (_type_) _type_ 9)
(calculate-total (_type_) int 10)
(print-mem-usage (_type_ level object) _type_ 11)
)
)
(define *mem-usage* (new 'debug 'memory-usage-block))
(define *dma-mem-usage* (new 'debug 'memory-usage-block))
(define *temp-mem-usage* (the-as memory-usage-block #f))
)