jak2/3: implement ocean envmap (#4303)

Implements the envmap for the ocean generated by
`ocean-method-89`/`ocean-method-88`.

While the resulting envmap looks accurate compared to PCSX2 in
Renderdoc, the end result does not seem 100% identical, but it is a big
improvement over the default placeholder texture.

Closes #3417
This commit is contained in:
Hat Kid
2026-06-07 07:27:43 +02:00
committed by GitHub
parent b948e954d0
commit 25e105aa5d
14 changed files with 417 additions and 28 deletions
+3 -5
View File
@@ -1167,11 +1167,9 @@
(let* ((s4-0 (-> *display* frames (-> *display* on-screen) global-buf))
(s5-2 (-> s4-0 base))
)
;; TODO handle ocean::79 and ocean::89
;; diasble tod ocean stuff
;; (if (-> *time-of-day-context* sky)
;; (ocean-method-89 this s4-0)
;; )
(if (-> *time-of-day-context* sky)
(ocean-method-89 this s4-0)
)
(draw-ocean-texture this s4-0 (the-as int (-> this verts)))
;; disable whatever this is
;; (ocean-method-79 this s4-0)
+3 -4
View File
@@ -1191,10 +1191,9 @@
(let* ((s4-1 (-> *display* frames (-> *display* on-screen) global-buf))
(s5-2 (-> s4-1 base))
)
;; og:preserve-this not-yet-implemented
; (if (-> *time-of-day-context* sky)
; (ocean-method-88 this s4-1)
; )
(if (-> *time-of-day-context* sky)
(ocean-method-88 this s4-1)
)
(draw-ocean-texture this s4-1 (the-as int (-> this verts)))
; (ocean-method-89 this s4-1)
(init-buffer! this s4-1)